Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v3.11.4 : it has been failing to build images with an HTTP 500 error #565

Open
hamelg opened this issue Sep 5, 2024 · 8 comments
Open

Comments

@hamelg
Copy link

hamelg commented Sep 5, 2024

What happened:
with v3.11.4 the image render plugin doesn't build the images and returns a http 500 error.
v3.11.3 works fine.

How to reproduce it (as minimally and precisely as possible):
Generate a report

Anything else we need to know?:
The logs when it fails


{
  "level": "error",
  "message": "::ffff:10.1.21.17 - - [05/Sep/2024:17:18:39 +0000] \"GET /render?deviceScaleFactor=2.000000&domain=grafanae&encoding=&height=280&renderKey=9tqp9T7WEDDVDKLVBlA8oD6CrzIsk0XU&timeout=10&timezone=&url=http%3A%2F%2Fgrafanae%3A3000%2Fd-solo%2FTk8-WD2Zz%2Fcarbon%3Ffrom%3D1725535117000%26panelId%3D26%26theme%3Dlight%26timezone%3Dbrowser%26to%3D1725556717000%26var-Cache%3Dweya0075-graphite-maina%26var-DS%3DGRAPHITE-MAR%26render%3D1&width=392 HTTP/1.1\" 500 96 \"-\" \"Grafana/10.4.8\"\n"
}
{
  "level": "error",
  "message": "Request failed",
  "stack": "Error: Failed to launch the browser process!\nchrome_crashpad_handler: --database is required\nTry chrome_crashpad_handler --help for more information.\n\n\nTROUBLESHOOTING: https://pptr.dev/troubleshooting\n\n    at Interface.onClose (/usr/src/app/node_modules/puppeteer-core/node_modules/@puppeteer/browsers/lib/cjs/launch.js:310:24)\n    at Interface.emit (node:events:529:35)\n    at Interface.close (node:internal/readline/interface:534:10)\n    at Socket.onend (node:internal/readline/interface:260:10)\n    at Socket.emit (node:events:529:35)\n    at endReadableNT (node:internal/streams/readable:1400:12)\n    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)",
  "url": "/render?deviceScaleFactor=2.000000&domain=grafanae&encoding=&height=280&renderKey=Sbr41ISO2s9CxqgEtFUIpcT6GfgQAM6N&timeout=10&timezone=&url=http%3A%2F%2Fgrafanae%3A3000%2Fd-solo%2FTk8-WD2Zz%2Fcarbon%3Ffrom%3D1725535117000%26panelId%3D27%26theme%3Dlight%26timezone%3Dbrowser%26to%3D1725556717000%26var-Cache%3Dweya0075-graphite-maina%26var-DS%3DGRAPHITE-MAR%26render%3D1&width=392"
}

Environment:

  • renderer is running in a docker container as remote rendering service
  • Docker image docker.io/grafana/grafana-image-renderer:3.11.4
  • Grafana version: 10.4.8
@b-neufeld
Copy link

Same issue, Grafana version, same environment as you. I reverted to 3.11.1 because it was I had installed before the attempted update.

@evictorero
Copy link
Contributor

The error message seems to be the same as this. Can you try adding this?
On the other hand, I have a docker container with 3.11.4 running as a standalone service and working as expected.
Can you provide more details of your configuration?

@hamelg
Copy link
Author

hamelg commented Sep 11, 2024

Setting these environment variables did the trick :

            - name: XDG_CONFIG_HOME
              value: /tmp/.chromium
            - name: XDG_CACHE_HOME
              value: /tmp/.chromium

I have no explanation as to why these variables are needed with 3.11.4 ...

@giuliomagnifico
Copy link

3.11.5 same

Sep 13 21:06:44 DietPi systemd[1]: Started grafana-image-renderer.service - grafana-image-renderer.
Sep 13 21:06:46 DietPi node[1016058]: {"level":"info","message":"HTTP Server started, listening at http://localhost:8081"}
Sep 13 21:06:57 DietPi node[1016058]: [2.4K blob data]
Sep 13 21:06:57 DietPi node[1016058]: {"level":"error","message":"::ffff:192.168.1.6 - - [13/Sep/2024:19:06:57 +0000] \"GET /rende
r?deviceScaleFactor=1.000000&domain=192.168.1.6&encoding=png&height=500&renderKey=YilU1wLHeGCY6AFPsXKu4AuqxL3oQC5S&timeout=60&time
zone=Europe%2FRome&url=http%3A%2F%2F192.168.1.6%3A3001%2Fd-solo%2FFGioSdO4z31m%2Fcasa-summary%3ForgId%3D1%26refresh%3D1m%26from%3D
1726168023780%26to%3D1726254423780%26panelId%3D87%26width%3D1000%26height%3D500%26scale%3D1%26tz%3DEurope%252FRome%26render%3D1&wi
dth=1000 HTTP/1.1\" 500 96 \"-\" \"Grafana/11.2.0\"\n"}

@github-project-automation github-project-automation bot moved this to 🗂️ Needs Triage / Escalation in Sharing squad Oct 1, 2024
@lucychen-grafana lucychen-grafana moved this to 🗂️ Needs Triage / Escalation in Sharing squad Oct 1, 2024
@Seokyun-Ha
Copy link

I encountered the same chrome_crashpad_handler: --database is required error with version 3.11.6. After reverting to 3.11.0, the issue was resolved 🙏

@enricojonas
Copy link

Hi, facing same issue using the Docker image up to 3.11.6. Rolling back to 3.11.2 "solves" the issue.

@enricojonas
Copy link

I have now upgraded to 3.11.6 docker image and the following is required to make it work so it would be nice to get it incorporated into the docker image itself:

          env {
            name  = "XDG_CONFIG_HOME"
            value = "/tmp/.chromium"
          }

          env {
            name  = "XDG_CACHE_HOME"
            value = "/tmp/.chromium"
          }

          env {
            name  = "BROWSER_TZ"
            value = "Europe/Stockholm"
          }

plus capture_timeout = 30s in grafana.ini and more CPU, it seems the performance is much worse with later release or the default timeout has changed in Grafana to 10s, not sure.

muffl0n added a commit to muffl0n/grafana-helm-charts that referenced this issue Dec 13, 2024
muffl0n added a commit to muffl0n/grafana-helm-charts that referenced this issue Dec 13, 2024
…rashpad_handler: --database is required

See grafana/grafana-image-renderer#565

Signed-off-by: Sven Schliesing <[email protected]>
muffl0n added a commit to muffl0n/grafana-helm-charts that referenced this issue Dec 13, 2024
…rashpad_handler: --database is required"

See grafana/grafana-image-renderer#565

Signed-off-by: Sven Schliesing <[email protected]>
@muffl0n
Copy link

muffl0n commented Dec 15, 2024

Workaround contained in the helm chart since 8.8.1, see grafana/helm-charts#3487

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🗂️ Needs Triage / Escalation
Development

No branches or pull requests

7 participants