DIG uses localhost

Hi,

I have these entries in the /etc/esolv.conf:
------------

domain xxxxxx
search yyyyyy
nameserver 127.0.0.1
nameserver  aaaaaaaaaaaaaaaa
nameserver  bbbbbbbbbbbbbbbb

-------------

When I use 'dig' or 'nslookup' command, like 'dig yahoo.com' it uses the localhost as the server.

I do have another system wher the resolv.conf is same, but it uses the first entry in the nameserver, i.e. 'aaaaaaaaaaaaaa'.

Could anyone help me to understand this diff.
Thanks

On this system dig also uses the first nameserver entry, which is 127.0.0.1 (= localhost).

Presumably, you mean /etc/resolv.conf
If the first entry 127.0.0.1 does not have a running name server daemon, dig tries the next server in the list..