InfluxDB migration error from 0.10.2 to 0.12.2
This is following the discussion at the google groups: https://groups.google.com/forum/#!topic/influxdb/5BX2pUD-9lU
I still think it was something I did, but @beckettsean seems to trust me more than I do :-)
I was upgrading influx from 0.10.2 to 0.12.2 and followed the instructions. Here are the steps I took. This is basically a dump of the relevant bash history.
# First backup the existing metadata
cd /data
mkdir -p metadata-backup
cd metadata-backup/
cp -r /usr/local/influxdb/meta/ .
# Next backup using the influxd backup command
cd ../
mkdir -p metastore-0.10.2-backup
influxd backup /data/influxdb-backups/metastore-0.10.2-backup/
# Shutdown influxd Server
supervisorctl stop influxd
# Update the influxd config file.
# Not adding the command here. It was just vi <blah>
# Do a restore
influxd restore -metadir=/usr/local/influxdb/meta /data/influxdb-backups/metastore-0.10.2-backup/
# Start influxd again.
supervisorctl start influxd
The expectation was that all the meta information would be restored to the two databases (our own and the "_internal")
However, when I did a SHOW MEASUREMENTS on our database, it returned empty.
I checked _internal and ran the same command, SHOW MEASUREMENTS
It showed all the measurements from our database.
For now, I just relocated the data using the following commands:
SELECT tagKey INTO mydb."default"._tagKeys FROM _internal.monitor._tagKeys
SELECT _tagKey, value INTO mydb."default"."_tags" FROM _internal.monitor._tags WHERE _tagKey = 'mykey'
Please close if this was operator error.
@srikara in your timeline, when was the influxd binary updated? I see the export and the import, but not the package installation.
Apologies. I was copy/pasting the commands and forgot to add the influx upgrade. The upgrade happened after stopping influxd server and updating the config file and before running restore.
Is /usr/local/influxdb/meta the value of your [meta].Dir in your config file? That's not the default meta dir location used in the packages so influxd might be looking for your meta data in a different location.
Closing this due to a lack of a response for 2 months. @srikara if you're still having issues, feel free to make another comment and I can reopen this.
@jsternberg Thanks for closing this. I am pretty sure this was operator error.