• Introducing WebPros Cloud - a fully managed infrastructure platform purpose-built to simplify the deployment of WebPros products !  WebPros Cloud enables you to easily deliver WebPros solutions — without the complexity of managing the infrastructure.
    Join the pilot program today!
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.

certificate CLI cannot work since update

NicolasC

New Pleskian
Hi,

Since about 23rd of March 2010, the certificate command always fails :

# /opt/psa/bin/certificate --update "Name" -admin -cert-file certif.crt -key-file certif.key
ERROR: PleskMainDBException
MySQL query failed: Cannot delete or update a parent row: a foreign key constraint fails (`psa/IP_Addresses`, CONSTRAINT `IP_Addresses_ibfk_1` FOREIGN KEY (`ssl_certificate_id`) REFERENCES `certificates` (`id`))

0: common_func.php3:168
db_query(string 'replace certificates set `id`='2', `name`='Name', `csr`='', `pvt_key`='-----BEGIN+RSA+PRIVATE+KEY-----%0A[...]%0A-----END+RSA+PRIVATE+KEY-----%0A', `cert`='-----BEGIN+CERTIFICATE-----%0A[...]%0A-----END+CERTIFICATE-----%0A', `cert_file`='cert-hWaBYG', `ca_file`='cert-x2teLX'')
1: class.Table.php:316
Table->replaceData(array)
2: class.Table.php:282
Table->update(array)
3: class.cObject.php:352
cObject->update()
4: class.SSLCertificate.php:454
SSLCertificate->update()
5: cuCertificate.php:636
cuCertificate->cmdUpdate(string 'Name', array)
6: cuCertificate.php:191
cuCertificate->execute()
7: certificate.php:23

In order to make it working again, I had to delete the foreign key on table IP_Address (and by the way, brake the relation between the tables) :

SUCCESS: Update of certificate 'Name' complete

I don't understand why because nothing changed on this server.... Does this foreign key exist since a long time ?

Thanks for your help
Nicolas
 
Back
Top