Author Topic: MariaDB update failed  (Read 17417 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
MariaDB update failed
« on: November 29, 2020, 12:35:12 PM »
Hi,
today I've received notification for MariaDB update to version 10.2.36-1.el7.centos   
This is part of log:

This is a brief description of the upgrade process.  Important details
can be found in the MariaDB manual, in the Upgrading section.
******************************************************************
error: %pre(MariaDB-server-10.2.36-1.el7.centos.x86_64) scriptlet failed, exit status 1
  Verifying  : MariaDB-server-10.1.48-1.el7.centos.x86_64                   1/2
  Verifying  : MariaDB-server-10.2.36-1.el7.centos.x86_64                   2/2

Failed:
  MariaDB-server.x86_64 0:10.1.48-1.el7.centos                                 
  MariaDB-server.x86_64 0:10.2.36-1.el7.centos                                 

Complete!

Offline
*
Re: MariaDB update failed
« Reply #1 on: November 29, 2020, 02:21:20 PM »
Hello,

I have the same problem, I have the pro version.

Thank you, for the one who has a solution.

Offline
*
Re: MariaDB update failed
« Reply #2 on: November 29, 2020, 02:34:36 PM »
Here is the solution I found:

First step to save your database (I didn't do it!)

Code: [Select]
mysqldump --all-databases > /home/fullbackup.sql.gz
Uninstall MariaDB client:

Code: [Select]
yum remove MariaDB-server MariaDB-client -y
Now install MariaDB, it will automatically install MariaDB 10.2 (10.2.36):

Code: [Select]
yum install MariaDB-server MariaDB-client -y
Then to finish:

Code: [Select]
mysql_upgrade

Offline
*
Re: MariaDB update failed
« Reply #3 on: November 30, 2020, 12:11:24 PM »
Is it really necessary to do this upgrade? Do we have to?

Offline
*
Re: MariaDB update failed
« Reply #4 on: December 01, 2020, 01:28:12 AM »
I'll wait for a CWP official solution, probably a script update to do the upgrade process automatically...

Offline
*
Re: MariaDB update failed
« Reply #5 on: December 01, 2020, 02:26:16 AM »
Here is the solution I found:

First step to save your database (I didn't do it!)

Code: [Select]
mysqldump --all-databases > /home/fullbackup.sql.gz
Uninstall MariaDB client:

Code: [Select]
yum remove MariaDB-server MariaDB-client -y
Now install MariaDB, it will automatically install MariaDB 10.2 (10.2.36):

Code: [Select]
yum install MariaDB-server MariaDB-client -y
Then to finish:

Code: [Select]
mysql_upgrade

You didn't do the all procedure or only the backup step?

It worked for you?

Offline
*
Re: MariaDB update failed
« Reply #6 on: December 01, 2020, 07:42:01 AM »
I'll wait for a CWP official solution, probably a script update to do the upgrade process automatically...
me too...

Offline
*
Re: MariaDB update failed
« Reply #7 on: December 01, 2020, 11:09:15 AM »
Here is the solution I found:

First step to save your database (I didn't do it!)

Code: [Select]
mysqldump --all-databases > /home/fullbackup.sql.gz
Uninstall MariaDB client:

Code: [Select]
yum remove MariaDB-server MariaDB-client -y
Now install MariaDB, it will automatically install MariaDB 10.2 (10.2.36):

Code: [Select]
yum install MariaDB-server MariaDB-client -y
Then to finish:

Code: [Select]
mysql_upgrade

well , this worked fine for me .. thanks ..  ;)

Offline
*
Re: MariaDB update failed
« Reply #8 on: December 01, 2020, 12:29:55 PM »
Below the steps that I made...

1. Create a backup file.
Code: [Select]
mysqldump --all-databases > /home/fullbackup.sql.gz
2. Disable InnoDB fast shutdown
Code: [Select]
mysql

mysql -> SET GLOBAL innodb_fast_shutdown = 0;

3. Stop MariaDB
Code: [Select]
service mysql stop
4. Manually uninstall MariaDB 10.1
Code: [Select]
yum remove MariaDB-server MariaDB-client -y
5. Manually install MariaDB 10.2
Code: [Select]
yum install MariaDB-server MariaDB-client -y
6. Start MariaDB
Code: [Select]
service mysql start
7. Upgrade the DB to compatibility
Code: [Select]
mysql_upgrade
8. Enable service "mariadb.service" on "Services config -> Start-up Services".
Code: [Select]
systemctl enable mariadb.service
9. Reboot to check if all right.
Code: [Select]
reboot
If everything all right, relax and drink a coffee. If not, breath and drink a coffee to find a fix, but stay calm... you have a backup (Do you made the 1st step, right?).
« Last Edit: December 01, 2020, 01:10:01 PM by ehstbr »

Offline
**
Re: MariaDB update failed
« Reply #9 on: December 02, 2020, 04:05:17 AM »
I'll wait for a CWP official solution, probably a script update to do the upgrade process automatically...

I will also love this.

I also have the same issue in all my 3 VPS.

Atleast waiting for an official guide to fix this.

Offline
*
Re: MariaDB update failed
« Reply #10 on: December 02, 2020, 04:56:37 PM »
I did this and fixed my issue:

Code: [Select]
mysqldump --all-databases > /root/fullbackup.sql.gz
Code: [Select]
yum remove MariaDB-server MariaDB-client -y
Code: [Select]
yum install MariaDB-server MariaDB-client -y
Code: [Select]
mysql_upgrade
Code: [Select]
systemctl enable mariadb.service
This finished in like 1 minute or so...

And for cleanup
Code: [Select]
rm /root/fullbackup.sql.gz

Offline
*
Re: MariaDB update failed
« Reply #11 on: December 02, 2020, 08:18:19 PM »
It's highly recommended set innodb_fast_shutdown to 0 and manually stop the mariadb.service before remove current version and install the new version...

Offline
*
Re: MariaDB update failed
« Reply #12 on: December 05, 2020, 12:21:30 PM »
I have the same problem ....

Code: [Select]
This is a brief description of the upgrade process.  Important details
can be found in the MariaDB manual, in the Upgrading section.
******************************************************************
error: %pre(MariaDB-server-10.2.36-1.el7.centos.x86_64) scriptlet failed, exit status 1
  Verifying  : MariaDB-server-10.1.48-1.el7.centos.x86_64                   1/2
  Verifying  : MariaDB-server-10.2.36-1.el7.centos.x86_64                   2/2

Failed:
  MariaDB-server.x86_64 0:10.1.48-1.el7.centos                                 
  MariaDB-server.x86_64 0:10.2.36-1.el7.centos                                 

Complete!

Complete!
?????

Offline
*
Re: MariaDB update failed
« Reply #13 on: December 07, 2020, 06:13:05 AM »
Below the steps that I made...

1. Create a backup file.
Code: [Select]
mysqldump --all-databases > /home/fullbackup.sql.gz
2. Disable InnoDB fast shutdown
Code: [Select]
mysql

mysql -> SET GLOBAL innodb_fast_shutdown = 0;

3. Stop MariaDB
Code: [Select]
service mysql stop
4. Manually uninstall MariaDB 10.1
Code: [Select]
yum remove MariaDB-server MariaDB-client -y
5. Manually install MariaDB 10.2
Code: [Select]
yum install MariaDB-server MariaDB-client -y
6. Start MariaDB
Code: [Select]
service mysql start
7. Upgrade the DB to compatibility
Code: [Select]
mysql_upgrade
8. Enable service "mariadb.service" on "Services config -> Start-up Services".
Code: [Select]
systemctl enable mariadb.service
9. Reboot to check if all right.
Code: [Select]
reboot
If everything all right, relax and drink a coffee. If not, breath and drink a coffee to find a fix, but stay calm... you have a backup (Do you made the 1st step, right?).

Works for me.
Thank You!

Offline
*
Re: MariaDB update failed
« Reply #14 on: December 10, 2020, 08:48:46 PM »
@sandeep

I followed your how to on how to upgrade MariaDB following this instruction set: https://forum.centos-webpanel.com/index.php?topic=9471.msg33152#msg33152

It worked, thanks for the support you give it is the best IMHO

Now I have this issue in CWP admin (using CWPpro) in the  services status panel it displays "MySQL Database Server" = failed

"The status log reads:  InnoDB: Unable to lock ./ibdata1 error: 11
[Note] InnoDB: Check that you do not already have another mysqld process using the same InnoDB data or log files."

How does one go about clearing this up?

Running on CentOS 7.5