-
-
Notifications
You must be signed in to change notification settings - Fork 373
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
Bug: health check flips between unhealthy and healthy with no logs #2270
Comments
@qdm12 is more or less the only maintainer of this project and works on it in his free time.
|
TLDR: pull the latest image and check if it reports as unhealthy still? The Gluetun Docker healthcheck queries the long running Gluetun instance for its health status every 5 seconds. The dial timeout was previously fixed at 3 seconds, so during high bandwidth usage, it's possible the dialing fails within 3 seconds, and so the health is reported as unhealthy, see debug log line:
This is logged at the debug level, since it's not really a big deal and can happen from time to time. It doesn't affect the VPN internal healing either. Now since 6042a9e, the tcp dialing timeouts change, increasing with every failure, from 2 seconds, to 4, 6, 8, and 10 seconds, instead of 3s always, which should allow it to work out during bandwidth stress for example with a 10 seconds timeout. I pushed another commit 1e25372 to increase the retries from 1 to 3. That means it would only report the container as unhealthy after it failed 4 times (4 x 5 seconds = 20 seconds), which means the internal healthcheck can try with the timeouts of 2s, 4s, 6s and 8s (20s total), which should fix this issue I hope. If not let me know, and I can change the internal timeouts from 2/4/6/8/10 to 2/4/10 for example, but I don't think it's necessary 🤔 |
Tested, container still flags as unhealthy even though the torrent downloaded fine in the background. |
This comment was marked as off-topic.
This comment was marked as off-topic.
Same issue |
Is this urgent?
No
Host OS
Synology DSM 7.2
CPU arch
x86_64
VPN service provider
Windscribe
What are you using to run the container
docker-compose
What is the version of Gluetun
Running version latest built on 2024-05-04T16:22:29.394Z (commit ef6874f)
What's the problem 🤔
Mentioned this in issue #2154 but thought it would be better to open a new issue.
The container keeps flipping between healthy and unhealthy when I am downloading a torrent at a high bandwidth (80-100MiB/s). The logs don't seem to update at all beyond the initial healthcheck which shows healthy, even in debug mode so I can't figure out why.
It doesn't seem to be an interruption of the VPN since in the background the torrent downloads fine, except for when the VPN is restarted due to the healthcheck. The torrent is interrupted for a few seconds while vpn restarts, and then works perfectly fine, over and over. I don't know why the healthcheck is flagging as unhealthy when it seems to be working as intended. For example if I am seeding, even for hours at lower bandwidths (1-2 MiB/s), it doesn't seem to make the container unhealthy.
My internet connection is fine and I don't have a firewall setup, so I am not sure what is causing this behaviour.
Share your logs (at least 10 lines)
Share your configuration
The text was updated successfully, but these errors were encountered: