Friday, January 25, 2008

Making peace with NetworkManager

Being new to the Linux laptop scene, I've struggled with getting the network settings just right. I've always been more comfortable with text config files, but switching wireless networking settings is something that's best handled in a UI.

I've finally tweaked the network config and NetworkManager settings to behave properly.

I enabled the NetworkManager service: chkconfig NetworkManager on. Now whenever Gnome starts there's a little networking icon in the Notification Area. From there I can left-click to switch networks, config wireless, etc.

Next I took care of the delayed boot time when disconnected from the network (waiting for dhclient to time out). I disabled 'Activate device when computer starts' on both eth0 and wlan0. This can be done by system-config-network, or by editing /etc/sysconfig/networking/devices/ifcfg-{eth0,wlan0}. If I ever need network access from a non-GUI login, I simply ifup eth0.

The biggest difference that annoyed me was NetworkManager ignoring the Fedora init script's DHCP client config /etc/dhclient-eth0.conf. We have Win2k3 DNS/DHCP servers, so I need send fqdn.server-update and send host-name clauses in the dhclient config. The short story is, whenever NetworkManager started the interface, no one could resolve my laptop's name.

I finally discovered that NetworkManager uses /etc/dhclient.conf. I add the two magic lines to that file, point, click, I'm good to go.

Networking, finally, 'just works'.

No comments: