SHOW TAG VALUES respecting retention policy / non-persistent tag values?
Is there some way to limit SHOW TAG VALUES FROM "measurement_name" WITH KEY = "tag_key" to show only values of the default retention policy - or perhaps some user picked one?
Changing retention policy doesn't help - even removing a RP leaves those values intact. Only droping a measurement helps.
Perhaps there should be some index refresh during retention policy change ?
Or some "rebuild indexes" command ?
It sounds similar to https://github.com/influxdata/influxdb/issues/5389
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This issue has been automatically closed because it has not had recent activity. Please reopen if this issue is still important to you. Thank you for your contributions.
This is still unresolved. If you have two retention policies, telegraf.autogen and telegraf.otherpolicy and a tag has different values in each, it is not possible to use SHOW TAG VALUES (or any other query) to show just the values in one RP and not the other. It will always show all values for both RPs combined
I believe that StaleBot closed this issue in error
This is still unresolved. If you have two retention policies, telegraf.autogen and telegraf.otherpolicy and a tag has different values in each, it is not possible to use SHOW TAG VALUES (or any other query) to show just the values in one RP and not the other. It will always show all values for both RPs combined
I believe that StaleBot closed this issue in error
InfluxDB 1.8
SHOW TAG KEYS ON db FROM rp.measurement does not respecting rp value, even if you are writing some inexistent rp
> show retention policies on telemetry
name duration shardGroupDuration replicaN default
---- -------- ------------------ -------- -------
autogen 0s 168h0m0s 1 true
Minutes1 2880h0m0s 24h0m0s 1 false
Minutes10 2880h0m0s 24h0m0s 1 false
Hours1 2880h0m0s 24h0m0s 1 false
Hours24 4320h0m0s 168h0m0s 1 false
OneWeekIntegration 168h0m0s 24h0m0s 1 false
> SHOW TAG KEYS ON telemetry FROM "blahblah"."srm"
name: srm
tagKey
------
MetricName
SetupID
User
Version
>
I hit this problem too. I was always seeing the tag counts for the default retention policy no matter what. But I wanted to see the tags for a different retention policy.
I tried all these and it did not work:
Changing GET url query from /query?db=telemetry&epoch=ms to /query?db=telemetry&rp=downsampled&epoch=ms
Changing InfluxQL query from
show tag values from "com.blah.metricname" with key="host"
to
show tag values from downsampled."com.blah.metricname" with key="host"
(this works for normal select queries but not for show tag values, thats what this issue is about)
Here is what DID WORK:
I am using InfluxDB 2.0 and so under the hood these are separate buckets, not different influxdb 1.0 retention policies.
I have my own database retention policy mappings configured, but im also on a version of influxdb that creates these virtual DBRP mappings for us:
$ sudo -u influxdb influx v1 dbrp list
ID Database Bucket ID Retention Policy Default Organization ID
Xxxxxxxxxxxxxxxx telemetry Xxxxxxxxxxxxxxxx raw_data true Xxxxxxxxxxxxxxxx
Xxxxxxxxxxxxxxxx telemetry Xxxxxxxxxxxxxxxx downsampled false Xxxxxxxxxxxxxxxx
VIRTUAL DBRP MAPPINGS (READ-ONLY)
----------------------------------
ID Database Bucket ID Retention Policy Default Organization ID
...
Xxxxxxxxxxxxxxxx default Xxxxxxxxxxxxxxxx autogen true Xxxxxxxxxxxxxxxx
Xxxxxxxxxxxxxxxx default_downsampled Xxxxxxxxxxxxxxxx autogen true Xxxxxxxxxxxxxxxx
...
When I changed the GET url query from /query?db=telemetry&epoch=ms to /query?db=default_downsampled&epoch=ms, it worked !!!