LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-28-2014, 03:18 PM   #1
vincix
Member
 
Registered: Feb 2011
Distribution: Centos 6.7, 7
Posts: 589

Rep: Reputation: 52
simple DNS server problem


I am trying to set up a simple DNS server in CentOS 6.5.
This is what my named.conf looks like:

Quote:
options {
listen-on { 127.0.0.1; 192.168.1.107; };
};

zone vinci.rr in { type master; file "/var/named/vinci.rr"; };
And this is my zone file "vinci.rr"
Quote:
$TTL 86400;
$ORIGIN vinci.rr.
@ IN SOA ns1 hostmaster.vinci.rr (
2014012801; serial
10800; refresh
3600; retry
604800; expire
86400; minimum
)
IN NS ns1 ; in the domain

ns1 IN A 192.168.1.107;
www IN A 192.168.1.107;
IN A 192.168.1.107;
Whenever I try to ping (from the host itself) vinci.rr, I get this error:

error (unexpected RCODE REFUSED) resolving 'vinci.rr.net/A/IN': 1.1.1.1 (-> there's a public ip there instead of the 1s).

What should I be looking for?

Last edited by vincix; 01-28-2014 at 03:37 PM.
 
Old 01-28-2014, 04:02 PM   #2
bathory
LQ Guru
 
Registered: Jun 2004
Location: Piraeus
Distribution: Slackware
Posts: 11,642

Rep: Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539Reputation: 1539
Quote:
Whenever I try to ping (from the host itself) vinci.rr, I get this error:

error (unexpected RCODE REFUSED) resolving 'vinci.rr.net/A/IN': 1.1.1.1 (-> there's a public ip there instead of the 1s).
This means that you are not using your dns as a resolver and instead you're going out to the net and query the real authoritative name server for the rr.net.domain. The response you get from that nameserver is "REFUSED" due to its configuration.
In order to use your nameserver, edit /etc/resolve.conf and add it before any other nameserver
 
Old 01-28-2014, 04:45 PM   #3
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: CentOS 6 (pre-systemd)
Posts: 2,693

Rep: Reputation: 725Reputation: 725Reputation: 725Reputation: 725Reputation: 725Reputation: 725Reputation: 725
Your zone file is for the .rr TLD. Your query is in the .net TLD. The two do not intersect. Maybe you want to do a zone file for the domain vinci.rr.net.
 
Old 01-28-2014, 04:56 PM   #4
vincix
Member
 
Registered: Feb 2011
Distribution: Centos 6.7, 7
Posts: 589

Original Poster
Rep: Reputation: 52
The thing is that I've already edited /etc/resolv.conf. I've inserted nameserver 192.168.1.107
It's the same. Moreoever, after I reboot my computer a new line keeps showing up in the resolv.conf: "search net" or something like that, I'm not exactly sure now. I guess it might be connected.
 
Old 01-28-2014, 06:47 PM   #5
myatthu
Member
 
Registered: Jan 2014
Distribution: CentOS, Fedora, Ubuntu
Posts: 108

Rep: Reputation: 18
Looks like you are using dhcp ip address and your router/dhcp server configured to append .net
Either change dhcp config or configure your test client static ip and change resolve.conf again make sure point to your dns server.
 
Old 01-29-2014, 05:29 AM   #6
vincix
Member
 
Registered: Feb 2011
Distribution: Centos 6.7, 7
Posts: 589

Original Poster
Rep: Reputation: 52
The actual problem was that I was pinging "vinci.rr" which wasn't associated with the host's IP. If I had pinged ns1.vinci.rr or www.vinci.rr it would have worked. But I did change to static anyway and there's no .net suffix anymore, so that might have something to do with it too.
 
  


Reply

Tags
dns failure, dnsserver


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
[SOLVED] DNS Server Related Problem: ** server can't find w3icon.com: SERVFAIL tonmoy Linux - Server 5 09-09-2013 04:26 AM
simple DNS server (dnsmasq) with Windows hosts? Umanga Linux - Server 3 07-29-2011 08:17 AM
LXer: DNS Part 1: Introduction and a Simple Server LXer Syndicated Linux News 0 12-14-2007 09:00 AM
Simple NAT/DNS Problem whohasit Linux - Networking 4 07-19-2005 03:08 PM
DNS (BIND)... Probably a simple problem dvergatal Linux - Networking 4 04-18-2005 11:04 AM


All times are GMT -5. The time now is 07:47 PM.

Main Menu
Advertisement
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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration