configure dns in centos


 
Thread Tools Search this Thread
Operating Systems Linux Red Hat configure dns in centos
# 1  
Old 08-08-2011
configure dns in centos

Hi, how do I set the DNS in centos.

I don't mean of creating DNS server, but setting what should be the DNS server of centos.

I mean to what server he should go in order to translate url into ip
# 2  
Old 08-08-2011
ur question is not clear
i mean in LAN or public u want,

u want to create new DNS server in ur LAN ? go through the below URL
HOWTO: Setting Up Your Own Local DNS Server - Mark S. Kolich
# 3  
Old 08-08-2011
Quote:
Originally Posted by venikathir
ur question is not clear
i mean in LAN or public u want,

u want to create new DNS server in ur LAN ? go through the below URL
HOWTO: Setting Up Your Own Local DNS Server - Mark S. Kolich
No, I do NOT want to create a DNS server.

I want to tell the centos what is the ip of the DNS server.
Currently for some reason it behave as if it doesn't know any ip.

I mean how do I tell the centos that 8.8.8.8 should be the DNS server that the computer use?
# 4  
Old 08-08-2011
There's probably a sysconf-* command, but the direct approach would be adding the line
Code:
nameserver 8.8.8.8

in /etc/resolv.conf.
This User Gave Thanks to pludi For This Post:
# 5  
Old 08-08-2011
Quote:
Originally Posted by pludi
There's probably a sysconf-* command, but the direct approach would be adding the line
Code:
nameserver 8.8.8.8

in /etc/resolv.conf.
can you elaborate more about the sysconf-* command.

Because I tried to use it but I could not.
I got a message "command not found ".

Last edited by programAngel; 08-08-2011 at 12:58 PM..
# 6  
Old 08-08-2011
All the Red Hat derivatives that I know (CentOS, RHEL, Fedora) have commands to configure the system. I never used them since I'm more comfortable editing the config files myself, based on templates, so I actually had to consult with Doctor Google on what they're called: system-config-xxx where xxx are various categories like network, ...
This User Gave Thanks to pludi For This Post:
# 7  
Old 08-08-2011
Hey how are you.
I'm a Solaris admin but I have been doing a lot of RHEL administration lately. No matter what UNIX or Linux distro I have work with, the /etc/resolve.conf file is used to point a server to the DNS server. If you don't want to use a editor like vi, then use this command.

Example your DNS server's IP is 10.0.0.1
Code:
echo nameserver 10.0.0.1 >>  /etc/resolve.conf

This should be what you see;
Code:
cat /etc/resolve.conf 
nameserver 10.0.0.1

You can also use the GUI.
System --> Administration --> Network
you can edit the the interfase in this GUI.

I hope this helps

Last edited by bitlord; 08-08-2011 at 06:33 PM..
This User Gave Thanks to bitlord For This Post:
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

How can i configure ipv6 on centos?

HI Forum, i was trying to configure ipv6 on my centos box with 2 physical interface bonded as bond0. what all things need to change? Regards, Ben (0 Replies)
Discussion started by: bentech4u
0 Replies

2. Red Hat

DNS Server Setup Centos 6.5 Issues

I am having a bit of trouble getting my CENTOS 6.5 DNS server to work correctly in our testlab environment. Lab network is 10.8.0.0/24 in which we all access from 10.7.0.0.0/24 && 10.0.0.0/24. Here are my configs: options { listen-on port 53 { 127.0.0.1; 10.8.0.19;}; #listen-on-v6 port 53 {... (2 Replies)
Discussion started by: metallica1973
2 Replies

3. Homework & Coursework Questions

Configure DNS in rhel6.3

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: cant configure dns in virtual box. im using rhel6.3. i have a cd containing rhel which the professor provided us.... (2 Replies)
Discussion started by: rpmacaspac
2 Replies

4. Shell Programming and Scripting

How to configure time zone using POSIX format in Centos 5?

I was in process of developing a new script to configure a time zone. After some study I got the unix utility /usr/bin/tzselect to get the user inputs. Now I am able to configure the time zone depending on the user inputs except for the POSIX format. root >/usr/bin/tzselect Please identify a... (1 Reply)
Discussion started by: kalpeer
1 Replies

5. Red Hat

Cannot configure TL-WN727N wireless usb in centos 6.2

hi everybody, iam using 32 bit centos 6.2 on my machine. i have purchase TP-LINK, TL-WN727N wireless usb, but i was not able to install on my desktop. i was not able to find drivers for centos 6.2 official site of TPLINK. $ uname -a Linux workstation 2.6.32-220.el6.i686 #1 SMP Tue Dec 6... (0 Replies)
Discussion started by: paruhang
0 Replies

6. Linux

How to Install and configure Jira And Confulence in Centos 5.5

Please Give me Step by step Instruction Or Video Tutorial For installing and configuring Jira And Confulence in Centos 5.5 , What are the Requirements For Installing and Configuring , wht are the Softwares need for it to work perfectly ... pls reply thanks in advance .... :wall: (1 Reply)
Discussion started by: babinlonston
1 Replies

7. IP Networking

Configure DNS

I am running Solaris 2.6 Server on a Sparc 10 and I was wondering how I can manually specify a DNS server to resolve hostnames. Any help will be greatly appreciated. And also I have created a file in the /etc dir named defaultrouter and added th IP address of my router, but when I ping another... (15 Replies)
Discussion started by: jskillet
15 Replies

8. Solaris

configure DNS server on solaris

Hello evrybody I need to know how i can implement and configure DNS server in solaris9 and i need to understand which files i modified it to do that Thanks all (8 Replies)
Discussion started by: asafwat
8 Replies

9. UNIX for Advanced & Expert Users

How to configure DNS

My OS is sun solaris7,(sun sparc),i want connect inernet and my computer in my company intranet.After i configure proxy server,i still can't conncet internet.I guess whether the DNS is configured correctly. who can help me???Thank you very much!!! (6 Replies)
Discussion started by: q30
6 Replies

10. IP Networking

trying to configure DNS address in Solaris

hi to all. I'm trying to use the sendmail command to generate some reports and I cant use it. The mails i try to send simply won't go out, instead I receive a response from the system sayng that the host is unknown. I think the problem is in the DNS configuration (or the IMAP/SMTP servers). ... (3 Replies)
Discussion started by: ldrojasm
3 Replies
Login or Register to Ask a Question