Public bug reported: Hi,
I'm having my server configured to send a notification by e-mail if a systemd unit failed. Today, I received thousands of emails within a short time, because once there is something wrong with rabbitmq, e.g. configuration, the unit settings will try to restart every few seconds, and forever. i.e. /usr/lib/systemd/system/rabbitmq-server.service contains Restart=on-failure RestartSec=10 which will flood the system with endless restart attempts and blow up log files. Reason: By default, systemd uses DefaultRestartSec=100ms DefaultStartLimitIntervalSec=10s DefaultStartLimitBurst=5 which means, that systemd tries to restart a service after 100ms, and if it is restarted more than LimitBurst times within the interval, systemd gives up. (see man systemd.unit) But, when setting RestartSec=10 without seting the other values accordingly, you inhibit systemd's protection against continuous failures. Usually, systemd would restart rabbitmq not more than 5 times and give up. With RestartSec=10 DefaultStartLimitIntervalSec=10s DefaultStartLimitBurst=5 this doesn't work anymore and it restarts forever. If you change RestartSec, you need to change StartLimitIntervalSec as well. And if you choose to change, you should change RestartSteps= RestartMaxDelaySec= as well, to increase the Restart time. Although these values can be overridden by the admin (if he knows), this is a really nasty trap and can break the whole system. ProblemType: Bug DistroRelease: Ubuntu 24.04 Package: rabbitmq-server 3.12.1-1ubuntu1.2 ProcVersionSignature: Ubuntu 6.8.0-100.100-generic 6.8.12 Uname: Linux 6.8.0-100-generic x86_64 ApportVersion: 2.28.1-0ubuntu3.8 Architecture: amd64 CasperMD5CheckResult: unknown CloudArchitecture: x86_64 CloudID: hetzner CloudName: hetzner CloudPlatform: hetzner CloudSubPlatform: metadata (http://169.254.169.254/hetzner/v1/metadata) Date: Sun Feb 22 00:33:33 2026 PackageArchitecture: all SourcePackage: rabbitmq-server UpgradeStatus: No upgrade log present (probably fresh install) ** Affects: rabbitmq-server (Ubuntu) Importance: Undecided Status: New ** Tags: amd64 apport-bug noble -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/2142374 Title: rabbitmq-server goes berserk in case of failure due to wrong systemd unit settings To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/rabbitmq-server/+bug/2142374/+subscriptions -- ubuntu-bugs mailing list [email protected] https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
