I make heavy use of the ping utility on a daily basis and it absolutely galls me that Ubuntu cannot ping hostnames by default. I need to use the nmblookup utility to find the ip address of the machine I want to ping and then ping that ip address… primitive, silly, unnecessarily complex… I feel a rant about idiotic default settings and legal gymnastics surrounding the universe repository coming up so I’ll just get on with the post. 😀
1) Back up and edit the /etc/nsswitch.conf file by copying and pasting the following commands:
sudo cp /etc/nsswitch.conf /etc/nsswitch.conf.original
gksu gedit /etc/nsswitch.conf
2) Add wins
to the hosts
directive:
hosts: files mdns4_minimal [NOTFOUND=return] wins dns mdns4
3) Install WINBIND:
sudo apt-get install winbind
4) Ping away. 🙂
Thanks, I always forget to install winbind and wonder why it´s not pinging by name.
By: Guest on August 8, 2011
at 11:31 pm