Question for DNS

  • Hello Everybody,


    I am using I-MSCP for quite a while now and have about 260 Websites under authority of I-MSCP.


    Maybe someone knows a solution for this problem:


    My I-MSCP Server is running bind DNS. The Zones are perfectly managed by the mscp software and working well with multiple IPs etc. (Btw. VERY good work from the developers :-)!)


    Is there any supported way to setup a secondary/slave DNS server, whitch recieves the Zones from the master ?
    Ideally without having to create the zones manually on the slave server.


    I saw some options in automated installer, but i found no further documentation / explanation etc.


    It would be great if this can be accomplished somehow.



    With best regards


    John

  • In my case I use a secondary server installed by hand (nothing related to imscp) by following part of this instructions.
    http://www.dmo.ca/blog/20081009143754/


    Once you've set up the slave server, you will have to create an entry such as this for every domain.


    Code
    1. zone "example.com" {
    2. type slave;
    3. file "example.com";
    4. masters { i-mscp_server_ip; };
    5. };


    That's what I have in my setup

  • Yes, but thats not really flexible..
    Is there a flexible solution for the zones to be created on slave automatically? If you have huge amount of domains this would be a huge help...

  • Are You still interested in this?
    I can give You my solution: Apache alias + wget + python.

  • On master server:


    Add in /etc/apache2/httpd.conf:

    Code
    1. Alias /domaintransfer-lmRRuOBwJ4A3jY6Qwm3oEJd /etc/bind<Directory /etc/bind> Order Deny,Allow Deny from all Allow from SECONDARY DNS IP</Directory>


    Add in /etc/bind/named.conf.options (just add needed line under 'options'):

    Code
    1. options { also-notify { SECONDARY DNS IP; };};


    Add in /etc/imscp/bind/bind.data:
    SECONDARY_DNS = SECONDARY DNS IP


    On secondary dns:
    Add in /etc/bind/named.conf:

    Code
    1. include "/etc/bind/named.conf.sync";


    run command:

    Code
    1. touch /etc/bind/named.conf.sync


    Add in /etc/bind/named.conf.options (just add needed line under 'options'):

    Code
    1. options { allow-notify { MASTER SERVER IP; };};


    create python script:


    Schedule newly created python script in cron as often as You wish. I did that once for 10 minutes.


    On master server:
    run /var/www/imscp/engine/setup/imscp-setup


    That's all!
    Gl & HF

    Edited once, last by Raisen ().

  • I have done the Raisen way, and it works perfect. Thanks for that.


    But I need to add a little more to get it working.


    In /etc/bind/named.conf.options I also added on both servers

    Code
    1. // If you want to use them on your servers /etc/resolv.confforwarders { ISP_DNS1; ISP_DNS2};// Allow query for specific computers.allow-query { any; };// Allow specific IP to get DNS Zone filesallow-transfer { SLAVE_OR_MASTER_IP; };


    The last line in Raisens howto says:

    Code
    1. On master server:
    2. run /var/www/imscp/engine/setup/imscp-setup


    But if I run it, it will change to: "SECONDARY_DNS = no" in /etc/imscp/bind/bind.data
    Is that correct or do I have something missing somewhere?


    I'm using i-mscp 1.0.3.0 Stable.


    /Mami

    Edited once, last by mami ().