We have Grafana v 4.6.3 docker container installed on Ubuntu machine. It uses volume grafana-storage. When I try to run latest version of grafana container with this volume it fails.
Here’s command I try to run:
docker run \ -d \ -p 3000:3000 \ --name=grafana-new \ -v grafana-storage:/var/lib/grafana \ -e GF_AUTH_ANONYMOUS_ENABLED=true \ grafana/grafana:5.2.2
Here’re the logs:
~$ docker logs grafana-new
t=2018-08-09T12:00:42+0000 lvl=info msg="Starting Grafana" logger=server version=5.2.2 commit=aeaf7b2 compiled=2018-07-25T11:17:28+0000
t=2018-08-09T12:00:42+0000 lvl=info msg="Config loaded from" logger=settings file=/usr/share/grafana/conf/defaults.ini
t=2018-08-09T12:00:42+0000 lvl=info msg="Config loaded from" logger=settings file=/etc/grafana/grafana.ini
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from command line" logger=settings arg="default.paths.data=/var/lib/grafana"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from command line" logger=settings arg="default.paths.logs=/var/log/grafana"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from command line" logger=settings arg="default.paths.plugins=/var/lib/grafana/plugins"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from command line" logger=settings arg="default.paths.provisioning=/etc/grafana/provisioning"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from command line" logger=settings arg="default.log.mode=console"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from Environment variable" logger=settings var="GF_PATHS_DATA=/var/lib/grafana"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from Environment variable" logger=settings var="GF_PATHS_LOGS=/var/log/grafana"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from Environment variable" logger=settings var="GF_PATHS_PLUGINS=/var/lib/grafana/plugins"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from Environment variable" logger=settings var="GF_PATHS_PROVISIONING=/etc/grafana/provisioning"
t=2018-08-09T12:00:42+0000 lvl=info msg="Config overridden from Environment variable" logger=settings var="GF_AUTH_ANONYMOUS_ENABLED=true"
t=2018-08-09T12:00:42+0000 lvl=info msg="Path Home" logger=settings path=/usr/share/grafana
t=2018-08-09T12:00:42+0000 lvl=info msg="Path Data" logger=settings path=/var/lib/grafana
t=2018-08-09T12:00:42+0000 lvl=info msg="Path Logs" logger=settings path=/var/log/grafana
t=2018-08-09T12:00:42+0000 lvl=info msg="Path Plugins" logger=settings path=/var/lib/grafana/plugins
t=2018-08-09T12:00:42+0000 lvl=info msg="Path Provisioning" logger=settings path=/etc/grafana/provisioning
t=2018-08-09T12:00:42+0000 lvl=info msg="App mode production" logger=settings
t=2018-08-09T12:00:42+0000 lvl=info msg="Initializing SqlStore" logger=server
t=2018-08-09T12:00:42+0000 lvl=info msg="Connecting to DB" logger=sqlstore dbtype=sqlite3
t=2018-08-09T12:00:42+0000 lvl=info msg="Starting DB migration" logger=migrator
t=2018-08-09T12:00:42+0000 lvl=info msg="Executing migration" logger=migrator id="Migrate all Read Only Viewers to Viewers"
t=2018-08-09T12:00:42+0000 lvl=eror msg="Executing migration failed" logger=migrator id="Migrate all Read Only Viewers to Viewers" error="attempt to write a readonly database"
t=2018-08-09T12:00:42+0000 lvl=eror msg="Exec failed" logger=migrator error="attempt to write a readonly database" sql="UPDATE org_user SET role = 'Viewer' WHERE role = 'Read Only Editor'"
t=2018-08-09T12:00:42+0000 lvl=eror msg="Server shutdown" logger=server reason="Service init failed: Migration failed err: attempt to write a readonly database"
Please help me update grafana