Setting up a Virtualmin DNS Cluster

For virtual host DNS, with parent domain DNS at the registrar

This document details the steps to set up a DNS cluster using two Virtualmin servers. The parent domain’s DNS will remain at the registrar, while DNS for all other virtual hosts will be managed by the Virtualmin cluster. Keeping the parent domain at the register avoids the need for glue records.

Server Details

  • Server Alpha (Master): alpha.techspecuk.org
  • Server Beta (Slave): beta.techspecuk.org
  • Public Nameservers: ns1.techspecuk.org (points to Alpha’s IP) and ns2.techspecuk.org (points to Beta’s IP). These must be configured at your domain registrar.

Prerequisites

Configure network access:

On both the Alpha and Beta servers, open the necessary firewall ports for DNS and Webmin cluster communication.

  • Port 53 (TCP and UDP): For DNS queries.
  • Port 953 (TCP): For rndc.
  • Port 10000 (TCP): For Webmin/Virtualmin access.
  • Port 10001 (TCP and UDP): For BIND zone transfers.

Ensure BIND is installed:

Confirm BIND DNS Server is installed on both servers using your package manager. For example:

dnf install bind bind-utils

Confirm registrar DNS records:

Ensure your domain registrar has ns1.techspecuk.org and ns2.techspecuk.org pointing to the public IP addresses of Alpha and Beta respectively. Crucially, do not use glue records.

Link the servers and create the cluster

On Alpha (alpha.techspecuk.org):

  • Log in to Virtualmin
  • Navigate to Webmin > Webmin > Webmin Servers Index.
  • Add the secondary server:
    • Click Register a new server.
    • Enter the IP address for the Beta server
    • provide its root username and password
    • click Save.
  • Configure the DNS cluster:
    • Navigate to the DNS cluster settings.
    • Go to Servers > BIND DNS Server > Cluster Secondary Servers.
    • Select the Beta server from the menu.
    • Set Create secondary on slave when creating locally? to Yes.
    • Click Add Now.
Repeat the process on Beta (beta.techspecuk.org), adding Alpha (alpha.techspecuk.org) as the slave server.

Configure the Virtual DNS

 

 

Setting up a Virtualmin DNS cluster

 

For virtual host DNS, with parent domain DNS at the registrar

This document details the steps to set up a DNS cluster using two Virtualmin servers. The parent domain’s DNS will remain at the registrar, while DNS for all other virtual hosts will be managed by the Virtualmin cluster.

Server details

  • Server Alpha (Master): alpha.techspecuk.org
  • Server Beta (Slave): beta.techspecuk.org
  • Public Nameservers: ns1.techspecuk.org (points to Alpha’s IP) and ns2.techspecuk.org (points to Beta’s IP). These must be configured at your domain registrar.

Phase 1: Prerequisites

  1. Configure network access:

    On both the Alpha and Beta servers, open the necessary firewall ports for DNS and Webmin cluster communication.

    • Port 53 (TCP and UDP): For DNS queries.
    • Port 953 (TCP): For rndc.
    • Port 10000 (TCP): For Webmin/Virtualmin access.
    • Port 10001 (TCP and UDP): For BIND zone transfers.
  2. Ensure BIND is installed:

    Confirm BIND DNS Server is installed on both servers using your package manager. For example:

    • dnf install bind bind-utils
  3. Confirm registrar DNS records:

    Ensure your domain registrar has ns1.techspecuk.org and ns2.techspecuk.org pointing to the public IPs of Alpha and Beta respectively. Crucially, do not use glue records.

Phase 2: Add secondary server to the cluster

On Alpha (alpha.techspecuk.org, the Master server):

  1. Log in to Virtualmin:

    Access the Virtualmin control panel.

  2. Go to the Webmin Servers Index:

    Navigate to Webmin > Webmin > Webmin Servers Index.

  3. Add the secondary server:

    • Click Register a new server.
    • Enter the IP address for the Beta server, provide its root username and password, then click Save.

Phase 3: Configure the DNS cluster

On Alpha (alpha.techspecuk.org, the Master server):

  1. Navigate to the DNS cluster settings:

    Go to Servers > BIND DNS Server > Cluster Secondary Servers.

  2. Add the secondary server to the cluster:

    • Select the Beta server from the menu.
    • Set Create secondary on slave when creating locally? to Yes.
    • Click Add Now.

