Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

Configure Zentyal as Backup Domain Controller

· 7 min read · Home Tech

In this article
  1. What Zentyal’s Directory Module Actually Is
  2. Prerequisites Before You Start
  3. Step-by-Step: Joining Zentyal as a Backup DC
  4. Common Problems and How to Fix Them
  5. Zentyal vs. Windows Server as a Backup DC
  6. Costs and Support Considerations
  7. Alternatives to Zentyal as a Backup DC
  8. Frequently Asked Questions

Yes, you can configure Zentyal as a backup domain controller (BDC) for an existing Samba-based Windows domain. Zentyal’s Directory module uses Samba 4, so a Zentyal server can join an Active Directory domain as a secondary domain controller and automatically replicate user accounts, group policies, and DNS zones from the primary controller.

What Zentyal’s Directory Module Actually Is

Zentyal is a Linux distribution that packages Samba 4, Bind9, and other services behind a web-based administration panel. The Directory module turns a Zentyal server into a full domain controller for Windows clients, supporting both classic NT4-style domains and Active Directory domains. In Samba 4 terms, a “backup domain controller” is a read-only domain controller (RODC) or a writable secondary DC, depending on how you join it. Zentyal’s web interface simplifies the process, but the underlying operations are standard Samba commands like samba-tool domain join.

This matters because many small businesses start with a single Windows Server or a single Zentyal DC, then want redundancy. A backup DC keeps authentication working if the primary goes offline, and it can also host file shares and DNS. Zentyal’s implementation is not a separate “backup mode”; it is a real second DC that participates in replication.

Prerequisites Before You Start

Before joining a Zentyal server to an existing domain as a backup DC, check these requirements:

  • A working primary domain controller – either Windows Server (2008 R2 or later) or another Samba 4 DC. Zentyal cannot create a backup DC from an NT4-style domain; it must be an Active Directory domain.
  • Both servers must be able to resolve each other’s DNS names. The Zentyal server should use the primary DC as its DNS server during installation.
  • Time synchronization is critical. Kerberos authentication fails if clocks drift more than a few minutes. Install NTP and point it to the primary DC or an external time source.
  • Administrator credentials for the domain – typically the Administrator account or a user with Domain Admin rights.
  • A static IP address for the Zentyal server. DHCP is possible but not recommended for a DC.

If you are setting up Zentyal from scratch, install the base system, then install the Directory module from the Zentyal package repository. Do not configure Samba manually; let Zentyal manage the configuration files.

Step-by-Step: Joining Zentyal as a Backup DC

The exact steps depend on your Zentyal version, but the process is stable across recent releases (6.x and 7.x). Here is the general flow:

  1. Install Zentyal with the Directory module. During installation, choose “Join an existing domain” rather than “Create a new domain.”
  2. Set the hostname to a name that does not conflict with the primary DC, e.g., dc2. The hostname should be set before joining.
  3. Configure network settings in Zentyal’s Network module. Set the DNS server to the primary DC’s IP address. Do not set the domain suffix manually unless you know the DNS zone is properly configured.
  4. In the Directory module, select “Join this domain” and enter the domain name (e.g., example.local) and the administrator credentials.
  5. Zentyal runs the join. It will create a computer account, replicate the database, and set up DNS and Kerberos. This can take several minutes.
  6. After the join, verify that the new DC appears in the domain. On the primary DC, run samba-tool domain info or check Active Directory Users and Computers.

If you are using Zentyal’s command line, you can also run samba-tool domain join example.local DC -UAdministrator manually, but the web interface handles the required configuration files for you.

Common Problems and How to Fix Them

The most frequent issue is DNS. If the Zentyal server cannot find the primary DC’s SRV records, the join fails with “No DNS servers found” or “NT_STATUS_NO_LOGON_SERVERS.” Fix this by ensuring the primary DC’s DNS is authoritative for the domain zone and that the Zentyal server’s resolver points to that DC.

Another common problem is time sync. Kerberos tickets are time-sensitive; if the clocks differ by more than 5 minutes, authentication fails. Install ntp and configure it to sync with the primary DC. You can check with ntpdate -q or chronyc tracking.

