View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0005163||CentOS-6||NetworkManager||public||2011-10-04 18:07||2011-10-04 18:07|
|Target Version||Fixed in Version|
|Summary||0005163: NetworkManager Prepends /etc/hosts instead of Appends|
|Description||We have a highly customized deployment of CentOS 6.0. We configure system-wide defaults before deployment to end-users. In particular:|
/etc/gconf/gconf.xml.defaults/%25gconf-tree.xml (Proxy servers settings and hosts to ignore in Gnome)
/etc/profile (to include our proxy servers being added to every new user's .bash_profile)
/usr/lib/firefox-3.6/defaults/preferences/firefox.js (to instruct firefox to use our PAC script for every user)
The weird issue comes after changing the hostname. Once the hostname is changed (by just editing /etc/sysconfig/network and restarting) to anything other than localhost.localdomain (or whatever was used during initial setup) we are unable to browse any internet sites. Firefox just times out. After changing it back to the original value by manually editing /etc/sysconfig/network, /etc/hosts, setting "hostname", and restarting /etc/init.d/network Firefox was able to browse sites again.
Eventually what I discovered was that when changing the hostname (tested on both i686 and X86_64) NetworkManager prepends /etc/hosts with the current IP and new FQDN and alias. If I modify /etc/hosts and move the current IP, new FQDN, and alias to the bottom of the file and have 127.0.0.1 localhost.localdomain localhost at the top of /etc/hosts everything works. Sometimes even after doing this when I restart NetworkManager will have automatically edited /etc/hosts and put the information at the top of the file, breaking internet browsing via Firefox.
|Steps To Reproduce||Change the hostname by editing /etc/sysconfig/network and reboot. Firefox will eventually time out.|
|Additional Information||Don't know if this is an issue on a direct/raw internet connection. This may only be specific to our environment (proxy servers and PAC script).|
|Tags||No tags attached.|