Applicable to:
- Plesk Obsidian for Linux
Symptoms
Adding a domain in Plesk fails during hosting creation with an error similar to:
PLESK_ERROR: Creating physical hosting
DB query failed: (1054) SQLSTATE[42S22]: Column not found: 1054 Unknown column 'disabled_with_parent' in 'field list', query was: INSERT INTO `log_rotation` (`period_type`, `period`, `max_number_of_logfiles`, `compress_enable`, `email`, `turned_on`, `disabled_with_parent`) VALUES (?, ?, ?, ?, ?, ?, ?)
Configuring PHP
Running the Plesk database check confirms the inconsistency:
CONFIG_TEXT: # plesk repair db -n
...
Column disabled_with_parent is absent in the table log_rotation ... [ERROR]
Other related inconsistencies may also be reported at the same time, for example:
CONFIG_TEXT: Column creationDate is absent in the table admin_aliases .......... [ERROR]
Extra table: APSApplicationItems .................................. [WARNING]
Extra table: APSCatalogUpdates .................................... [WARNING]
Extra table: apscategories ........................................ [WARNING]
Column uuid is absent in the table admin_aliases .................. [ERROR]
The table CopilotConversations is absent ........................... [ERROR]
The table CopilotMessages is absent ................................ [ERROR]
Column bit is absent in the table dsn .............................. [ERROR]
Wrong attributes for the column 'value' in the table 'PleskStats' .. [ERROR]
Cause
The structure of the Plesk database (psa) is out of sync with the Plesk version installed on the server. The log_rotation table (and, depending on the case, other system tables) is missing columns that the currently installed Plesk build expects when creating hosting for a new domain.
This typically happens when a Plesk update did not fully complete its database migration, for example because the update was interrupted, or because the psa database was restored from a backup taken before the panel packages were upgraded.
Resolution
- Connect to the server over SSH.
-
Create a backup of the Plesk database before making changes:
# plesk db dump /root/psa_backup_$(date +%F).sql
-
Run the Plesk repair utility to check the database structure:
# plesk repair db -n
Confirm that the missing columns/tables reported match the symptoms above.
-
Run the repair utility to apply the fix:
# plesk repair db -y -v
This adds the missing columns and tables and brings the database structure back in line with the installed Plesk version.
-
Re-run the check to confirm the errors are resolved:
# plesk repair db -n
- Retry adding the domain in Plesk to confirm hosting is created without errors.
Comments
Please sign in to leave a comment.