DNS not resolving

I have configured my solaris 9 box to obtain a IP from the DHCP server which is on windows, I have also set up the DNS with domain name and name servers under /etc/resolv.conf

I can ping a ip address I just cant seem to ping hostnames, theres probaly something im not doing. I have looked through other threads and have tryed there methods and fixes but nothing seems to work. Any ideas for a fix?

trye checking your /etc/nsswitch.conf

under hosts : it says files dns

Unless somethings missing somewhere else :frowning:

What is the output from nslookup when you input a valid hostname?

ahh when I nslookup a valid hostname is comes back to me and says

Server: servername01.mp.company-name.co.uk
address 100.0.0.111

**servername01.mp.company-name.co.uk "cant find cad60: server failed"

When I boot the machine up in the boot up process it appears it cant get a IP address it says:

"unable to get my IP address: gethos" Theres quite a bit more but if you need that aswell I shall have to copy it

Any help is appreciated im running out of ideas!

Is your box SPARC or x86?
Can you see your interface as UP when you issue the ifconfig -a command?
Can you ping your own interface?

Its a SPARC box when Issue the ifconfig -a command it shows le0 and hme0 both as UP, they only other thing I can think of is when I boot up it shows a different gateway address. Is there any way to change this?

Ahh!

You can delete the route and add it manually as root in the command line with:
# route delete default <ip address of current gateway>
# route add default <ip address of new gateway> 1 #type the space 1 at the end

Also, check your network mask. You can use the ifconfig command to do it in the command line:

ifconfig hme0 netmask <netmask>

If they were indeed wrong, edit /etc/defaultrouter and add your gateway address, and /etc/netmasks, to make sure they set properly once you reboot.

Well I gave up and installed solaris 9, I think it was to do with the config files from when it was on the NIS but who knows! Thanks alot guys for helping me one day I hope to be able to give advice out instead of just taking but hey thats the joy of learning :slight_smile: