Page 1 of 3 123 LastLast
Results 1 to 10 of 22

Thread: [SOLVED] Can't resolve fake domain even after setup split dns

Hybrid View

  1. #1
    Join Date
    Apr 2008
    Location
    Brighton, ON, Canada
    Posts
    89
    Rep Power
    7

    Default [SOLVED] Can't resolve fake domain even after setup split dns

    I have a machine which I am trying to install on. I am using a fake/bogus subdomain (mailserv.rci.ca) for my real domain (rci.ca).

    I have followed the wiki page for split dns. I still cannot get my machine to resolve my fake domain name.

    There are a few posts I found regarding this and I have followed them but still cannot get this to work. Here is the info requested in other posts:

    cat /etc/hosts:
    -----------------------
    Code:
    127.0.0.1 localhost.localdomain localhost mailserv
    192.168.7.101 mailserv.rci.ca mailserv
    cat /etc/resolv.conf:
    -----------------------
    Code:
    search rci.ca
    nameserver 192.168.7.101
    nameserver 24.226.1.93
    dig mailserv.rci.ca mx:
    -----------------------
    Code:
    ; <<>> DiG 9.4.2-P2.1 <<>> mailserv.rci.ca mx
    ;; global options:  printcmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 16627
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0
    
    ;; QUESTION SECTION:
    ;mailserv.rci.ca.               IN      MX
    
    ;; Query time: 0 msec
    ;; SERVER: 192.168.7.101#53(192.168.7.101)
    ;; WHEN: Tue Mar 23 16:01:01 2010
    ;; MSG SIZE  rcvd: 33
    dig mailserv.rci.ca any
    ---------------------------
    Code:
    ; <<>> DiG 9.4.2-P2.1 <<>> mailserv.rci.ca any
    ;; global options:  printcmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 18922
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0
    
    ;; QUESTION SECTION:
    ;mailserv.rci.ca.               IN      ANY
    
    ;; Query time: 0 msec
    ;; SERVER: 192.168.7.101#53(192.168.7.101)
    ;; WHEN: Tue Mar 23 16:01:38 2010
    ;; MSG SIZE  rcvd: 33
    /etc/bind/named.conf.options:
    -----------------------------
    Code:
    options {
            // directory "/var/cache/bind";
            auth-nxdomain no;    # conform to RFC1035
            listen-on-v6 { any; };
    
            directory "/var/named";
            dump-file "/var/named/data/cache_dump.db";
            statistics-file "/var/named/data/named_stats.txt";
            forwarders { 192.168.7.101; };
    };
    include "/etc/bind/rndc.key";
    zone "mailserv.rci.ca" {
            type master;
            file "db.mailserv.rci.ca";
    };

    /var/named/db.mailserv.rci.ca:
    -----------------------------
    Code:
    ;       Addresses and other host information.
    ;
    @       IN      SOA     mailserv.rci.ca. hostmaster.mailserv.rci.ca. (
                                   10118      ; Serial
                                   43200      ; Refresh
                                   3600       ; Retry
                                   3600000    ; Expire
                                   2592000 )  ; Minimum
    ;       Define the nameservers and the mail servers
                   IN      NS      192.168.7.101
                   IN      A       192.168.7.101
                   IN      MX      10 mailserv.rci.ca.
    host `hostname`:
    ----------------------------
    Code:
    Host mailserv.rci.ca not found: 3(NXDOMAIN)
    Any ideas?
    Last edited by strafford; 03-23-2010 at 01:04 PM. Reason: added hostname info

  2. #2
    Join Date
    Apr 2008
    Location
    Brighton, ON, Canada
    Posts
    89
    Rep Power
    7

    Default

    I have also looked at this post about nsswitch.conf but mine was correct.

  3. #3
    Join Date
    Mar 2006
    Location
    Massachusetts
    Posts
    965
    Rep Power
    10

    Default

    Not to state the obvious, but have you verified that DNS is in fact running on the server you set it up on?

  4. #4
    Join Date
    Apr 2008
    Location
    Brighton, ON, Canada
    Posts
    89
    Rep Power
    7

    Default

    Well, not past doing an nslookup on google. Is there anything else I should be checking (I guess I assumed that since it didn't bawk at google.com that it was working fine).

    Code:
    mailserv:~$ nslookup google.com
    Server:         192.168.7.101
    Address:        192.168.7.101#53
    
    Non-authoritative answer:
    Name:   google.com
    Address: 66.249.81.104

  5. #5
    Join Date
    Mar 2006
    Location
    Massachusetts
    Posts
    965
    Rep Power
    10

    Default

    I don't have a definite answer, but a couple of things to look at...

    1) If the DNS server for this fake/bogus domain is running on 192.168.7.101 then I don't think you want a forwarders line to be referencing the same IP. Basically this is forwarding to itself.

    2) I know Red Hat DNS setup a lot better than Ubuntu. Does Ubuntu install DNS chrooted? If so, your config files need to go in another location. Anything in /etc wouldn't be read at DNS startup.

    3) Are you sure your /etc/nsswitch.conf file is correct? It should be setup to use both files (/etc/hosts) and BIND (dns).

    4) Stop your DNS service; restart it and then look in /var/log/messages to see about any error messages or warnings related to the DNS service.

    I'm probably missing something real obvious in your configuration, but it's just not jumping out at me. I know there are a ton of posts about DNS/Split DNS. Have you looked for you "host not found" error?

  6. #6
    Join Date
    Apr 2008
    Location
    Brighton, ON, Canada
    Posts
    89
    Rep Power
    7

    Default

    Quote Originally Posted by soxfan View Post
    1) If the DNS server for this fake/bogus domain is running on 192.168.7.101 then I don't think you want a forwarders line to be referencing the same IP. Basically this is forwarding to itself.
    Ok, changed it to use two DNS servers from IP (I guess I read the Zimbra Wiki Split DNS post wrong).

    Here is my /etc/bind/named.conf.options file:
    Code:
    options {
            auth-nxdomain no;    # conform to RFC1035
            query-source address * port 53;
            directory "/var/named";
            dump-file "/var/named/data/cache_dump.db";
            statistics-file "/var/named/data/named_stats.txt";
            forwarders { 24.226.1.93; 24.226.10.193; };
    };
    include "/etc/bind/rndc.key";
    zone "mailserv.rci.ca" {
            type master;
            file "/var/named/db.mailserv.rci.ca";
    };
    Quote Originally Posted by soxfan View Post
    2) I know Red Hat DNS setup a lot better than Ubuntu. Does Ubuntu install DNS chrooted? If so, your config files need to go in another location. Anything in /etc wouldn't be read at DNS startup.
    Actually I had so much trouble getting the prerequisites for Zimbra installed on Centos 5.4 that I gave up and went w/ Ubuntu.

    Quote Originally Posted by soxfan View Post
    3) Are you sure your /etc/nsswitch.conf file is correct? It should be setup to use both files (/etc/hosts) and BIND (dns).
    Well I was.

    Here is my file:
    Code:
    # /etc/nsswitch.conf
    #
    # Example configuration of GNU Name Service Switch functionality.
    # If you have the `glibc-doc-reference' and `info' packages installed, try:
    # `info libc "Name Service Switch"' for information about this file.
    
    passwd:         compat
    group:          compat
    shadow:         compat
    
    hosts:          files dns
    networks:       files
    
    protocols:      db files
    services:       db files
    ethers:         db files
    rpc:            db files
    
    netgroup:       nis
    I also found this post on Ubuntu 8.04 LTS Server Install Guide and here is my new bind data file as per the DNS section from that post:

    Code:
    ; BIND data file for mydomain.com
    ;
    $TTL    604800
    @       IN      SOA     mailserv.rci.ca. scott.rci.ca. (
                             070726         ; Serial
                             604800         ; Refresh
                              86400         ; Retry
                            2419200         ; Expire
                             604800 )       ; Negative Cache TTL
    ;
    @       IN      NS      mailserv
            IN      MX      10 mailserv
            IN      A       192.168.7.101
    mailserv    IN      A       192.168.7.101
    One thing to note if you are reading this post later for info, change the serial number of your bind data file each time you make a change!

    Quote Originally Posted by soxfan View Post
    4) Stop your DNS service; restart it and then look in /var/log/messages to see about any error messages or warnings related to the DNS service.
    No errors just info.

  7. #7
    Join Date
    Apr 2008
    Location
    Brighton, ON, Canada
    Posts
    89
    Rep Power
    7

    Default

    Last 3 entries from /var/log/messages:

    Mar 26 09:50:57 mailserv -- MARK --
    Mar 26 10:00:18 mailserv kernel: [29375.223301] audit(1269612018.927:4): type=1503 operation="capable" name="sys_resource" pid=5036 profile="/usr/sbin/named" namespace="default"
    Mar 26 10:00:18 mailserv kernel: [29375.239258] audit(1269612018.937:5): type=1503 operation="inode_permission" requested_mask="::r" denied_mask="::r" name="/var/named/db.mailserv.rci.ca" pid=5036 profile="/usr/sbin/named" namespace="default"

  8. #8
    Join Date
    Apr 2008
    Location
    Brighton, ON, Canada
    Posts
    89
    Rep Power
    7

    Default

    Also tried w/ the following bind data file (/var/named/db.mailserv.rci.ca):
    Code:
    ;
    ; BIND data file for mydomain.com
    ;
    $TTL    604800
    @       IN      SOA     mailserv.rci.ca. scott.rci.ca. (
                             070727         ; Serial
                             604800         ; Refresh
                              86400         ; Retry
                            2419200         ; Expire
                             604800 )       ; Negative Cache TTL
    ;
    @       IN      NS      192.168.7.101
            IN      A       192.168.7.101
            IN      MX      10 mailserv.rci.ca

  9. #9
    Join Date
    Nov 2006
    Location
    UK
    Posts
    8,017
    Rep Power
    24

    Default

    If mailserv.rci.ca is the FQDN of your ZCS server then your domain/zone file should be rci.ca.

  10. #10
    Join Date
    Apr 2008
    Location
    Brighton, ON, Canada
    Posts
    89
    Rep Power
    7

    Default

    Quote Originally Posted by uxbod View Post
    If mailserv.rci.ca is the FQDN of your ZCS server then your domain/zone file should be rci.ca.
    Can you please clarify that? You mean in /etc/bind/named.conf[.options]? Also, note that mailserv.rci.ca is a bogus/fake domain name.

Similar Threads

  1. Replies: 13
    Last Post: 10-13-2009, 01:37 PM
  2. Guidance required on DNS setup in sles10
    By simonpope in forum Installation
    Replies: 2
    Last Post: 08-24-2008, 09:55 AM
  3. Invert split domain configuration or stop it
    By fmodola in forum Administrators
    Replies: 0
    Last Post: 08-20-2008, 02:44 AM
  4. Reverse DNS lookups with multiple Domain hosting.
    By carpicker in forum Installation
    Replies: 0
    Last Post: 04-23-2008, 12:14 PM

Posting Permissions

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