This is usually because your hostname won't resolve. The best
way to fix this is to make sure that /etc/hosts
is
consoluted by your resolver first by editing /etc/host.conf
and putting the hosts
line first. Then, simply put an
entry in /etc/hosts
for your local machine. If you have
no local network, change your localhost
line:
127.0.0.1 foo.bar.com foo localhost
Otherwise, simply add another entry for your host. Consult the relevant man pages for more details.
You should be able to successfully ping -c1 `hostname`
when you're done.