Introduction
In a cPanel DNS cluster environment, it is possible for DNS zones to be unintentionally synchronized to the wrong server due to a misconfigured cluster relationship or incorrect synchronization settings. When this occurs, a cluster member may accumulate a large number of DNS zone files that it should not be managing.
These unmanaged zones can increase administrative overhead, consume unnecessary disk space, and create confusion during DNS troubleshooting. In some cases, they may also lead to unexpected DNS behavior if cluster synchronization continues to propagate incorrect records.
This guide explains how to safely identify and remove unmanaged DNS zones from a cluster member while preserving the zones that are legitimately managed by the server. The procedure includes creating backups, identifying managed domains, disabling cluster synchronization, removing unwanted zone files, rebuilding the DNS configuration, and re-enabling cluster services.
Prerequisites
Before proceeding, ensure the following requirements are met:
Access Requirements
- Root or sudo access to the server.
- Access to WHM with administrative privileges.
- Access to all DNS cluster configuration settings.
Backup Requirements
- A complete backup of the
/var/nameddirectory. - Sufficient disk space available to store temporary backups and relocated zone files.
Verification Requirements
- Review the current DNS cluster configuration and identify the root cause of the unwanted zone synchronization.
- Confirm which domains and DNS zones should be managed by the local server.
- Identify any custom zones, hostname records, or nameserver zones that must remain on the server.
Service Considerations
- Schedule a maintenance window if possible.
- Be prepared to temporarily stop the DNS service (BIND/named or PowerDNS).
- Ensure DNS clustering is disabled before removing any zone files to prevent unwanted synchronization during the cleanup process.
Recommended Precautions
- Test the procedure on a non-production server if available.
- Keep backups for at least one week after the cleanup is completed.
- Verify DNS resolution for critical domains after re-enabling clustering and synchronization.
Conclusion
Removing unmanaged DNS zones from a cluster member helps maintain a clean and accurate DNS environment while preventing unnecessary zone synchronization across the cluster. By following this procedure, administrators can safely identify unwanted zone files, remove them from the server, rebuild the DNS configuration, and restore normal cluster operations.
After completing the cleanup, it is recommended to monitor DNS resolution and cluster synchronization for several days to ensure that all required zones remain functional and that no unwanted zones are recreated. Once the environment has been verified and is operating correctly, the temporary backup files may be removed to reclaim disk space.
Regular reviews of DNS cluster configuration and synchronization policies can help prevent similar issues from occurring in the future.