Control Web Panel

WebPanel => Installation => Topic started by: Wonder on October 24, 2025, 08:00:16 AM

Title: Problems installing CWP 8 with MariaDB
Post by: Wonder on October 24, 2025, 08:00:16 AM
This week I installed CWP 8 from scratch, and I had to do it several times on the same server.
My mistake for not noting and saving the error.

The error appears once installed. It installs MariaDB 10.5, and when you run a yum update, it gives a result similar to this (because I searched for it and it appeared):

Copied from other post but equal than my problem:
yum update
Last metadata expiration date check: 0:05:32 ago on Sat 17 May 2025 14:34:10 UTC. Mistake:
Problem 1: package MariaDB-shared-10.5.29-1.el8.x86_64 from mariadb requires MariaDB-common, but none of the providers can be installed
- cannot install the best update candidate for package mariadb-connector-c-3.1.11-2.el8_3.x86_64
- package MariaDB-common-10.5.27-1.el8.x86_64 from mariadb is filtered out by modular filtering
- package MariaDB-common-10.5.28-1.el8.x86_64 from mariadb is filtered out by modular filtering
- package MariaDB-common-10.5.29-1.el8.x86_64 from mariadb is filtered out by modular filtering
Problem 2: package MariaDB-shared-10.5.29-1.el8.x86_64 from mariadb requires MariaDB-common, but none of the providers can be installed
- cannot install the best update candidate for package mariadb-connector-c-config-3.1.11-2.el8_3.noarch
- package MariaDB-common-10.5.27-1.el8.x86_64 from mariadb is filtered out by modular filtering
- package MariaDB-common-10.5.28-1.el8.x86_64 from mariadb is filtered out by modular filtering
- package MariaDB-common-10.5.29-1.el8.x86_64 from mariadb is filtered out by modular filtering
(try adding '--skip-broken' to skip uninstallable packages or '--nobest' to use not only the best candidate packages)

I read the link mentioned and it takes us Here:
https://www.alphagnu.com/topic/23-upgrade-mariadb-1011-in-cwp-centos-7-centos-8-stream-almalinux-78-rockylinux-78/#comment-25

But it doesn't fix it. In my case, it never fixed it; I always had the same problem.

