Issue with automatic upgrade to influxDB 2.0 with Docker

Hi,
Me and some others have an issue when trying to upgrade to InfluxDB 2.0 with docker, Error: error getting size of /var/lib/influxdb/data: open /var/lib/influxdb/data/_internal: permission denied

We tried to get your attention at github without any response: Automatic upgrade documentation in docker hub does work as described · Issue #462 · influxdata/influxdata-docker · GitHub

Kind regards.

As suspected, the old data folders need special permissions.
One can achieve that by running chown -R 1000:1000. (h/t to desvdp)

Thank you, I’ll give it a try

@mhall119 can you help here please?

Did the chown -R 1000:1000 suggestion work?

As described in the issue on Github, InfluxDB 2 runs as an unprivileged user, which is better security practice. But that means it can’t read or write the data files created by InfluxDB 1.x unless you have the file permissions on them, which is what the above command does.

Well this was very timely. I ran into the same issue.

Yes, chown -R 1000:1000 solved the problem

I’ve been using influx1.x for a couple years but I had never used docker before. I want to get a taste of Influx2.x so this seemed like a good time to work with docker. If anyone needs help I can provide the details of how I took my production V1 influx and got my data into a docker InfluxV2. This file ownership issue was the last thing stumping me.