Difference between revisions of "Talk:NetworkManager"

From ArchWiki
Jump to: navigation, search
(Hostname_problems Entry: re)
m (Add `systemctl start NetworkManager` for newbies.: rm closed discussion)
 
(35 intermediate revisions by 14 users not shown)
Line 1: Line 1:
== GNOME 3 and nm-applet ==
+
== Add recommendation to install dhclient ==
  
Looks like GNOME 3 doesn't need nm-applet any more. Moreover, it competes with the shell's network agent for new connections. Does anyone copy this? Should this be mentioned on the page?
+
NetworkManager tries to use dhclient by default but falls back to dhcpcd if dhclient is not installed.
  
== Hostname_problems Entry ==
+
However, if NetworkManager uses dhcpcd, NetworkManager does not terminate dhcpcd when systemd tells NetworkManager to shut down. See [https://mailman.archlinux.org/pipermail/arch-general/2014-April/035827.html this mailing list thread].
  
Isn't the suggested solution a little bit overkill? (Revert to using dhcpcd with NetworkManager) Also kind of assumes that dhclient is the problem. Which I do not believe to be the case.
+
I wanted to suggest some ideas here before making any drastic changes.
Rather then switch back to dhcpcd you could just have dhclient push the hostname.
+
A la "send host-name" in the dhclient.conf. [[User:Ortango|Ortango]] ([[User talk:Ortango|talk]]) 18:57, 11 March 2013 (UTC)
+
  
:I agree, especially the linked [https://bbs.archlinux.org/viewtopic.php?id=152376 forums thread] is confusing at least. It seems like a solution for a different problem with ''hostname problems'' only as a side effect. -- [[User:Lahwaacz|Lahwaacz]] ([[User talk:Lahwaacz|talk]]) 12:40, 21 August 2013 (UTC)
+
I think there should be a recommendation to install dhclient in the "Base install" section, above "VPN support". Installing dhclient is preferred because it plays nicely with NetworkManager. Also, dhclient requires no configuration for NetworkManager to use it.
  
== <s>systemd</s> ==
+
If adding a recommendation in the "Base install" section is too much, I would at least like to add this issue to the troubleshooting section so others are not baffled by NetworkManager leaving dhcpcd running.
  
the openbox section still refers to /etc/rc.conf. Does the note still apply? --[[User:Qqqqqqqqq9|Qqqqqqqqq9]] ([[User talk:Qqqqqqqqq9|talk]]) 18:01, 4 April 2013 (UTC)
+
[[User:KlipperKyle|KlipperKyle]] ([[User talk:KlipperKyle|talk]]) 03:54, 10 April 2014 (UTC)
  
:Fixed, thanks for reporting. -- [[User:Lahwaacz|Lahwaacz]] ([[User talk:Lahwaacz|talk]]) 11:55, 21 August 2013 (UTC)
+
:The behaviour is obviously intentional as per the provided systemd unit:
 +
{{hc|/usr/lib/systemd/system/NetworkManager.service|2=
 +
...
 +
# NM doesn't want systemd to kill its children for it
 +
KillMode=process
 +
}}
 +
:Ideally this problem would be resolved in the NetworkManager itself, feel free to submit a bug.
 +
:-- [[User:Lahwaacz|Lahwaacz]] ([[User talk:Lahwaacz|talk]]) 06:28, 10 April 2014 (UTC)
  
== <s>Fails to auto-connect</s> ==
+
::Thanks, Lahwaacz. It appears the NetworkManager team already knows about the dhcpcd issue ([https://bugzilla.gnome.org/show_bug.cgi?id=723746 Bug 723746]).
 +
::Also, after more poking around it appears that dhclient is left running after stopping NetworkManager. However, NetworkManager actually restarts dhclient when NetworkManager starts up. (NetworkManager does not restart dhcpcd when initializing.)
 +
::Shall I add a section about dhcpcd not properly restarting to the troubleshooting section?
 +
::[[User:KlipperKyle|KlipperKyle]] ([[User talk:KlipperKyle|talk]]) 02:20, 12 April 2014 (UTC)
  
I was having an issue with getting NM to auto connect to known APs. I ran 'systemd-analyze blame' and found that I still had dhcpcd@<myadapter>.service enabled and it was taking a very long time to initialize. I disabled it, and now NM works perfectly.  I noticed that in the wiki page it doesn't mention to disable this service, only to disable your previous wifi management system. Hope this helps!
+
:::Adding a note to our wiki will not help to resolve the real problem - please add comments to the upstream bug report you referenced. They are missing the detail about {{ic|KillMode}} in systemd unit.
[[User:MagnumXopus|MagnumXopus]] ([[User talk:MagnumXopus|talk]]) 00:37, 24 July 2013 (UTC)
+
:::Additionally, could you test if resetting {{ic|KillMode}} back to default {{ic|control-group}} actually works? I.e. create the following file:
 
+
{{hc|/etc/systemd/system/NetworkManager.service.d/killmode.conf|<nowiki>
:I added a note instead of the inaccurate section, {{ic|1=systemctl --type=service}} will listt such services. -- [[User:Lahwaacz|Lahwaacz]] ([[User talk:Lahwaacz|talk]]) 12:34, 21 August 2013 (UTC)
+
[Service]
 +
KillMode=control-group
 +
</nowiki>}}
 +
:::-- [[User:Lahwaacz|Lahwaacz]] ([[User talk:Lahwaacz|talk]]) 09:06, 12 April 2014 (UTC)

Latest revision as of 15:18, 5 February 2015

Add recommendation to install dhclient

NetworkManager tries to use dhclient by default but falls back to dhcpcd if dhclient is not installed.

However, if NetworkManager uses dhcpcd, NetworkManager does not terminate dhcpcd when systemd tells NetworkManager to shut down. See this mailing list thread.

I wanted to suggest some ideas here before making any drastic changes.

I think there should be a recommendation to install dhclient in the "Base install" section, above "VPN support". Installing dhclient is preferred because it plays nicely with NetworkManager. Also, dhclient requires no configuration for NetworkManager to use it.

If adding a recommendation in the "Base install" section is too much, I would at least like to add this issue to the troubleshooting section so others are not baffled by NetworkManager leaving dhcpcd running.

KlipperKyle (talk) 03:54, 10 April 2014 (UTC)

The behaviour is obviously intentional as per the provided systemd unit:
/usr/lib/systemd/system/NetworkManager.service
...
# NM doesn't want systemd to kill its children for it
KillMode=process
Ideally this problem would be resolved in the NetworkManager itself, feel free to submit a bug.
-- Lahwaacz (talk) 06:28, 10 April 2014 (UTC)
Thanks, Lahwaacz. It appears the NetworkManager team already knows about the dhcpcd issue (Bug 723746).
Also, after more poking around it appears that dhclient is left running after stopping NetworkManager. However, NetworkManager actually restarts dhclient when NetworkManager starts up. (NetworkManager does not restart dhcpcd when initializing.)
Shall I add a section about dhcpcd not properly restarting to the troubleshooting section?
KlipperKyle (talk) 02:20, 12 April 2014 (UTC)
Adding a note to our wiki will not help to resolve the real problem - please add comments to the upstream bug report you referenced. They are missing the detail about KillMode in systemd unit.
Additionally, could you test if resetting KillMode back to default control-group actually works? I.e. create the following file:
/etc/systemd/system/NetworkManager.service.d/killmode.conf
[Service]
KillMode=control-group
-- Lahwaacz (talk) 09:06, 12 April 2014 (UTC)