Find the answer to your Linux question:
Results 1 to 8 of 8
Hi all! I have just know Linux 2 month ago. I want config DNS but i don't know how to. Please help me, thanks very much....
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Nov 2007
    Posts
    4

    Help me config DNS Step by Step!!


    Hi all! I have just know Linux 2 month ago. I want config DNS but i don't know how to. Please help me, thanks very much.

  2. #2
    Blackfooted Penguin daark.child's Avatar
    Join Date
    Apr 2006
    Location
    West Yorks
    Posts
    4,393
    Are you trying to create a DNS server or trying to configure DNS settings for your internet connection?

  3. #3
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    Linux for 2 months doesn't sound like he is ready for a server yet.

    Setting you your machine to use DNS is not hard.

    To configure your DNS look at the resolve.conf file that should be with your other conf files. The format is simple

    Fist line will be the domains that you want appended to any host you are trying to look up. If you don't want to use any this is ok too. The next lines will be the ip addresses of the dns servers you want to use.

    ex:

    search domain1.com domain2.com domain3.com etc....
    nameserver 10.10.10.1
    nameserver 10.10.10.2
    nameserver 10.10.10.2

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  4. #4
    Just Joined!
    Join Date
    Nov 2007
    Posts
    4
    @ daark.child: Thanks for your helping, I want config DNS for sever and I do it on VMWARE. The server is virtual and the real PC is client.

    @Lazydog : Thanks very much. I did but when I ping my-domain-name.com it give me an error: Unknow host my-domain-name.com.

    Please help me!!!

  5. #5
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    phananhtuan post your resolve.conf file and your named.conf file.
    Also are you trying to run named in a chroot env.?
    Also post the output from the following:

    Code:
    ps -ef | grep named
    I would also suggest that yopu buy the following book for setup and troubleshooting:

    http://www.oreilly.com/catalog/dns4/

    I can get you setup with a dns server, the problem is if you don't have the basics down and there is a problem you are going to be lost in finding and fixing that issue.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  6. #6
    Just Joined!
    Join Date
    Nov 2007
    Posts
    4
    Thanks very much, I think you right, i need have basic first, I don't know bind use to do, when config DNS, we must use it?

    Quote Originally Posted by Lazydog View Post
    phananhtuan post your resolve.conf file and your named.conf file.
    Also are you trying to run named in a chroot env.?
    Also post the output from the following:

    Code:
    ps -ef | grep named
    I would also suggest that yopu buy the following book for setup and troubleshooting:

    oreilly.com -- Online Catalog: DNS and BIND, Fourth Edition

    I can get you setup with a dns server, the problem is if you don't have the basics down and there is a problem you are going to be lost in finding and fixing that issue.

  7. #7
    Linux Guru Lazydog's Avatar
    Join Date
    Jun 2004
    Location
    The Keystone State
    Posts
    2,677
    It would all depend on how many hosts you have.
    You could just use your hosts file for resolving your local machines.

    In your hosts file you need something like this:
    Code:
    127.0.0.1       localhost.localdomain   localhost
    xxx.xxx.xxx.xxx host1.domain.com host1
    xxx.xxx.xxx.xxx host2.domain.com host2
    xxx.xxx.xxx.xxx host3.domain.com host3
    and so on.

    In your host.conf you should have
    Code:
    order hosts,bind
    Then in your resolve.conf you should have something like this;
    Code:
    nameserver <isp dns server1>
    nameserver <isp dns server2>
    nameserver <isp dns server3>
    Then when you goto lookup your own host your machine will first look at the HOSTS file first to resolve and when it doesn't find it it will use your ISP's DNS servers to resolve.

    Regards
    Robert

    Linux
    The adventure of a life time.

    Linux User #296285
    Get Counted

  8. #8
    Just Joined!
    Join Date
    Nov 2007
    Posts
    4
    Quote Originally Posted by Lazydog View Post
    It would all depend on how many hosts you have.
    You could just use your hosts file for resolving your local machines.

    In your hosts file you need something like this:
    Code:
    127.0.0.1       localhost.localdomain   localhost
    xxx.xxx.xxx.xxx host1.domain.com host1
    xxx.xxx.xxx.xxx host2.domain.com host2
    xxx.xxx.xxx.xxx host3.domain.com host3
    and so on.

    In your host.conf you should have
    Code:
    order hosts,bind
    Then in your resolve.conf you should have something like this;
    Code:
    nameserver <isp dns server1>
    nameserver <isp dns server2>
    nameserver <isp dns server3>
    Then when you goto lookup your own host your machine will first look at the HOSTS file first to resolve and when it doesn't find it it will use your ISP's DNS servers to resolve.

    Thanks very much by your helping. I did it successful. Have a good day

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •