參考:http://kb.parallels.com/en/1360
Symptoms may differ. For example(三種主要狀況所引起):
- Parallels Plesk Panel (hereafter Plesk) domains are added in HSPcomplete: the DNS zones are not created in the HSPcomplete name servers automatically.
- The domain is deleted in Plesk: it is not deleted completely, but an exception is shown.
- You create a domain: hosting is not created, but an error is shown.
The complete error looks like the following:
ERROR: PleskException
Table::select() failed: no such row in the table
0: /usr/local/psa/admin/plib/dns/DNSZone.php:52
DNSZone->DNSZone(string '100')
1: /usr/local/psa/admin/plib/common_func.php3:2610
objectMaker(string 'DNSZone', string '100')
2: /usr/local/psa/admin/plib/dns/DNSManager.php:39
DNSManager::getDNSZone(string '100')
3: /usr/local/psa/admin/htdocs/domains/dns.php:21
On Plesk for Windows, the error is different and is also shown in the domain management operations (suspend/resume/delete domain):
Error: DNSZone::Table::select() failed: no such row in the table
Cause
The reason for the error is that in psa.domains
, the Plesk mysql table dns_zone_id
record points to a nonexistent ID record in the psa.dns_zone
table for one or several domains. This may occur because of internal Plesk issues, a broken database, incomplete domain deletion, incorrect provisioning from HSPcomplere to the Plesk server, etc.
Resolution
Note: The solution below is demonstrated for Linux; however, it can be applied in the same way for a Windows server. Note that accessing the psa database will look differently.
You need to create an appropriate zone in the psa.dns_zone
table first. Log in to the Parallels Plesk database:
# mysql -uadmin -p`cat /etc/psa/.psa.shadow` -Dpsa
Find the domains that have missing IDs:
mysql> SELECT d.name FROM domains d LEFT JOIN dns_zone z ON d.dns_zone_id=z.id WHERE z.id IS NULL;
Then for each reported domain, do the following:
-
Create appropriate ID records with the following commands. Do not forget to replace <"DOMAN-NAME"> with the real domain name and <"ADMIN-EMAIL"> with the correct email:
mysql> INSERT INTO dns_zone (name, displayName, email) VALUES ('<DOMAIN-NAME>', '<DOMAIN-NAME>', '<ADMIN-EMAIL>');
-
Determine the new zone ID:
mysql> SELECT id, name FROM dns_zone where name='<DOMAIN-NAME>';
-
Substitute the correct ID into the
psa.domains
table, and don't forget to replace <"DOMAN-NAME"> and <"DNS-ZONE-ID"> with the correct values:mysql> UPDATE domains SET dns_zone_id='<DNS-ZONE-ID>' WHERE name='<DOMAIN-NAME>';
Then log in to Plesk Panel. For each corrected domain, go to Home > Domains > <"DOMAIN-NAME"> > Website & Domains > DNS and use the Default
button to re-generate DNS records. After this, the error disappears. Now you will be able to repeat the action that was interrupted by the error: do domain deletion or synchronize DNS to HSPcomplete or something else.
NOTE: It is highly recommended to update Plesk components to the latest available builds, which have fixes included that prevent such problems.