LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 04-14-2007, 10:57 PM   #1
veeruk101
Member
 
Registered: Mar 2005
Distribution: Ubuntu 12.04 LTS
Posts: 249

Rep: Reputation: 16
Resolve hostnames to IP


I'm able to ping external addresses, but cannot yet ping their hostnames successfully. So far I haven't configured anything related to the DNS server to use, and am wondering how to go about doing so.

Edit: It might be useful to point out that this question relates to specifying a DNS server to use in my own name resolution, such as for browsing the web, rather than creating/hosting my own DNS server for others to use.

Some tutorials have led me to believe I have to do all sorts of stuff with DNS/BIND configuration files, which seems like something a bit different than what I'm trying to do. I'm basically just trying to specify somewhere my DNS server. Does this have something to do with the ifcfg-eth0 file?

In the GUI version of RHEL I remembered being able to specify primary, secondary, and tertiary DNS servers. What's the command-line equivalent of that functionality from a RHEL (well, CentOS) without GUI?

Where would I get the address of my DNS server? Could I just put in the name of any DNS server out there on the Internet, or does it have to be provided by my ISP in particular? Pardon my ignorance, I'm just getting started.

Thanks.

Last edited by veeruk101; 04-14-2007 at 10:59 PM.
 
Old 04-14-2007, 11:08 PM   #2
macemoneta
Senior Member
 
Registered: Jan 2005
Location: Manalapan, NJ
Distribution: Fedora x86 and x86_64, Debian PPC and ARM, Android
Posts: 4,593
Blog Entries: 2

Rep: Reputation: 326Reputation: 326Reputation: 326Reputation: 326
For command line configuration, you can use:

system-config-network-tui

Or just edit /etc/resolv.conf:

nameserver 208.67.222.222
nameserver 208.67.220.220

The values above are for the OpenDNS DNS servers, which are free to use. You can get your ISP's DNS servers from their web site, usually in the support section.
 
Old 04-14-2007, 11:40 PM   #3
bouchecl
Member
 
Registered: Nov 2005
Location: Quebec
Distribution: Fedora Core / Ubuntu
Posts: 37

Rep: Reputation: 15
Quote:
Originally Posted by veeruk101

Where would I get the address of my DNS server? Could I just put in the name of any DNS server out there on the Internet, or does it have to be provided by my ISP in particular? Pardon my ignorance, I'm just getting started.

Thanks.
Like the previous poster said, check the support section of your ISP web site. You migth want to ping these addresses to see it they're fast.

I personnally like to add 3 nameservers to my /etc/resolv.conf

First: my local DNS server (if you have one)
Second: one of my ISP's DNS (pick the fastest one)
Third: a DNS from a local university (the admins there are usually very good)
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't resolve hostnames Emma77 Debian 12 08-02-2006 04:31 PM
Cannot resolve hostnames BobBuchanan Linux - Networking 1 02-12-2005 05:56 PM
Can't resolve hostnames....need help shaggystyle Linux - Networking 2 08-28-2004 02:20 AM
pppoe seems to connect but cant resolve hostnames mecister Linux - Networking 2 06-23-2004 06:32 PM
resolve hostnames zero_kewl Linux - General 5 09-01-2003 04:00 AM


All times are GMT -5. The time now is 04:02 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration