• 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 Migration from Centos to Rocky issue with ModSecurity

mariano_loo

New Pleskian
Server operating system version
CentOS Stream 8
Plesk version and microupdate number
Plesk Obsidian Version 18.0.41
Hello
Trying to migrate my server from Centos8 to Rocky Linux... I am getting an error during the migration process.
I am not sure how to proceed here without breaking the existing Plesk installation.

Here is the log:
Error: Transaction test error:
file /var/lib/mod_security from install of mod_security-2.9.6-1.el8.x86_64 conflicts with file from package plesk-modsecurity-configurator-18.0-2.centos.8+p18.0.41.1$

Running dnf update before we attempt the migration.
Last metadata expiration check: 0:01:40 ago on Thu Jan 5 15:51:10 2023.
Dependencies resolved.
================================================================================
Package Architecture Version Repository Size
================================================================================
Upgrading:
mod_security x86_64 2.9.6-1.el8 appstream 270 k

Transaction Summary
================================================================================
Upgrade 1 Package

Total download size: 270 k
Downloading Packages:
mod_security-2.9.6-1.el8.x86_64.rpm 1.0 MB/s | 270 kB 00:00
--------------------------------------------------------------------------------
Total 562 kB/s | 270 kB 00:00
Running transaction check
Transaction check succeeded.
Running transaction test
The downloaded packages were saved in cache until the next successful transaction.
You can remove cached packages by executing 'dnf clean packages'.
Error: Transaction test error:
file /var/lib/mod_security from install of mod_security-2.9.6-1.el8.x86_64 conflicts with file from package plesk-modsecurity-configurator-18.0-2.centos.8+p18.0.41.1$


Error running pre-update. Stopping now to avoid putting the system in an
unstable state. Please correct the issues shown here and try again.


An error occurred while we were attempting to convert your system to Rocky Linux. Your system may be unstable. Script will now exit to prevent possible damage.
 
If you have not already tried, try upgrading your Plesk installation to 18.0.43. Otherwise go into the Plesk updater and uninstall modsecurity temporary (it's under Web Hosting). Once the upgrade is complete, you should be able to reinstall it.
 
I'm afraid Plesk Updater is not an option since we're talking about Centos 8, Plesk has stopped updates for it since Feb 2022..
 
Hello
I resolved my problem by uninstalling mod_security, starting the OS migration, and verifying successful OS installation, updating Plesk, reinstalling mod_security, and finally recheck all your modsecurity configs.

That solved my problem.
 
I'm afraid Plesk Updater is not an option since we're talking about Centos 8, Plesk has stopped updates for it since Feb 2022..
As I've mention as an alternative is uninstall modsecurity, do the conversion, then reinstall like how mariano did.
 
Were you able to access Plesk Updater? I get this message:

There are no products for your operating system
( 'CentOS' 'Linux' '8' 'x86_64' ) available
from the selected source.

You can try using another source.

How did you uninstall ModSecurity?
 
Once updating the OS... I was able to get the Plesk updater from the backend.
Uninstall from root. it skipped the module during migration.
 
I would be grateful if you shared some more info on how you did it. I haven't found a way to uninstall it through SSH..
 
Sure...

-yum remove mod_security
-OS Migration then
-yum install mod_security
-yum update --all

Again check your ModSecurity in Plesk cause it gets reset during update. Everything else was working fine for me,
 
Back
Top