After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 741587 - systemd does not restart NetworkManager.service after crashes
systemd does not restart NetworkManager.service after crashes
Status: RESOLVED FIXED
Product: NetworkManager
Classification: Platform
Component: general
git master
Other Linux
: Normal normal
: ---
Assigned To: NetworkManager maintainer(s)
NetworkManager maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2014-12-16 09:16 UTC by Mikko Rapeli
Modified: 2015-01-12 15:51 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch (878 bytes, patch)
2014-12-16 09:16 UTC, Mikko Rapeli
none Details | Review

Description Mikko Rapeli 2014-12-16 09:16:16 UTC
Created attachment 292794 [details] [review]
patch

If NetworkManager crashes, systemd does not restart it, but it should.

From Debian bug: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=773213

Attached patch tells systemd to restart NetworkManager.service if the binary exited with non-zero return value, like it does whith asserts or crashes.
Comment 1 Thomas Haller 2014-12-16 11:44:47 UTC
This looks like the right thing to do.

Anybody know the reason, we don't do that already?
Comment 2 Dan Winship 2014-12-16 13:34:59 UTC
(In reply to comment #1)
> Anybody know the reason, we don't do that already?

In my experience, NM tends to get automatically restarted via D-Bus auto-activation immediately after crashing. (I've had to "systemctl disable NetworkManager.service" to keep that from happening if I want to start NM under gdb.) So probably no one ever noticed that it doesn't get auto-restarted in other scenarios.

Patch LGTM too.
Comment 3 Dan Williams 2014-12-16 22:22:02 UTC
pushed to git master:
fe95185f6f9f0e3bd3a71024b8b916bca2dc397f