Declare DNS servers in my domain register provider

Discussion in 'General' started by raspdroid, Feb 8, 2017.

  1. raspdroid

    raspdroid Member

    I have 2 dns servers in the same static ip.

    hostname - dns1.domain.com
    hostname - dns2.domain.com

    What do i have to put in the control panel of my domain register provider ?

    A records pointed to dns1 and dns2?

    Best regards
     
  2. florian030

    florian030 ISPConfig Developer ISPConfig Developer

    you can not run 2 public dns on the same ip
     
  3. raspdroid

    raspdroid Member

    Thanks for the clarification.

    Then I will use two IPs. In differents locations.

    dns1.domain.com - 80.58.60.150
    dns2.domain.com - 80.58.65.130

    Then in my domain provider control panel do I have to add two A records? dns1 pointer to 80.58.60.150 and dns2 pointer to 80.58.65.130?

    And change provider dns for dns1.domain.com and dns2.domain.com ?

    Best regards
     
  4. raspdroid

    raspdroid Member

    I was referring to the public IP, which I use for each server (Mail, Web, Db ...) But in the local network each host has a unique IP. Did you mean local IP or public IP?
     
  5. sjau

    sjau Local Meanie Moderator

    Why not? I do the same. Denic won't allow it for .de TLDs but you can do it for other TLDs.

    Code:
    dig roleplayer.org
    
    ; <<>> DiG 9.9.5-9+deb8u9-Debian <<>> roleplayer.org
    ;; global options: +cmd
    ;; Got answer:
    ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 22539
    ;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 2, ADDITIONAL: 3
    
    ;; OPT PSEUDOSECTION:
    ; EDNS: version: 0, flags:; udp: 4096
    ;; QUESTION SECTION:
    ;roleplayer.org. IN A
    
    ;; ANSWER SECTION:
    roleplayer.org. 3600 IN A 176.9.139.175
    
    ;; AUTHORITY SECTION:
    roleplayer.org. 1932 IN NS ns5.roleplayer.org.
    roleplayer.org. 1932 IN NS ns6.roleplayer.org.
    
    ;; ADDITIONAL SECTION:
    ns5.roleplayer.org. 1932 IN A 176.9.139.175
    ns6.roleplayer.org. 1932 IN A 176.9.139.175
    
    ;; Query time: 28 msec
    ;; SERVER: 10.0.0.1#53(10.0.0.1)
    ;; WHEN: Wed Feb 08 17:48:31 CET 2017
    ;; MSG SIZE rcvd: 127
    
     
  6. Jesse Norell

    Jesse Norell Well-Known Member

    I think it depends on what the registrar allows (what checks they implement).
     
  7. raspdroid

    raspdroid Member

    Hi,
    I tested the dns of sjau in my domain (GoDaddy) and can be added. Check if the names are different but not if the ip is different.

    I added an A record dns1 pointing to my public ip. It looks like this. I will add the second and try to change the domain dns to see if it works.

     
    Last edited: Feb 9, 2017
  8. raspdroid

    raspdroid Member

    Hello!

    Public IP: 150.200.2.56
    Local IP's:
    gateway: 192.168.1.1
    web1.example.com - 192.168.1.50
    dns1.example.com - 192.168.1.51
    dns2.example.com - 192.168.1.52


    DNS-Zone:
    Server: dns1.example.com
    Client: clientC1
    Zone(SOA): example.com.
    NS: dns1.example.com
    E-mail: [email protected]
    Refresh: 7200 seconds
    Retry: 540 seconds
    Expire: 604800 seconds
    Minimum: 3600 seconds
    TTL: 3600 seconds

    Records:
    A example.com. 150.200.2.56
    A mail 150.200.2.56
    A www 150.200.2.56
    MX example.com. mail.example.com
    NS example.com. dns2.example.com
    NS example.com. dns1.example.com
    TXT example.com. v=spf1 mx a ~all

    WEB1.example.com (ispconfig3 master server)
    DNS1.example.com
    DNS2.example.com


    On the router I have open port 53 to dns1.example.com (192.168.1.51) but I do not know which port to open for dns2.example.com (192.168.1.52) because the router does not allow me to open the same port for more than one ip address. Is it possible to use another port? For example the 54?

    In System --> Server Services
    web1.example.com --> Web/Yes - File/Yes the rest No.
    dns1.example.com --> DNS/Yes - the rest No.
    dns2.example.com --> DNS/Yes - the rest No. :: Is mirror of Server: dns1.example.com


    Can you tell me what I'm doing wrong?

    Best regards
     
  9. Jesse Norell

    Jesse Norell Well-Known Member

    That is exactly the issue, and why @florian030 said:
    DNS always uses port 53, there is no way to run 2 separate DNS servers behind a NAT by a simple port forward. If your router/firewall supports a load balancer (particularly one that monitors if the servers it's forwarding to are actually answering), look into using that. If all you have is port forwards, pick one server or the other and forward there.
     
  10. raspdroid

    raspdroid Member

    Thank you!

    I changed dns2.example.com another public IP (150.200.2.57). In the master database added to the root user with privileges for the public ip 150.200.2.57.

    In the firewall of dns2.example.com (ufw) I opened the ports udp/tcp 53 and tcp 3306, on the router of dns2.example.com I opened ports udp/tcp 53 and tcp 3306.

    In ISPConfig 3 --> System --> Server Config --> dns2.example.com I changed the IP address 192.168.1.52 to 150.200.2.57

    In Domain register I changed A record dns2 150.200.2.56 to dns2 150.200.2.57

    Then,

     

Share This Page