Phase 4: Configure the Virtualmin DNS template

On Alpha (alpha.techspecuk.org, the Master server):

  1. Navigate to the default template:

    Go to System Settings > Server Templates > Default Settings > BIND DNS Domain.

  2. Set the nameservers for new virtual hosts:

    • In Primary DNS server hostname, enter ns1.techspecuk.org.
    • In Additional manually configured nameservers, enter ns2.techspecuk.org.
    • Click Save.
  3. Disable DNS for the parent domain:

    For the virtual server managing techspecuk.org, disable the DNS domain feature in System Settings > Features and Plugins. This ensures Virtualmin does not attempt to host DNS for the parent domain.

Phase 5: Create your virtual host

When creating a new virtual server (e.g., virtualhost.com), Virtualmin will automatically create a master DNS zone on Alpha, populate it with NS records pointing to ns1.techspecuk.org and ns2.techspecuk.org, and synchronize a slave zone to the Beta server. This sets up the virtual host to use your private nameservers with automatic synchronization.

 

Your Title Goes Here

 

 

Setting up a Virtualmin DNS cluster

 

For virtual host DNS, with parent domain DNS at the registrar

This document details the steps to set up a DNS cluster using two Virtualmin servers. The parent domain’s DNS will remain at the registrar, while DNS for all other virtual hosts will be managed by the Virtualmin cluster.

Server details

  • Server Alpha (Master): alpha.techspecuk.org
  • Server Beta (Slave): beta.techspecuk.org
  • Public Nameservers: ns1.techspecuk.org (points to Alpha’s IP) and ns2.techspecuk.org (points to Beta’s IP). These must be configured at your domain registrar.

Phase 1: Prerequisites

  1. Configure network access:

    On both the Alpha and Beta servers, open the necessary firewall ports for DNS and Webmin cluster communication.

    • Port 53 (TCP and UDP): For DNS queries.
    • Port 953 (TCP): For rndc.
    • Port 10000 (TCP): For Webmin/Virtualmin access.
    • Port 10001 (TCP and UDP): For BIND zone transfers.
  2. Ensure BIND is installed:

    Confirm BIND DNS Server is installed on both servers using your package manager. For example:

    • dnf install bind bind-utils
  3. Confirm registrar DNS records:

    Ensure your domain registrar has ns1.techspecuk.org and ns2.techspecuk.org pointing to the public IPs of Alpha and Beta respectively. Crucially, do not use glue records.

Phase 2: Add secondary server to the cluster

On Alpha (alpha.techspecuk.org, the Master server):

  1. Log in to Virtualmin:

    Access the Virtualmin control panel.

  2. Go to the Webmin Servers Index:

    Navigate to Webmin > Webmin > Webmin Servers Index.

  3. Add the secondary server:

    • Click Register a new server.
    • Enter the IP address for the Beta server, provide its root username and password, then click Save.

Phase 3: Configure the DNS cluster

On Alpha (alpha.techspecuk.org, the Master server):

  1. Navigate to the DNS cluster settings:

    Go to Servers > BIND DNS Server > Cluster Secondary Servers.

  2. Add the secondary server to the cluster:

    • Select the Beta server from the menu.
    • Set Create secondary on slave when creating locally? to Yes.
    • Click Add Now.

Phase 4: Configure the Virtualmin DNS template

On Alpha (alpha.techspecuk.org, the Master server):

  1. Navigate to the default template:

    Go to System Settings > Server Templates > Default Settings > BIND DNS Domain.

  2. Set the nameservers for new virtual hosts:

    • In Primary DNS server hostname, enter ns1.techspecuk.org.
    • In Additional manually configured nameservers, enter ns2.techspecuk.org.
    • Click Save.
  3. Disable DNS for the parent domain:

    For the virtual server managing techspecuk.org, disable the DNS domain feature in System Settings > Features and Plugins. This ensures Virtualmin does not attempt to host DNS for the parent domain.

Phase 5: Create your virtual host

When creating a new virtual server (e.g., virtualhost.com), Virtualmin will automatically create a master DNS zone on Alpha, populate it with NS records pointing to ns1.techspecuk.org and ns2.techspecuk.org, and synchronize a slave zone to the Beta server. This sets up the virtual host to use your private nameservers with automatic synchronization.