Linux: Hostname change break X apps


There exists a really lame problem on X (X11,XFree86,Xorg,…): The authentification or identification mechanism when a new application wants to connect to the X server (read: show a window) works over the hostname.

This is fine if you live in 1990, but wireless network have dhcp and dhcp server can send a hostname to your machine making your X session stop working: You can’t start any programs anymore.

NetworkManager (what also make the little icon on GNOME/KDE desktops, pre-installed on Ubuntus et.al., developed by RedHat) uses dhclient to retrieve a hostname.

The magic words to add to your dhclient.conf are:

send host-name "hoot";
supersede host-name "hoot";

If you use pump (instead of dhclient), you shouldn’t have this problem, as it doesn’t set the hostname (see the man page).

A mailing list entry on this topic starts here: http://lists.freedesktop.org/archives/xorg/2004-August/002772.html

  1. No comments yet.
(will not be published)

  1. No trackbacks yet.