LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   error in bind configuration (https://www.linuxquestions.org/questions/linux-newbie-8/error-in-bind-configuration-921269/)

jaideep.t 12-30-2011 03:00 PM

error in bind configuration
 
friends, i was tring DNS services of linux and configured zone file included in my named.conf as :

; Zone file for funmail.com
;
; The full zone file
;
$ORIGIN funmail.com.
$TTL 3D
@ IN SOA ns1.funmail.com. webmaster.funmail.com. (
201112301 ; serial#
3600 ; refresh, seconds
3600 ; retry, seconds
3600 ; expire, seconds
3600 ) ; minimum, seconds
IN NS ns1.funmail.com. ; Inet address of nameserver

mail MX 10 192.168.100.1 ; Primary mail exchanger
localhost IN A 192.168.100.1
ns1 IN A 192.168.100.1
funmail1.com IN A 192.168.100.1
service IN A 192.168.100.1
www IN CNAME service.funmail.com.


Now i am not able to ping my hostname also dig my host name or ip through dig funmail.com A (hostname) or dig -x 192.168.100.1 didn't work. While it is working for dig ns1.funmail.com.

bathory 12-30-2011 03:37 PM

Hi and welcome to LQ,
Quote:

<-snip->
funmail1.com IN A 192.168.100.1
<-snip->
Unless that "1" after funamail is a typo, the above should read:
Code:

funmail.com IN A 192.168.100.1
You can also use one of the following
Code:

@ IN A 192.168.100.1
    IN A 192.168.100.1 ; leave at least one blank space

For the reverse zone you need to create a zone file for the 100.168.192.in-addr.arpa zone and give the PTR record(s) for your host(s)

Regards

jaideep.t 01-02-2012 09:37 AM

Thanks bathory for pointing out error as '1' in funmail1.com. Now still i am not able to ping my hostname as funmail.com whereas able to do "dig funmail.com A". I do configured reverse zone file also bt want to get all errors and queries resolved for forward lookup and then will practice on reverse lookup.

bathory 01-02-2012 10:57 AM

Hi,

Quote:

Thanks bathory for pointing out error as '1' in funmail1.com. Now still i am not able to ping my hostname as funmail.com whereas able to do "dig funmail.com A"
Couldn't be. If you can resolve funmail.com , then you should be able to ping it too.
What happens when you ping funmail.com? If you see the correct IP (192.168.100.1), but you get a "host unreachable", then there should be a firewall in between blocking icmp packets.

jaideep.t 01-02-2012 01:20 PM

Thanks bathory i found out it was due to secondary lan card connecting to dsl due to which its trying to get name resolution from isp dns, after disabling same its working fine. Could you please check below conf for reverse zone if i done something wrong bcoz i am not able to dig -x 192.168.100.1

;
; Filename: 192-168-100.zone
;
; Zone file for 192.168.100.x
;
$TTL 3D
@ IN SOA www.funmail.com. hostmaster.funmail.com. (
200303301 ; serial number
8H ; refresh, seconds
2H ; retry, seconds
4W ; expire, seconds
1D ) ; minimum, seconds
NS www ; Nameserver Address
2 PTR bigboy.funmail.com.
3 PTR smallfry.funmail.com.
4 PTR ochorios.funmail.com.
5 PTR reggae.funmail.com.

bathory 01-02-2012 01:43 PM

Quote:

i am not able to dig -x 192.168.100.1
Well, first of all you don't have a PTR record for 192.168.100.1, so this is expected. The second and more serious error is your NS record. You should use the FQDN of the dns server.
Code:

$TTL 3D
@ IN SOA www.funmail.com. hostmaster.funmail.com. (
200303301 ; serial number
8H ; refresh, seconds
2H ; retry, seconds
4W ; expire, seconds
1D ) ; minimum, seconds
  NS www.funmail.com. ; Nameserver Address FQDN
1 PTR www.funmail.com.
2 PTR bigboy.funmail.com.
3 PTR smallfry.funmail.com.
4 PTR ochorios.funmail.com.
5 PTR reggae.funmail.com.

Regards

jaideep.t 01-03-2012 11:46 AM

Thanks bathory now i am able to do dig -x 192.168.100.1bt just one more query for reverse dns when i am trying to do ping -a 192.168.100.1 from a window pc whose DNS is set as 192.168.100.1 its not able to name resolution whereas its able to ping funmail.com. Also i am not able to do host 192.168.100.1 it says connection timed out, no server to reach.

bathory 01-03-2012 03:21 PM

Quote:

when i am trying to do ping -a 192.168.100.1 from a window pc whose DNS is set as 192.168.100.1 its not able to name resolution whereas its able to ping funmail.com.
Could be the windows dns cache. To flush it, run:
Code:

ipconfig /flushdns
Quote:

Also i am not able to do host 192.168.100.1 it says connection timed out, no server to reach.
Again could be a firewall or other network problem, like the one you had before.


All times are GMT -5. The time now is 02:58 PM.