24 April 2015
Living With Network Manager
The gnome-network-manager is embedded in Ubuntu and Mint in the main Unity and Cinnamon desktop installs so deeply that you cannot get rid of it. When we want to manage our connection manually, instinctively we want to get rid of it, unfortunately a huge amount of work by the desktop environment developers has gone into insuring that this will either break networking or your desktop environment or both.
After wasting many hours after upgrades and installs I’ve finally figured out how to live with it by editing its configuration files!
Update 2019
Network-Manager should respect a network/interfaces file, although its’ applets will show the network-manager network configuration rather than the real configuration.
The easiest way to disable network manager is with systemctl mask network-manager. Disable will not prevent a service that requests network-manager as a pre-requisite from loading it. Mask will cause systemd to not only disable it but to lie that it is running to services requesting it. The NM applet will show networking as not running which is better than showing the wrong configuration as running.
Your connections are configured in files in: /etc/NetworkManager/system-connections
An example of a manual configuration file for a connection is:
[802-3-ethernet]
duplex=full
mac-address=11:22:33:49:94:24
[connection]
id=Wired connection 1
uuid=3a2e741c-9834-4784-bbbc-65209eba6fb5
type=802-3-ethernet
domain="brainbuz.org"
[ipv6]
method=auto
[ipv4]
method=manual
dns=172.1.1.2;172.3.1.3;
dns-search=brainbuz.org;
address1=172.1.1.41/16,172.1.1.1
You can force network manager to reload with the command service network-manager
restart (which may change to systemctl with the switch to systemd), but I’ve found that nm doesn’t always respect my changes if I make them while running so it is better to stop the service before editing the file and start it again after.
If you remove the Network Manager Applet and want to manually launch it the command is nm-applet