Slave (secoundary) ISPconfig powered BIND synconization

Discussion in 'Installation/Configuration' started by pavljiks, Dec 19, 2010.

  1. pavljiks

    pavljiks New Member

    First of all thanks for such clean ISP control panel.
    Actually i started my installation by reading ISPConfig 3 manual.

    I used a multi server scenario (actually second instance is only running BIND, so i could synchronize dns records).

    Before that i have only used to work with djbdns, didn't have to manage lot dns records. But now i realized that knowing Bind wouldn't harm.

    So back to business. I installed first master server accourding to manual
    Ubuntu 10.10 and ISPConfig everything went smood.

    After that I installed another Ubuntu server in expert mode with only mysql and bind (as ISPConfig 3 manuals says).

    i have domain dns hosted somewhere else where i have to A records: A A (same host as NS1 with running ISPConfig panel). A

    for hosted domains i have dns records using this template:



    Server config from ISPConfig control panel perspective. Looks fine:

    also both server /etc/hosts files contains ns1,ns2,server1 hosts records. hostname [-f] returns full address.

    I create (which i am about to host) using my custom template.
    I also add ns2 Ip in field "Allow zone transfers to
    these IPs (comma separated list)" and "Also Notify". In final it also creates a correct
    so it correctly modifies named.conf.local adding

    zone "" {
    type master;
    allow-transfer {;};
    also-notify {;};
    file "/etc/bind/";

    So finally the problem is on ns2 host
    in his logs i see record:
    named[1325]: client received notify for zone '': not authoritative

    and until i myself doesn't create a slave record on ns2 it doesn't fetch domain info. until i modify by hand ns2 named.conf.local
    zone "" {
    type slave;
    masters {; };
    file "/etc/bind/";

    Have i done something wrong. How i can configure ns2 name server to automatically syncronize changes (new domains) from ns1.
  2. pavljiks

    pavljiks New Member

    To make it simpler i just need to:

    Every time I add a new domain/zone to my
    master, I have to edit named.conf on my slave server as well.

    So my question: Are there any automatic solutions out there to create this
    new zone in named.conf on the slave DNS server as well?
  3. falko

    falko Super Moderator ISPConfig Developer

    You must create the slave zone on the slave server in ISPConfig (DNS > Secondary DNS > Secondary Zones).
  4. pavljiks

    pavljiks New Member

    So does it mean slave server doesn't have to have "Is mirror of Server" mark, as it says in manual.
    Maybe i have to enable root login on ns2. Or how else changes are populated to secoundary zones.
  5. till

    till Super Moderator Staff Member ISPConfig Developer

    There are different methods of syncing a slave dns server. The easiest one is to use the builtin ispconfig mirroring function. In that case, you do not have to do anything manually like creating slave records in the dns manager. Everything is syncaed automatically.

    The alternative way is to not enable mirroring in ispconfig and then create dns slave records on the secondary server with ispconfig.

    You should not use both methods together, as this will cause the bind setup to get corrupted and bind may not start then anymore or delivers wrong results.
  6. pavljiks

    pavljiks New Member

    Finally after reinstalling ns2 server i manage add slave zones using ispconfig control panel. There was still a small fix on ns2 with permissions. chmod 777 /etc/bind/slave hellped.

    Till what exactly do you mean mirror function. that glusterfs and so on from manual (3.3 Mirror setup)?

    BTW: on both servers keeps poping same lines:

    Dec 20 19:38:01 server1 named[1477]: reloading configuration succeeded
    Dec 20 19:38:01 server1 named[1477]: managed-keys-zone ./IN: loading from master file managed-keys.bind failed: file not found
    Dec 20 19:38:01 server1 named[1477]: managed-keys-zone ./IN: loaded serial 0
    Dec 20 19:38:01 server1 named[1477]: reloading zones succeeded

    Do i have to fix something?
    Last edited: Dec 20, 2010
  7. till

    till Super Moderator Staff Member ISPConfig Developer

    yes and no. I refer to a small part of the mirror setup, but for dns mirroring there is no glusterfs needed. The configuration is mirrored by ispconfig internally without the need of external software and dns consists just out of configuration files without any data payload to be mirrored. Glusterfs is used in that setup only for data mirroring (websites and email).

    So basically to enable mirroring of dns records between two ispconfig servers, you install them as normal master / slave setup without glusterfs and the switch on mirroring in the server settings. Thats all. ISPConfig will then perform every configuration cahnge on boths servers, so if aou add a zone on the master, it gets added on the slave as well. Same with zone updates etc. This kind of mirroring is not limited totwo servers, you can use as many mirror slaves as you need.
    Last edited: Dec 20, 2010

Share This Page