Finally, I was able to fix it (I don't remember exactly how; I was stressed because the production server had crashed).

Now, cwp detects two pending updates. I log in and none appear. Yum update indicates that neither does it. But I see that the latest kernel, although apparently installed, isn't activated even in GRUB. I'm not worried; it will be updated with the next kernel released.

The problem is mariadb in a clean install. I think the installation script should be changed. It's not easy to fix the problem of having version 10.5 and then having yum update not work.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: overseer on October 24, 2025, 01:35:50 PM
I too have seen this. (Hopefully you are on an true EL8 distribution such as AlmaLinux 8 -- not a beta OS like CentOS Stream.) CWP should default to MariaDB 10.11 LTS version in its installation script. 10.5 is woefully EOL. Starburst does have a patched EL8 install script that includes 10.6 as the starting point, after which you upgrade to 10.11:
https://starburst.help/control-web-panel-cwp/control-web-panel-cwp-install-tutorials/updated-cwp-installer-script-for-almalinux-8-with-mariadb-10-6/
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Starburst on October 24, 2025, 03:42:06 PM
What @overseer said.

Also when you create the new MariaDB.repo for 10.11, make sure to use the Red Hat Enterprise Linux 8 for Distribution at:
https://mariadb.org/download/?t=repo-config&d=Red+Hat+Enterprise+Linux+8&v=10.11 (https://mariadb.org/download/?t=repo-config&d=Red+Hat+Enterprise+Linux+8&v=10.11)
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on October 24, 2025, 04:59:16 PM
Hello,

Yes, it is indeed a genuine EL8 distribution, AlmaLinux8 in question.

I've installed a server, installed AlmaLinux 8 from scratch, and installed CWP from the official CWP repo (I'll do it later from the one mentioned by Startburst, but I wanted to note that we're using the official CWP repo and instructions).

After installing CWP and running a yum update, we have this:
Code: [Select]
[root@server ~]# yum update
CentOS Web Panel repo for Linux 8 - x86_64                                                                                                                    3.0 MB/s | 330 kB     00:00   
AlmaLinux 8 - BaseOS                                                                                                                                           16 MB/s |  44 MB     00:02   
AlmaLinux 8 - AppStream                                                                                                                                       3.1 MB/s |  21 MB     00:06   
AlmaLinux 8 - Extras                                                                                                                                           34 kB/s |  14 kB     00:00   
AlmaLinux 8 - PowerTools                                                                                                                                      7.1 MB/s | 5.0 MB     00:00   
AlmaLinux 8 - PowerTools Source                                                                                                                               357 kB/s | 142 kB     00:00   
AlmaLinux 8 - PowerTools debuginfo                                                                                                                            1.6 MB/s | 854 kB     00:00   
Extra Packages for Enterprise Linux 8 - x86_64                                                                                                                7.1 MB/s |  14 MB     00:01   
Error:
 Problem 1: package MariaDB-shared-10.5.29-1.el8.x86_64 from cwp requires MariaDB-common, but none of the providers can be installed
  - cannot install the best update candidate for package mariadb-connector-c-3.1.11-2.el8_3.x86_64
  - package MariaDB-common-10.5.29-1.el8.x86_64 from cwp is filtered out by modular filtering
 Problem 2: package MariaDB-shared-10.5.29-1.el8.x86_64 from cwp requires MariaDB-common, but none of the providers can be installed
  - cannot install the best update candidate for package mariadb-connector-c-config-3.1.11-2.el8_3.noarch
  - package MariaDB-common-10.5.29-1.el8.x86_64 from cwp is filtered out by modular filtering
(try to add '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)
[root@server ~]#
I followed the instructions at this URL step by step as shown below.
https://www.alphagnu.com/topic/23-upgrade-mariadb-1011-in-cwp-centos-7-centos-8-stream-almalinux-78-rockylinux-78/#comment-25

Code: [Select]
[root@server ~]# cp /etc/my.cnf /etc/my.cnf.bak
[root@server ~]# systemctl stop mariadb mysql mysqld
[root@server ~]# systemctl disable mariadb
Removed /etc/systemd/system/multi-user.target.wants/mariadb.service.
Removed /etc/systemd/system/mysql.service.
Removed /etc/systemd/system/mysqld.service.
[root@server ~]# rpm -e --nodeps $(rpm -qa | grep -i mariadb)
[root@server ~]# rpm -e --nodeps mysql-common mysql-libs mysql-devel
error: package mysql-common is not installed
error: package mysql-libs is not installed
error: package mysql-devel is not installed
[root@server ~]# rpm --nodeps -ev MariaDB-server
error: package MariaDB-server is not installed
[root@server ~]# dnf module disable mariadb -y
Last metadata expiration check: 0:04:12 ago on Fri 24 Oct 2025 06:27:29 PM CEST.
Dependencies resolved.
==============================================================================================================================================================================================
 Package                                       Architecture                                 Version                                       Repository                                     Size
==============================================================================================================================================================================================
Disabling modules:
 mariadb                                                                                                                                                                                     

Transaction Summary
==============================================================================================================================================================================================

Complete!
[root@server ~]# rpm -e --nodeps mariadb-server
error: package mariadb-server is not installed
[root@server ~]# nano /etc/yum.repos.d/mariadb.repo
[root@server ~]# yum clean all
62 files removed
[root@server ~]# yum install MariaDB-server MariaDB-client MariaDB-devel MariaDB-shared net-snmp perl-DBD-MySQL -y
CentOS Web Panel repo for Linux 8 - x86_64                                                                                                                    3.1 MB/s | 330 kB     00:00   
AlmaLinux 8 - BaseOS                                                                                                                                           15 MB/s |  44 MB     00:02   
AlmaLinux 8 - AppStream                                                                                                                                        15 MB/s |  21 MB     00:01   
AlmaLinux 8 - Extras                                                                                                                                           34 kB/s |  14 kB     00:00   
AlmaLinux 8 - PowerTools                                                                                                                                      7.6 MB/s | 5.0 MB     00:00   
AlmaLinux 8 - PowerTools Source                                                                                                                               334 kB/s | 142 kB     00:00   
AlmaLinux 8 - PowerTools debuginfo                                                                                                                            1.8 MB/s | 854 kB     00:00   
Extra Packages for Enterprise Linux 8 - x86_64                                                                                                                7.9 MB/s |  14 MB     00:01   
MariaDB                                                                                                                                                       1.6 MB/s | 634 kB     00:00   
Package perl-DBD-MySQL-4.046-3.module_el8.6.0+2827+49d66dc3.x86_64 is already installed.
Error:
 Problem: package MariaDB-server-10.11.14-1.el8.x86_64 from mariadb requires MariaDB-client >= 10.6.1, but none of the providers can be installed
  - cannot install both MariaDB-client-10.11.11-1.el8.x86_64 from mariadb and MariaDB-client-10.5.29-1.el8.x86_64 from cwp
  - cannot install both MariaDB-client-10.11.13-1.el8.x86_64 from mariadb and MariaDB-client-10.5.29-1.el8.x86_64 from cwp
  - cannot install both MariaDB-client-10.11.14-1.el8.x86_64 from mariadb and MariaDB-client-10.5.29-1.el8.x86_64 from cwp
  - cannot install the best candidate for the job
(try to add '--allowerasing' to command line to replace conflicting packages or '--skip-broken' to skip uninstallable packages or '--nobest' to use not only best candidate packages)
[root@server ~]#
The only way I can find to solve it is by disabling the CWP repo at that point, then it updates without any problem, but it installs some more package, which I really don't know if it's necessary:

disabling cwp repo:
Code: [Select]
Installing:
 MariaDB-client                                       x86_64                                10.11.14-1.el8                                     mariadb                                   16 M
 MariaDB-devel                                        x86_64                                10.11.14-1.el8                                     mariadb                                  8.5 M
 MariaDB-server                                       x86_64                                10.11.14-1.el8                                     mariadb                                   28 M
 MariaDB-shared                                       x86_64                                10.11.14-1.el8                                     mariadb                                  128 k
 net-snmp                                             x86_64                                1:5.8-31.el8_10                                    appstream                                355 k
Installing dependencies:
 MariaDB-common                                       x86_64                                10.11.14-1.el8                                     mariadb                                   88 k
 boost-program-options                                x86_64                                1.66.0-13.el8                                      appstream                                140 k
 galera-4                                             x86_64                                26.4.23-1.el8                                      mariadb                                  1.5 M
 net-snmp-agent-libs                                  x86_64                                1:5.8-31.el8_10                                    appstream                                749 k
 net-snmp-libs                                        x86_64                                1:5.8-31.el8_10                                    baseos                                   827 k
Installing weak dependencies:
 lsof                                                 x86_64                                4.93.2-1.el8                                       baseos                                   252 k
 pv                                                   x86_64                                1.6.6-7.el8                                        epel                                      64 k
 socat                                                x86_64                                1.7.4.1-2.el8_10                                   appstream                                322 k

Transaction Summary

And the rest of the steps are perfect.

By the way, I've used both the one indicated in the URL and the one @starburst mentioned as repos with the same result; the problem isn't the mariadb repository.

Then, in a few hours, I'll run the same tests using the CWP installer created by @starburst and post them here.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on October 24, 2025, 08:45:33 PM
As they say around here, a promise is a promise.

I performed a clean install of AlmaLinux 8 on a server and tried the @Starburst installer:
https://starburst.help/control-web-panel-cwp/control-web-panel-cwp-install-tutorials/updated-cwp-installer-script-for-almalinux-8-with-mariadb-10-6/
It didn't work.

The server had Almalinux 8 installed and updated; nothing else was installed.

I started the CWP installation and was already seeing some errors. At one point, it stopped. I'll paste the last few lines:

Code: [Select]
Transaction Summary
==============================================================================================================================================================================================
Install  2 Packages

Total download size: 954 k
Installed size: 2.9 M
Downloading Packages:
(1/2): gpm-libs-1.20.7-17.el8.x86_64.rpm                                                                                                                      451 kB/s |  38 kB     00:00   
(2/2): elinks-0.12-0.58.pre6.el8.x86_64.rpm                                                                                                                   3.3 MB/s | 916 kB     00:00   
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                                         1.0 MB/s | 954 kB     00:00     
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
  Preparing        :                                                                                                                                                                      1/1
  Installing       : gpm-libs-1.20.7-17.el8.x86_64                                                                                                                                        1/2
  Running scriptlet: gpm-libs-1.20.7-17.el8.x86_64                                                                                                                                        1/2
  Installing       : elinks-0.12-0.58.pre6.el8.x86_64                                                                                                                                     2/2
  Running scriptlet: elinks-0.12-0.58.pre6.el8.x86_64                                                                                                                                     2/2
  Verifying        : gpm-libs-1.20.7-17.el8.x86_64                                                                                                                                        1/2
  Verifying        : elinks-0.12-0.58.pre6.el8.x86_64                                                                                                                                     2/2

Installed:
  elinks-0.12-0.58.pre6.el8.x86_64                                                                gpm-libs-1.20.7-17.el8.x86_64                                                               

Complete!
Last metadata expiration check: 0:01:48 ago on Fri 24 Oct 2025 09:58:48 PM CEST.
Dependencies resolved.
Nothing to do.
Complete!

PREPARING THE SERVER
##########################
Failed to stop firewalld.service: Unit firewalld.service not loaded.
Failed to disable unit: Unit file firewalld.service does not exist.

#############################################
Please wait... installing web server files...
#############################################

Last metadata expiration check: 0:01:52 ago on Fri 24 Oct 2025 09:58:48 PM CEST.
No match for argument: cwp-httpd
Error: Unable to find a match: cwp-httpd
Last metadata expiration check: 0:01:56 ago on Fri 24 Oct 2025 09:58:48 PM CEST.
No match for argument: cwp-suphp
Error: Unable to find a match: cwp-suphp

Compiler requires 512 MB RAM + SWAP
Installation FAILED at httpd
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   899  100   899    0     0   4181      0 --:--:-- --:--:-- --:--:--  4181
sh: line 46: /usr/local/bin/php: No such file or directory
grep: /etc/init.d/httpd: No such file or directory
Received
Please contact CWP support about this issue and include the last few lines from the error:
http://centos-webpanel.com/contact
[root@server src]#

So, for now, a clean install, from what I can see or from my experience, should be done through the CWP installer. We followed the instructions to update MariaDB, but right when we installed MariaDB 10.11 (or 10.6, whichever version you prefer), we deactivated the CWP repo, installed MariaDB, and after it was installed, we reactivated the CWP repo.

By the way, thanks @Starburst for your work here...
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Starburst on October 24, 2025, 08:57:55 PM
Your running some commands not in the KB.

I see a conflict wit the CWP repo, where it's trying to load from.

You add this to cwp.repo below enabled=1
Code: [Select]
exclude=mariadb*
The error you posted, shows the httpd installation failed.
Our updated script only updated MariaDB to install 10.6.

Quote
Last metadata expiration check: 0:01:52 ago on Fri 24 Oct 2025 09:58:48 PM CEST.
No match for argument: cwp-httpd
Error: Unable to find a match: cwp-httpd
Last metadata expiration check: 0:01:56 ago on Fri 24 Oct 2025 09:58:48 PM CEST.
No match for argument: cwp-suphp
Error: Unable to find a match: cwp-suphp

Compiler requires 512 MB RAM + SWAP
Installation FAILED at httpd

Try to just use the CWP install script, and before you reboot complete the MariaDB 10.11 update.

Note, the OS should be a base install, Without LAMP installed.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on October 25, 2025, 04:49:06 AM
Your running some commands not in the KB.
No, I don't run any commands, I simply install AlmaLinux, and the next step is to install CWP...

Quote
I see a conflict wit the CWP repo, where it's trying to load from.
Exactly, that's what I think happens... (I'm referring to updating MariaDB using the CWP installer from the "official" CWP repo).

Quote
You add this to cwp.repo below enabled=1
Code: [Select]
exclude=mariadb*
The error you posted, shows the httpd installation failed.
Our updated script only updated MariaDB to install 10.6.
For me, that's not possible. As I mentioned, I do a clean install of AlmaLinux, and the next step is to install CWP using your updated installer. I can't modify any repo because it's not installed; it doesn't install CWP.
Updated: But I've tried what you say below, just before restarting after installing CWP, and the result is the same error: it doesn't allow it.
For me, the only solution is to disable the CWP repo at the MariaDB update point, and then re-enable it.

Quote
Quote
Last metadata expiration check: 0:01:52 ago on Fri 24 Oct 2025 09:58:48 PM CEST.
No match for argument: cwp-httpd
Error: Unable to find a match: cwp-httpd
Last metadata expiration check: 0:01:56 ago on Fri 24 Oct 2025 09:58:48 PM CEST.
No match for argument: cwp-suphp
Error: Unable to find a match: cwp-suphp

Compiler requires 512 MB RAM + SWAP
Installation FAILED at httpd

Try to just use the CWP install script, and before you reboot complete the MariaDB 10.11 update.
Do you mean using the instructions above to update MariaDB (https://www.alphagnu.com/topic/23-upgrade-mariadb-1011-in-cwp-centos-7-centos-8-stream-almalinux-78-rockylinux-78/#comment-25)?

Quote
Note, the OS should be a base install, Without LAMP installed.
Correct, I don't have LAMP installed; it's a clean AlmaLinux installation.

PS: Sorry my poor english
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Starburst on October 25, 2025, 10:57:24 AM
What is failing is cwp-http and cwp-suphp, not only MariaDB.

The tow cwp- files are what's causing the installer to crash, which means for some reason that server isn't talking to the cwp server.

Is this server behind a NAT?
Any firewalls that may be blocking?
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on October 25, 2025, 11:57:05 AM
What is failing is cwp-http and cwp-suphp, not only MariaDB.

The tow cwp- files are what's causing the installer to crash, which means for some reason that server isn't talking to the cwp server.

Is this server behind a NAT?
Any firewalls that may be blocking?

Nothing, no NAT, no firewall, nothing, it's a clean install of AlmaLinux 8.

The "official" CWP installer works, but your updater is failing. I don't know why... but it's very, very strange.....

I'll try again later. Maybe I didn't let AlmaLinux update enough time after installing it, and it happened when I was doing something... that's the only thing I can think of, but even so... it's very strange to me...
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Starburst on October 25, 2025, 11:04:23 PM
Use the stock installer then, and us Sandeep's MariaDB upgrade instructions at:
https://www.alphagnu.com/topic/23-upgrade-mariadb-1011-in-cwp-centos-7-centos-8-stream-almalinux-78-rockylinux-78/ (https://www.alphagnu.com/topic/23-upgrade-mariadb-1011-in-cwp-centos-7-centos-8-stream-almalinux-78-rockylinux-78/)

The installer you are trying is to replace the stock CWP installer, and install MariaDB 10.6
CWP may have changed something, I haven't installed CWP on AL8 for awhile, we moved on to AL9.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on October 26, 2025, 12:17:50 PM
Yes, I reinstalled yesterday and the same thing happened again, the same problem and errors at the same point or points, so I deduced that the installer + Almalinux 8 had changed something (I mean the installer: https://starburst.help/control-web-panel-cwp/control-web-panel-cwp-install-tutorials/updated-cwp-installer-script-for-almalinux-8-with-mariadb-10-6/ )
So, indeed, I used the stock CWP installer (from CWP web) and then updated MariaDB following the instructions here:
https://www.alphagnu.com/topic/23-upgrade-mariadb-1011-in-cwp-centos-7-centos-8-stream-almalinux-78-rockylinux-78/
But as I mentioned, there is one point that is not viable, it gives the error I indicated In the first post, at this point:
Code: [Select]
yum clean all
yum install MariaDB-server MariaDB-client MariaDB-devel MariaDB-shared net-snmp perl-DBD-MySQL -y
yum update -y
Just before
Code: [Select]
yum install MariaDB.... etc....We need to disable the CWP repo. If you don't disable the CWP repo, the MariaDB update won't happen.

You must disable the MariaDB repo. The instructions would be:
Code: [Select]
yum clean all
nano /etc/yum.repos.d/cwp.repo
Set enabled=0
Save changes, and then:
yum install MariaDB-server MariaDB-client MariaDB-devel MariaDB-shared net-snmp perl-DBD-MySQL -y
Then, very important:
nano /etc/yum.repos.d/cwp.repo
Set enabled=1
Save changes
yum update -y
The following steps are as described in the manual.

This is the only viable way I found to update MariaDB. I performed several installations (on the same server for testing) so I can provide accurate instructions here.

By the way, sorry for being off-topic, you say you've moved to AL9 using CWP9. I currently have a server for testing, and I've tested it. To install CSF, I have to install iptables (iptables doesn't come installed by default, although it's not a major problem), but... is CWP9 fully operational?
It still has the problem of not being able to migrate accounts from CWP8 to CWP9, and that's important to me. I would migrate some to AL/CWP9, but if I can't do the migration, I can't. AL9 is only viable for fresh installations, but for existing ones, if the account can't be migrated, CWP -> CWP Migration is important to me.

Thanks
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Starburst on October 26, 2025, 02:56:26 PM
There's isn't a mariadb repo right after the CWP installation anymore, since the version they are installing is past EOL.

You also don't need to disable the whole cwp.repo, you can just add this form the above, so MariaDB won't try to install from it.

You add this to cwp.repo below enabled=1
Code: [Select]
exclude=mariadb*
Then follow the upgrade instructions from AlphaGNU.

All of our servers run AL9 with CWP.

If you don't need PHP below 7.4 or site migration (problem with 2 different security algorithms) AL9 would be better.

And if you want, do the basic AL9 image, and I can login and get everything installed for you. (no cost)
You would just need to PM me your login info.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on October 26, 2025, 09:41:24 PM
There's isn't a mariadb repo right after the CWP installation anymore, since the version they are installing is past EOL.
Yes, that's what I've seen. A fresh CWP installation doesn't have a MariaDB repository.

Regarding these instructions:
Quote
You also don't need to disable the whole cwp.repo, you can just add this form the above, so MariaDB won't try to install from it.

You add this to cwp.repo below enabled=1
Code: [Select]
exclude=mariadb*
Then follow the upgrade instructions from AlphaGNU.
I could swear I tried it, I could swear I tried it and it didn't work, but now I'm doubting it. I did a lot of testing to be able to post here with confidence. And this point, I think I tried it and it didn't work, but I can't be 100% sure, maybe 90% sure. Since I have a test server now, I can test it and be sure.

Quote
All of our servers run AL9 with CWP.

If you don't need PHP below 7.4 or site migration (problem with 2 different security algorithms) AL9 would be better.

And if you want, do the basic AL9 image, and I can login and get everything installed for you. (no cost)
You would just need to PM me your login info.
Indeed, I don't need PHP below 7.4 on two out of three sites, and I'm using AL8 on all of them.
But... if I have the problem you mentioned, I need a migration. I can migrate the website and the database manually, but not the email accounts. I can rsync the email accounts, but, above all, I have a server with many email accounts and the password. I can't ask them to reset it (the password for the email accounts). That would have to be migrated. And it's one of the two issues you mentioned, the migration, which is why it's so important to me, because of the email accounts.

Regarding the basic AL9 image, you can't imagine how much I appreciate it. I installed AL9 from scratch, but unlike AL8, I've noticed that iptables must be installed to activate CSF, and that makes me think maybe more things are needed. It would be helpful to know what those things are. I'll contact you.
Let's see if CWP 9 evolves further and isn't still in Beta...
Thank you sincerely.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: overseer on October 27, 2025, 12:33:48 AM
You should be able to manually migrate, no problem. I just had to manually migrate my last CentOS 7 server to AlmaLinux 8 because I was continually encountering a bug with CWP Migration (even though it's worked just fine for me for other servers). You dump all DB to a single SQL file, on the new server create the user accounts you are replicating, load the DB SQL on the new server and rsync in all your files -- /home and /var/vmail. (Also move any conf you want to carry over -- CSF firewall, Roundcube, nginx vhosts, DNS zone files, etc.).

https://wiki.centos-webpanel.com/how-to-manually-import-emails

But the postfix DB, particularly the mailbox table has all the end user PW hashes stored. So recreating that DB on the new server will get you all the user PW you need. No need to recreate any mail user accounts or aliases. Also bring over the roundcube DB for a seamless mail experience. Just make sure their /var/vmail IMAP storage is in place and all the references will point appropriately. Voila!
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on November 01, 2025, 12:15:47 PM
You should be able to manually migrate, no problem. I just had to manually migrate my last CentOS 7 server to AlmaLinux 8 because I was continually encountering a bug with CWP Migration (even though it's worked just fine for me for other servers). You dump all DB to a single SQL file, on the new server create the user accounts you are replicating, load the DB SQL on the new server and rsync in all your files -- /home and /var/vmail. (Also move any conf you want to carry over -- CSF firewall, Roundcube, nginx vhosts, DNS zone files, etc.).

https://wiki.centos-webpanel.com/how-to-manually-import-emails

But the postfix DB, particularly the mailbox table has all the end user PW hashes stored. So recreating that DB on the new server will get you all the user PW you need. No need to recreate any mail user accounts or aliases. Also bring over the roundcube DB for a seamless mail experience. Just make sure their /var/vmail IMAP storage is in place and all the references will point appropriately. Voila!

Hi,
I read your message carefully. I apologize for not replying sooner; forums fluctuate, and I've been quite busy this week.
When you mention backing up all the databases, I assume you mean the website databases, not the CWP databases themselves, correct? I know how to import emails and accounts using rsync, and I greatly appreciate your message, but... I'm not sure how to export/import the Postfix mailbox table to retain the password for each email account. However, when you say:
"So recreating that DB on the new server will get you all the user PW you need. No need to recreate any mail user accounts or aliases,"

If I recreate that database, is it a database restoration, a backup of the original, and then restoring it in CWP9? Is that correct? The same applies to the Roundcube database.

I assume so, but I'd prefer to be sure, although perhaps a test server would clear things up for me... Thanks again!
Title: Re: Problems installing CWP 8 with MariaDB
Post by: overseer on November 01, 2025, 03:09:15 PM
No, not limited to just the website DB -- I do mean ALL DB (including the root_cwp database, postfix DB, roundcube DB). On the original server to be migrated, issue this command:
Code: [Select]
mariadb-dump -u root -p --all-databases --system=users > all_DB.sqlThen SCP or rsync this all-inclusive SQL file over (it can be several GB large).
Then on the fresh AL9 system after re-creating all the user accounts, issue the reverse command to load in the DBs:
Code: [Select]
mariadb -u root -p < /path/to/all_DB.sqlThis worked for my CentOS 7.9 to AlmaLinux 8 migration.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on November 02, 2025, 01:30:11 AM
No, not limited to just the website DB -- I do mean ALL DB (including the root_cwp database, postfix DB, roundcube DB). On the original server to be migrated, issue this command:
Code: [Select]
mariadb-dump -u root -p --all-databases --system=users > all_DB.sqlThen SCP or rsync this all-inclusive SQL file over (it can be several GB large).
Then on the fresh AL9 system after re-creating all the user accounts, issue the reverse command to load in the DBs:
Code: [Select]
mariadb -u root -p < /path/to/all_DB.sqlThis worked for my CentOS 7.9 to AlmaLinux 8 migration.

Justo, thank you!! That was it, that was the question I had. Logically, I thought it should be all the databases, but I wasn't sure, and I wasn't certain. Perhaps restoring those databases from another version of CWP wouldn't be possible in a clean installation.

But what you've told me has saved my life in case I migrate (I still have to decide whether to migrate a production server from CWP8 to CWP9... I don't want that server to fail for any reason). Like I said, this was exactly the information I needed. I'm extremely grateful.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: overseer on November 02, 2025, 02:25:03 PM
The goal would be to have 2 concurrently running systems -- your live AL8 system and your newly migrated AL9 system. Then you just change the DNS to point to the new server to complete the migration. In my case, I had 2 VMs on the same host machine, IPs separated by only a couple of digits. I brought up the new system, tested it as best I could, then shut down the main production VM and changed the IP on the replacement VM. It was a seamless transition (1 min downtime), with only some housekeeping to tend to after the switch -- that didn't affect the clients at all. This way, if things go south you can always revert back to the previous VM with only ~1 min downtime.

(Even if you go the DNS route, with Cloudflare you are only talking about >5 min downtime, switching DNS back & forth.)
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on November 03, 2025, 09:51:02 PM
That's right, that's the idea, and that's how I usually proceed when doing migrations.

Sometimes the migration involves changing VPSs. The server is the same, same domain, same everything, but... the new VPS has better performance for the price.

So, at that point, I have both: the one in production and the new one. As you correctly mentioned, the new one is fully configured and ready, so I just need to migrate the CWP account to the CWP account. I'm behind Cloudflare and I do it at a time that won't cause any disruption. It's just a matter of changing the DNS settings in Cloudflare, and as you said, it doesn't take more than 5 minutes for the new one to be active.

But... this is where I had my doubts, mainly because I had no idea how to migrate the email accounts and their passwords. And this is where, thanks to you, I can do it.
Right now, I have a server set up with AL9 and CWP9, properly and perfectly configured, and I'm going to try it there. I'm using it as a server for this test; if it works, it'll stay, thanks to... it's perfectly configured.

However, the server has many email accounts, which is what worries me most. I'll have to either stop the mail server somehow or simply run another rsync from the old one to the new one.

Thanks!!!
Title: Re: Problems installing CWP 8 with MariaDB
Post by: overseer on November 03, 2025, 10:05:05 PM
Do both -- stop the old server's mail, run another rysnc run, then switch DNS, perhaps even one more rsync run (5 min or less). But if the mail service is stopped, it shouldn't be taking in any new mail. Mail will just sit in other servers' outgoing mail queues until your new server becomes available at the DNS address they are looking for.
Title: Re: Problems installing CWP 8 with MariaDB
Post by: Wonder on November 04, 2025, 05:24:42 PM
Do both -- stop the old server's mail, run another rysnc run, then switch DNS, perhaps even one more rsync run (5 min or less). But if the mail service is stopped, it shouldn't be taking in any new mail. Mail will just sit in other servers' outgoing mail queues until your new server becomes available at the DNS address they are looking for.

That's exactly a question I've always had, and I think you've answered it:

"If the mail service is stopped, it shouldn't receive any new emails. The emails will simply remain in the outgoing mail queues of other servers until your new server is available at the DNS address they're looking for."

I'll do what you suggested; a final rsync won't hurt, but as you mentioned, it shouldn't receive anything if I stop the mail server.

Thanks again!