Setting a network hostname doesn’t work

hostnamenetworking

I'm on a Kubuntu 11.10 and I'm having trouble setting a hostname on the network.

I already tried changing send host-name "myhostname" in /etc/dhcp/dhclient.conf or /etc/dhcp3/dhclient.conf with a networking restart after that (even a reboot).

My hostname is still new-host-4 or new-host-5. I assume it's the DHCP server who gave me these names.

I also know that the servers allows these request since iPhones, Macs can set their hostnames and the hostname I ask is not in use.

Any idea what to do ?

Best Answer

Some routers only use the netbios hostname.

On Debian you can

sudo apt-get install samba

and if your /etc/hostname is set correctly this will show up in the network without a restart.

This works for RaspberryPi, BeagleboneBlack and as far as I can remember also with Ubuntu.

Related Question