• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved Plesk Is not working

waseem

Basic Pleskian
Hi i am facing issues with plesk as plesk is not working on my server, error on admin screen is
ERROR: Zend_Db_Statement_Exception: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'psa.sessions' doesn't exist (Pdo.php:234)
however problem is wirh psa database as i am not able to restore a dump file, every time when i tried to restore it gives me error like table is write only and table is not found.
When i check db errors via command it shows most of tables are not present, plesk repair is also not working as it says no db found,
Can any one suggest me what to do? the dump i am trying to restore is valid as i restore my plesk db with it 20 hours ago.
 
Hi waseem,

however problem is wirh psa database as i am not able to restore a dump file, every time when i tried to restore it gives me error like table is write only and table is not found.
When you are trying to RESTORE a psa - db, pls. make sure, that you DELETE ( DROP ) the former psa - db first:

Example:
Code:
MYSQL_PWD=`cat /etc/psa/.psa.shadow` mysql -u admin -e"DROP DATABASE psa;"
zcat /var/lib/psa/dumps/mysql.preupgrade.<version and time stamp>.dump.gz | sed -n '/-- Current Database: `psa`/,/-- Current Database:*/p' | MYSQL_PWD=`cat /etc/psa/.psa.shadow` mysql -f -uadmin

=> How to backup/restore a Plesk database dump? ( KB - article 881 )
 
Hi @UFHH01
yes i drop table first and if it gives error i simply rename var/lib/mysql/psa folder to random name and trying to restore dump still no luck
 
using this method
Code:
gunzip /var/lib/psa/dumps/mysql.preupgrade.-12.5.30.20160911-225644.dump.gz
mysql -uadmin -p`cat /etc/psa/.psa.shadow` -e"DROP DATABASE psa;"
mysql -f -uadmin -p`cat /etc/psa/.psa.shadow` < /var/lib/psa/dumps/mysql.preupgrade.-12.5.30.20160911-225644.dump


when i try
mysql -uadmin -p`cat /etc/psa/.psa.shadow` -e"DROP DATABASE psa;"
it gives me error of
Code:
ERROR 1010 (HY000) at line 1: Error dropping database (can't rmdir './psa', errno: 39 "Directory not empty")

if i restore it forcefully, it shows error too, when i tr to run
wasi:~# plesk repair db -n
here is its output
Code:
Checking the Plesk database using the native database server tools .. [OK]

Checking the structure of the Plesk database ........................ [OK]

Checking the consistency of the Plesk database

  Inconsistency in the table 'apsContextsApplications' for the column
  registryApplicationId: There is no object in the 'apsc' database in
  the table 'aps_registry_object' with UID =
  09b0a123-2660-4200-bd9b-12c04ca82a1c .............................. [ERROR]

  Inconsistency in the table 'apsResources' for the column registryId:
  There is no object in the 'apsc' database in the table
  'aps_registry_object' with UID =
  09544442-dab3-4595-b458-fc906e1613c7 .............................. [ERROR]

  Inconsistency in the table 'apsResources' for the column registryId:
  There is no object in the 'apsc' database in the table
  'aps_registry_object' with UID =
  9e338331-88c7-4b16-804c-0128367f3d4b .............................. [ERROR]

  Inconsistency in the table 'smb_apsPackages' for the column
  registryUid: There is no object in the 'apsc' database in the table
  'aps_registry_object' with UID =
  ecd8fef9-8ebe-479a-9b93-2aee536abe4f .............................. [ERROR]

  Inconsistency in the table 'smb_apsInstances' for the column
  registryResourceId: There is no object in the 'apsc' database in the
  table 'aps_registry_object' with UID =
  e46f1747-88a9-4fc3-adf0-f2ed398fc04d .............................. [ERROR]

  Inconsistency in the table 'smb_serviceInstances' for the column
  externalId: There is no object in the 'apsc' database in the table
  'aps_registry_object' with UID =
  e46f1747-88a9-4fc3-adf0-f2ed398fc04d .............................. [ERROR]

  Inconsistency in the table 'smb_apsInstances' for the column
  registryResourceId: An APS application for the APS database entry
  with ID = 3 was not found ......................................... [ERROR]

Error messages: 7; Warnings: 0; Errors resolved: 0


exit status 1
 
Last edited:
Back
Top