Main Content

Slow boot and terminal start on Linux boxes

Archive - Originally posted on "The Horse's Mouth" - 2008-06-05 21:23:53 - Graham Ellis

Now this was a mystery. I had two Linux boxes which booted perfectly when used inhouse, but very slowly indeed (10 minutes plus) when in use on a customer site. Very awkward really - we would test out the systems in Melksham and find them fine, but then they would fail in Bristol. Even calling up a terminal window took minutes!

A clue ... with pauses at networking, sendmail and sm-client ... the problem had to be DNS (domain name service) related, but I checked all the systems - good and bad - and found the same name servers in /etc/resolv.conf and the same host line in /etc/nsswitch.conf, namely
hosts files dns

It turns out that the problem is in /etc/hosts. My machines have names like holt.wellho.net, trowbridge.wellho.net, iford.wellho.net and easterton.wellho.net and if the /etc/hosts file contained both the short (trowbridge) and long (trowbridge.wellho.net) names against 127.0.0.1, it worked fine - but if the fully qualified name was missing it was going to DNS and failing to find it away from the office.

Isn't it gauling how - once you have spend what seems like an eternity trackinging something like this down - the final answer is so darned obvious!