Applicable to:
- Plesk Onyx for Linux
Symptoms
-
The following error message is shown on the home page in Plesk:
PLESK_ERROR: New configuration files for the Apache web server were not created due to the errors in configuration templates: Template processing failed: file = /opt/psa/admin/conf/templates/default/domainVhostIpDefault.php, error = Template_Exception: Unable to load object of type SysUser with id=26: SysUser: unable to select: no such row in the table file: /opt/psa/admin/plib/Template/Processor.php line: 28 code: 0 Previous error: Template_Exception: Unable to load object of type SysUser with id=26: SysUser: unable to select: no such row in the table file: /opt/psa/admin/plib/Template/Processor.php line: 28 code: 0 Previous error: PleskDBException: Unable to load object of type SysUser with id=26: SysUser: unable to select: no such row in the table file: /opt/psa/admin/plib/functions.php line: 1627 code: 0. Detailed error descriptions were sent to you by email.
-
In the Subscriptions list, one subscription is marked as broken.
-
The utility
plesk repair web
returns an error:# plesk repair web example.com
Unable to load object of type SysUser with id=26: SysUser: unable to select: no such row in the table
Cause
Database inconsistency: there is an orphaned record in the table sys_user_id
.
Resolution
-
Connect to the server via SSH.
-
Create a backup of
psa
database:# MYSQL_PWD=`cat /etc/psa/.psa.shadow` mysqldump -uadmin psa > /root/psa_backup.sql
-
Run
plesk repair db
to fix the database inconsistency:# plesk repair db -n
OR
Proceed with the below steps: -
List all web users from the table
web_users
that are under the domainexample.com
:MYSQL_LIN: select w.id, w.dom_id, w.sys_user_id from web_users as w join domains as d where d.id=w.dom_id and d.name='example.com';
+----+--------+-------------+
| id | dom_id | sys_user_id |
+----+--------+-------------+
| 1 | 5 | 26 |
| 2 | 5 | 30 |
| 3 | 5 | 31 |
+----+--------+-------------+ -
List all web users from the table
sys_users
that are under the domainexample.com
:MYSQL_LIN: mysql> select id, login from sys_users where id in (select w.sys_user_id from web_users as w join domains as d where d.id=w.dom_id and d.name='example.com');
+----+-----------+
| id | login |
+----+-----------+
| 30 | web_user1 |
| 31 | web_user2 |
+----+-----------+
2 rows in set (0.00 sec) -
Check current web users in Plesk at Domains > example.com > Web Users - there are only two of them:
web_user1
andweb_user2
. -
Remove the invalid record:
MYSQL_LIN: delete from web_users where id=1;
-
Repair the website
example.com
:# plesk repair web example.com
Repairing web server configuration
Repairing web server configuration for the domain example.com ........................................... [OK]
Error messages: 0; Warnings: 0; Errors resolved: 0
Comments
0 comments
Please sign in to leave a comment.