Off late I noticed X applications on my Gentoo installation failing to launch in gnome sessions unless launched within first few seconds. It didn’t seem easily reproducible so it took me a few xdm and os restarts to nail the actual problem.
NetworkManager changes the hostname after connecting to wireless network. However, it doesn’t update xauth with the new hostname, which means .Xauthority file is no longer valid once the hostname is changed, and attempts to launch applications fail with ‘no protocol specified/cannot open display’ messages.
In my case, i believe, ‘etc-update’ was the culprit. Fix is to update /etc/conf.d/hostname with the desired hostname, which is apparently honored by NetworkManager. Once HOSTNAME is set in the conf-file, and OS is rebooted, ‘xhost list’ can be used to validate the .Xauthority contents and hostname can be matched. X applications should start without any trouble.
hey, cfg-update looks interesting, emerging it as im typing this comment. Thanks a lot for the input mate!
the last time i used wicd was a few years back with fedora(afair), and it wasn’t too appealing back then, but im sure it has improved a lot, will take it for a spin sometime😉