Page 1 of 1

Problems updating mysql 5.0 to 5.5

Posted: Mon Apr 16, 2012 7:18 am
by egrueda
Hi all.

I've tried to update a mysql server in a centos+plesk environment.
There were some problems during mysql-server update and now it won't start anymore:

Code: Select all

Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
  Updating       : mysql-server                                                              1/2 
Stopping mysqld:  [  OK  ]
/usr/bin/mysqlcheck: Got error: 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) when trying to connect
FATAL ERROR: Upgrade failed
Stopping mysqld:  [  OK  ]
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
Stopping mysqld:  [  OK  ]
MySQL Daemon failed to start.
Starting mysqld:  [FAILED]
Non-fatal POSTIN scriptlet failure in rpm package mysql-server-5.5.22-4.el5.art.x86_64
error: %post(mysql-server-5.5.22-4.el5.art.x86_64) scriptlet failed, exit status 1

Updated:
  mysql-server.x86_64 0:5.5.22-4.el5.art                                                                                          

Complete!
Now I have 2 mysql-server versions at the same time:

Code: Select all

mysql-server-5.5.22-4.el5.art
mysql-server-5.0.95-1.el5_7.1
I've tried removing and reinstalling mysql-server-5.5.22-4.el5.art, but getting the same result.

What should I try?
Thanks.

Re: Problems updating mysql 5.0 to 5.5

Posted: Mon Apr 16, 2012 9:36 am
by egrueda
I've managed to solve it this way:
- copy /etc/my.cnf.rpmnew over /etc/my.cnf
- started mysqld manually skipping grant tables
- run /usr/bin/mysql_upgrade
- stop mysql and start as normal (init script)
- then, yum update mysql-server
Problem fixed! old version was removed when new version completed its installation
:P

Re: Problems updating mysql 5.0 to 5.5

Posted: Mon Apr 16, 2012 9:57 am
by Highland
After installing 5.5, try doing a "mysql -V" and see what it reports

Re: Problems updating mysql 5.0 to 5.5

Posted: Mon Apr 16, 2012 11:57 am
by faris
The original problem, and possibly your current one, is almost certainly a line in my.cnf that needs to be removed or commented out: skip-bdb

With that line in there, mysql will fail to start.

Sorry if that's not what's really the problem, but I'd put a high probability on it.

I'm not terribly sure what you'd need to do to get rid of the old mysql once the new one is up and running, however.