Applicable to:
- Plesk for Windows
Symptoms
-
Unable to sync DNS zones with Slave server. The following error is shown in Plesk:
PLESK_ERROR: Error: Execution repair has failed with exit code 255, stdout: Restoring DNS server configuration Synchronizing DNS zones with the DNS server ..................... [OK] Error messages: 0; Warnings: 0; Errors resolved: 0 , stderr:
-
%plesk_dir%\admin\logs\php_error
log with Debug mode enabled shows the following:CONFIG_TEXT: [2019-08-15 19:25:53] PHP Fatal error: Uncaught PleskMultipleException: Error during example.com updateZone: dnsmng failed: Unable to find domain or alias 'example.com' in database
at (PSADatabase::getBaseDomainName line 395)
at execute console command --update(vconsoleapp::start line 93)
at execute C:\Plesk/admin/bin/dnsmng --update "--zone-name=example.com" --without-reverse(vconsoleapp::run line 110) in C:\Plesk\admin\plib\Service\Dns\Connector\Plesk.php:14
Cause
Orphaned DNS records exist in the Plesk database.
Resolution
-
Connect to the server via RDP
-
Create a database dump of the Plesk database (for more information, see this KB article):
C:\> plesk db dump psa > C:\psa_backup.sql
-
C:\> plesk db
-
Find
dns_zone_id
of the domain mentioned in the error, using the following command. Replace example.com with an actual domain name:MYSQL_WIN: select dns_zone_id,host from dns_recs where host like "%example.com%";
+-------------+---------------------+
| dns_zone_id | host |
+-------------+---------------------+
| 3 | www.example.com. |
| 3 | example.com. |
| 3 | ns2.example.com. |
| 3 | ns1.example.com. |
| 3 | example.com. |
| 3 | ftp.example.com. |
| 3 | example.com. |
| 3 | example.com. |
| 3 | _dmarc.example.com. |
| 3 | example.com. |
| 3 | mail.example.com. |
| 3 | ipv4.example.com. |
+-------------+---------------------+ -
Using dns_zone_id from the output above, make sure that the domain name is the same:
MYSQL_WIN: select id,name from dns_zone where id=3;
+----+-------------+
| id | name |
+----+-------------+
| 3 | example.com |
+----+-------------+ -
Delete records from corresponding tables using the ID from the steps above:
MYSQL_WIN: mysql>delete from dns_zone where id=3;
mysql> delete from dns_recs where dns_zone_id=3; -
Resync DNS zones in Plesk > Extensions > Slave DNS Manager > Resync
Comments
1 comment
What is the solution for Plesk Onyx 18 onwards?
Please sign in to leave a comment.