Applicable to:
- Plesk for Windows
- Plesk for Linux
Symptoms
- The WordPress Instance marked as broken in Plesk > Domains > example.com > WordPress the following message shown, however, WordPress site however is working correctly:
CONFIG_TEXT: WordPress Toolkit has found WordPress files at the following path: /var/www/vhosts/example.com/httpdocs/wordpress
However, it does not seem that this WordPress website is working. Try restoring the website from a backup or cleaning up the redundant files. - The following error can be found in
/var/log/plesk/panel.log
:CONFIG_TEXT: Failed to change directory to /var/www/vhosts/example.com/httpdocs/wordpress: No such file or directory
Cause
WordPress content was moved manually to the different directory, due to this WordPress database has not been updated with information about this change. The directory mentioned in the error message is actually missing on the server or no files can be found inside:
# ll /var/www/vhosts/example.com/httpdocs/wordpress:
ls: cannot access /var/www/vhosts/example.com/httpdocs/wordpress:: No such file or directory
Resolution
- Login into Plesk and click Scan in Domains > example.com > WordPress: that way instance will be detected by WordPress Toolkit;
- Detach affected instance;
- Connect to the Plesk server via SSH.
-
Create backup of WordPress ToolKit database:
# cp -p /usr/local/psa/var/modules/wp-toolkit/wp-toolkit.sqlite3{,.backup}
- Remove leftovers of affected instance from WordPress Toolkit database:
# sqlite3 /usr/local/psa/var/modules/wp-toolkit/wp-toolkit.sqlite3
# sqlite> .headers on
# sqlite> select instanceId from InstancesDomains where domainId=123;
instanceId
567
# sqlite> DELETE FROM InstanceProperties WHERE instanceId=567;
# sqlite> DELETE FROM InstancesDomains WHERE instanceId=567;
# sqlite> DELETE FROM Instances where id=567;
# sqlite> .quit
- Connect to the server via RDP
-
Download
sqlite3.exe
from this link intoC:\temp\
-
Create copy of WordPress ToolKit database, located in %plesk_dir%var\modules\wp-toolkit\wp-toolkit.sqlite3
- Open cmd.exe as Administrator and remove leftovers of affected instance from WordPress Toolkit database:
C:\> "C:\temp\sqlite3.exe" "%plesk_dir%var\modules\wp-toolkit\wp-toolkit.sqlite3"
sqlite> .headers on
sqlite> select instanceId from InstancesDomains where domainId=123;
instanceId
567
sqlite> DELETE FROM InstanceProperties WHERE instanceId=567;
sqlite> DELETE FROM InstancesDomains WHERE instanceId=567;
sqlite> DELETE FROM Instances where id=567;
sqlite> .quit
Comments
0 comments
Please sign in to leave a comment.