Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

cannot resolve hostname

Status
Not open for further replies.

whirlpool6

Technical User
Sep 2, 2007
58
JP
hello everyone.

i am using red hat linux server. i would like to access files but then the hostname can not be resolved. i then found out that this hostname is not listed in /etc/host. is there other ways to look up this hostname other than by updating /etc/host? i can not ping the hostname but i can ping the ip address. this must surely be because of the resolve issue..

pls advise... thanks a lot.
 
I think you would need a local DNS server to resolve local IP addresses. Just edit the /etc/hosts file and put it in there

Norm
 
Just add to your /etc/hosts the ip address and host name like this

10.0.0.1 test1.yahoo.com

save the file

then ping test1.yahoo.com it will point to 10.0.0.1 right?

I guess this way will work, but for permanant solution you will need a DNS server, or I don't know make this linux your DNS server? Either way will work.
 
is there no other way which does not involve editing /etc/host?

pls advise... thanks a lot.
 
Can you be a little more spacific. How do you want to access the server? What type of server? Are we talking local or public access? Is it on a local network?



 
@OP
I hope you aren't confusing yourself with NetBIOS/NetBEUI. You can only connect to machines using IP addresses in a TCP/IP network. The moment you start touching computer names, you need to resolve them. Your options are 1) hosts files 2) WINS 3) DNS. Is there more to your scenario that you haven't told us because this should all be common knowledge to all who deal with IP networking.




--== Anything can go wrong. It's just a matter of how far wrong it will go till people think its right. ==--
 
its like this, i would like to access servers on a lan (local network) setting. i am using a linux server to access pcs. now there are so many pcs in my network and i want to access them using hostnames (computer names, whatever it is called). but i cant add them all up in /etc/host...

i have consulted this with my boss and he said that i need to install something in my linux. this is what has been confusing me... wht do i have to install?

what are WINS by the way? i am not really familiar with networking and most especially with linux...

pls help..
thanks a lot
 
WINS or Windows Internet Name Service is like DNS. While a DNS server is a lookup for for FQDN (Fully Qualified Domain Name), a WINS server is a lookup for NetBIOS names.

So lets figure out what you have in your network environment. Are you using Microsoft's Active Directory service in your network? If you do, then you have a fully working DNS server. All you have to do then is to just edit the file /etc/resolv.conf and add in these 2 lines

Code:
search [i][domain_name][/i]
nameserver [i][dns_server_ip][/i]

Replace [domain_name] & [dns_server_ip] with whatever is applicable in your environment.

--== Anything can go wrong. It's just a matter of how far wrong it will go till people think its right. ==--
 
hello zeland...

may i know how to check if im using Microsoft's Active Directory? i really dont know about this and this is not our network... its the clients network and im only accessing it using a vpn.
 
When your clients startup their desktops (Windows XP/2k/NT4), do they have a login screen which allows then to select a domain name?

--== Anything can go wrong. It's just a matter of how far wrong it will go till people think its right. ==--
 
Thats good. Now you need to figure out the IP of the DNS server. You should be able to find this from any of the client 's network setting.

--== Anything can go wrong. It's just a matter of how far wrong it will go till people think its right. ==--
 
Seriously man, he just spoon fed you the entire solution. It's hard for me to believe you're in charge of any network/system.
 
On you Windows Client, checkout: Control Panel -> Network Connection

--== Anything can go wrong. It's just a matter of how far wrong it will go till people think its right. ==--
 
hello nerbonne... this is really not my job... i am not a network/system administrator... and i have stated this beforehand that i am a newbie when it comes to this...

thanks zeland for your help.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top