Can't update to lastest version

I’m using verion 8.5.4 then upgrade to 9.3.0

But after I run upgrade it still show i’m in 8.5.4 in website

My docker-compose file

grafana:
    image: grafana/grafana-enterprise:9.3.1
    restart: always
    volumes:
      - grafana_database:/var/lib/grafana
      - grafana_config:/etc/grafana
      - grafana_home:/usr/share/grafana
      - grafana_logs:/var/log/grafana
      - grafana_plugins:/var/lib/grafana/plugins
    ports:
      - "2000:3000"
    environment:
      GF_RENDERING_SERVER_URL: http://renderer:8081/render
      GF_RENDERING_CALLBACK_URL: http://grafana:2000/
      GF_LOG_FILTERS: rendering:debug
    profiles:
      - dev

My step:

docker pull grafana/grafana
docker stop my-grafana-container
docker rm my-grafana-container
docker-compose -p my-project --profile dev up -d

Screenshot from 2022-12-09 17-21-36

Hi @nhatmicls,

Can you try to add the following parameter as well using docker-compose up command i.e.
--force-recreate

If this does not help then please check if the container logs and paste them here so that we can see what is causing this issue.

Thanks for your reply,
After I do --force-recreate it still in 8.5.4

This is logs container

logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Starting Grafana" version=8.5.4 commit=78ee95814 branch=HEAD compiled=2022-05-30T13:55:03Z
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config loaded from" file=/usr/share/grafana/conf/defaults.ini
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config loaded from" file=/etc/grafana/grafana.ini
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from command line" arg="default.paths.data=/var/lib/grafana"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from command line" arg="default.paths.logs=/var/log/grafana"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from command line" arg="default.paths.plugins=/var/lib/grafana/plugins"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from command line" arg="default.paths.provisioning=/etc/grafana/provisioning"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from command line" arg="default.log.mode=console"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from Environment variable" var="GF_PATHS_DATA=/var/lib/grafana"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from Environment variable" var="GF_PATHS_LOGS=/var/log/grafana"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from Environment variable" var="GF_PATHS_PLUGINS=/var/lib/grafana/plugins"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from Environment variable" var="GF_PATHS_PROVISIONING=/etc/grafana/provisioning"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from Environment variable" var="GF_LOG_FILTERS=rendering:debug"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from Environment variable" var="GF_RENDERING_SERVER_URL=http://renderer:8081/render"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Config overridden from Environment variable" var="GF_RENDERING_CALLBACK_URL=http://grafana:3000/"
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Path Home" path=/usr/share/grafana
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Path Data" path=/var/lib/grafana
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Path Logs" path=/var/log/grafana
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Path Plugins" path=/var/lib/grafana/plugins
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="Path Provisioning" path=/etc/grafana/provisioning
logger=settings t=2022-12-12T04:13:34.14+0000 lvl=info msg="App mode production"
logger=sqlstore t=2022-12-12T04:13:34.14+0000 lvl=info msg="Connecting to DB" dbtype=sqlite3
logger=migrator t=2022-12-12T04:13:34.18+0000 lvl=info msg="Starting DB migrations"
logger=migrator t=2022-12-12T04:13:34.23+0000 lvl=info msg="migrations completed" performed=0 skipped=461 duration=695.056µs
logger=licensing t=2022-12-12T04:13:34.23+0000 lvl=info msg="Validated license token" appURL=http://scada.pec-cloud.com:3000/ source=disk status=NotFound
logger=plugin.manager t=2022-12-12T04:13:34.33+0000 lvl=info msg="Plugin registered" pluginId=input
logger=query_data t=2022-12-12T04:13:34.35+0000 lvl=info msg="Query Service initialization"
logger=live.push_http t=2022-12-12T04:13:34.36+0000 lvl=info msg="Live Push Gateway initialization"
logger=grafanaStorageLogger t=2022-12-12T04:13:34.47+0000 lvl=info msg="storage starting"
logger=http.server t=2022-12-12T04:13:34.48+0000 lvl=info msg="HTTP Server Listen" address=[::]:3000 protocol=http subUrl= socket=
logger=ngalert t=2022-12-12T04:13:34.48+0000 lvl=info msg="warming cache for startup"
logger=rendering renderer=http t=2022-12-12T04:13:34.48+0000 lvl=dbug msg="calling remote rendering service" url=http://renderer:8081/render/version
logger=rendering renderer=http t=2022-12-12T04:13:34.48+0000 lvl=eror msg="Failed to send request to remote rendering service" error="Get \"http://renderer:8081/render/version\": dial tcp 192.168.80.7:8081: connect: connection refused"
logger=rendering renderer=http t=2022-12-12T04:13:34.48+0000 lvl=info msg="Couldn't get remote renderer version, retrying" err="failed to send request to remote rendering service: Get \"http://renderer:8081/render/version\": dial tcp 192.168.80.7:8081: connect: connection refused" try=0
logger=ngalert.multiorg.alertmanager t=2022-12-12T04:13:34.63+0000 lvl=info msg="starting MultiOrg Alertmanager"

Hi @nhatmicls,

Thanks for the detailed reply. I need the following information in order to reproduce this issue.

1- Send me your docker-compose.yml file you used before updating to version 9.x (i know that you already posted the docker-compose so if the only change is using 9.3.1 instead of 8.5.4 then also let me know as in that case, no need to post).

2- What is your docker version?

Hi,

  1. I just change from 8.5.4 to 9.3.1
  2. My docker version Docker version 20.10.7, build f0df350
  3. My docker compose version docker-compose version 1.29.2, build 5becea4c

So I have tested it out on my test machine and it seems to be working fine.

I took your docker-compose.yml file and took only the necessary lines to run it correctly i.e.

version: "3"
services:
  grafana:
    image: grafana/grafana-enterprise:9.3.1
    container_name: grafana-enterprise
    restart: always
    ports:
      - "2000:3000"

The first deployment was with 8.5.4 which was fine

Then I run the command:

docker-compose down

to bring the container down and then edit the yml file to change it to 9.3.1 and then deployed again

docker-compose up -d

which I checked and it was not showing the older version.

So, this is not a Grafana issue but docker-related.

I also noticed one slight mistake with the Image renderer (which you want to use).

The Image Renderer plugin is separate from grafana so you have to define it as a separate entry in the docker-compose.yml i.e. :

version: "3"
services:
  grafana:
    image: grafana/grafana-enterprise:8.5.4
    container_name: grafana-enterprise
    restart: always
    ports:
      - "2000:3000"

  renderer:
    image: grafana/grafana-image-renderer:latest
    environment:
      GF_RENDERING_SERVER_URL: http://renderer:8081/render
      GF_RENDERING_CALLBACK_URL: http://grafana:2000/
    ports:
    - "8081"

Also, you can try to delete the version 8.5.4 downloaded image from the disk before proceeding to 9.3.4 and when you run the docker-compose up -d will show you as if incase it is still downloading the 8.5.4 image or not

1 Like

I just found the error, after i remove my grafana-home volume it work again, everything update to latest