It's not clear why we rescheduled a service auto restart while a stop job for the unit was pending. The comment claims that the unit shouldn't be restarted but the code did reschedule an auto restart meanwhile. In practice that was rarely an issue because the service waited for the next auto restart to be rescheduled, letting the queued stop job to be proceed and service_stop() to be called preventing the next restart to complete. However when RestartSec=0, the timer expired right away making PID1 to reschedule the unit again, making the timer expired right away... and so on. This busy loop prevented PID1 to handle any queued jobs (and hence giving no chance to the start rate limiting to trigger), which made the busy loop last forever. This patch breaks this loop by skipping the reschedule of the unit auto restart and hence not depending on the value of u->restart_usec anymore. Fixes: #13667
System and Service Manager
Details
Most documentation is available on systemd's web site.
Assorted, older, general information about systemd can be found in the systemd Wiki.
Information about build requirements is provided in the README file.
Consult our NEWS file for information about what's new in the most recent systemd versions.
Please see the Code Map for information about this repository's layout and content.
Please see the Hacking guide for information on how to hack on systemd and test your modifications.
Please see our Contribution Guidelines for more information about filing GitHub Issues and posting GitHub Pull Requests.
When preparing patches for systemd, please follow our Coding Style Guidelines.
If you are looking for support, please contact our mailing list or join our IRC channel.
Stable branches with backported patches are available in the stable repo.
