I am trying to configure a Ceph dashboard behind Traefik, but have issues with setting up service health checks in Traefik.
Here is my scenario:
There are 3 Ceph managers available to serve the dashboard at port 7000.
However, the dashboard is only ever served over one of the 3 managers.
The other 2 managers reply with status 500 and a corresponding error message:
{"status": "500 Internal Server Error", "detail": "Keep on looking", "request_id": "efc1d3ba-66cc-4138-9d11-8bf8fe51af34"}
Only the active manager replies with status 200.
Previously, we used Traefik v1, where we were able to set a service healthcheck to always point to the active manager.
Traefik v1 config
# Ceph UI
[frontends.ceph]
backend = "ceph"
[frontends.ceph.routes.route1]
rule = "Host:ceph.example.com"
[backends.ceph.healthcheck]
interval = "10s"
path = "/"
[backends.ceph.loadbalancer]
method = 'drr'
[backends.ceph.servers.server1]
url = "http://192.168.1.1:7000"
[backends.ceph.servers.server2]
url = "http://192.168.1.2:7000"
[backends.ceph.servers.server3]
url = "http://192.168.1.3:7000"
After migrating to Traefik v3, the healthcheck does not seem to work correctly anymore.
Traefik v3 config
http:
routers:
# Ceph UI
ceph:
service: ceph@file
rule: Host(`ceph.example.com`)
services:
ceph:
loadBalancer:
servers:
- url: http://192.168.1.1:7000
- url: http://192.168.1.2:7000
- url: http://192.168.1.3:7000
healthCheck:
path: /
interval: 10s
timeout: 3s
status: 200
In the Traefik dashboard, all 3 servers are displayed as healthy for about 10s, then the 2 inactive managers are displayed as unhealthy for about 3s, then they appear as healthy again.
When I try to reach the Ceph dashboard over Traefik, I randomly get either the HTML page or status 500.
Is this a bug or did I miss something in the Traefik configuration?