Firewall rules can also block replication. Samba uses ports 135, 139, 445, and 49152-65535 for RPC. If you have a firewall between the two DCs, open those ports. On the Zentyal server itself, the firewall should be configured to allow Samba traffic.

If the join succeeds but clients cannot authenticate, check that the Zentyal server is registered in DNS. Run host dc2.example.local from a client. If it fails, add the A record manually or restart the Samba service on the new DC.

Zentyal vs. Windows Server as a Backup DC

Choosing Zentyal over Windows Server for a backup DC usually comes down to cost and administration style. Zentyal is free (with optional paid support), while Windows Server requires a license for each DC. Zentyal’s web panel is simpler for small IT teams, but it does not offer every Windows feature, such as Group Policy Management Console or AD Federation Services.

For a small business that already uses Zentyal as a primary DC, adding a second Zentyal server is natural. For a mixed environment, you can join Zentyal to a Windows domain, but you must be careful with schema updates. Samba 4 supports the schema versions used by Windows Server 2012 and later, but if your Windows DC is older, you may need to upgrade it first.

Performance-wise, a Zentyal backup DC handles authentication and file sharing well for up to a few hundred users. For larger environments, Windows Server with its native DFS-R and AD replication is more robust.

Costs and Support Considerations

The software itself is free, but running a backup DC has hidden costs: hardware, electricity, and time. Zentyal’s community edition includes all features, but you get no official support. If you need a service-level agreement, Zentyal offers paid subscriptions that include access to their repository and support. For a business, the cost of a support contract is often less than a Windows Server license, but you must weigh the learning curve.

Also consider that a backup DC is not a backup of your data. It replicates AD objects, but not file shares unless you configure DFS or rsync. If the primary DC fails, you still need a separate backup strategy for user files.

Alternatives to Zentyal as a Backup DC

If Zentyal does not fit, other options exist:

  • Plain Samba 4 on any Linux distribution – you get the same functionality without Zentyal’s web interface, but you manage everything via command line.
  • Windows Server – the native choice, with full AD features and Microsoft support.
  • FreeIPA – a Red Hat project that provides identity management but uses LDAP and Kerberos, not Samba, so it is not a drop-in replacement for an existing Windows AD domain.
  • JumpCloud or other cloud directory services – these can act as a secondary authentication source, but they are not a true DC and have different replication models.

For most small to medium businesses, Zentyal is a practical middle ground between cost and functionality.

Frequently Asked Questions

Can Zentyal be a backup DC for a Windows Server primary?
Yes. Zentyal uses Samba 4, which implements Active Directory protocols compatible with Windows Server. You can join a Zentyal server to a Windows domain as a secondary DC, and it will replicate AD data. However, you must ensure the Windows domain functional level is 2008 R2 or later.

Does Zentyal backup DC replicate all AD objects?
Yes, by default Samba replicates the entire AD database, including users, groups, GPOs, and DNS zones. You cannot selectively replicate only certain OUs, as you can with Windows Server’s partial replication. This means the Zentyal server holds a full copy of the directory.

What happens if the primary DC fails?
Clients can still authenticate against the Zentyal backup DC because it holds a writable copy of the directory. However, if the primary DC was the only one holding certain FSMO roles (like RID master or PDC emulator), those roles must be transferred to the Zentyal server. You can do this with samba-tool fsmo transfer after the primary is permanently offline.

Can I promote a Zentyal backup DC to primary?
Yes. You can seize the FSMO roles using samba-tool fsmo seize. After that, the Zentyal server becomes the sole DC. You may need to update client DNS settings to point to the new primary.

Is Zentyal backup DC suitable for a large enterprise?
Probably not. Zentyal is designed for small to medium networks. For hundreds of users or multiple sites, Windows Server with proper AD sites and services is more reliable. Zentyal’s web interface also lacks advanced monitoring and troubleshooting tools that enterprise admins expect.

Do I need a separate license for Zentyal?
No. Zentyal is open-source and free to use. If you want professional support, you can buy a subscription, but it is not required for the software to function.