how to upgrade mysql using SSH or WHM?

mickalo

Well-Known Member
Apr 16, 2002
782
5
318
N.W. Iowa
Use at your own RISK!

This is what I did on a RH 7.3 and 9.0 w/cpanels and haven't run into any problems yet :) But use at your own risk.... BESURE TO BACKUP ALL YOUR DATABASE FIRST!!
Code:
#First Do a complete back up of all databases
mysqldump --all-databases --opt -u root -p > /path/to/backup_file/ALL-db_backups.sql

#Stop MySQL:
service mysql stop 
(or /etc/init.d/mysql stop)
# make sure it all is stopped.

kill -9 mysqld
kill -9 mysql

# change to your install directory,. where we do it.
cd /usr/src/rpms

# then do the "wget" to get the new RPM files
#(Std Server)
wget [url]http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-server-4.0.20-0.i386.rpm[/url]
#(Client programs)
wget [url]http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-client-4.0.20-0.i386.rpm[/url]
#(Libraries and header files)
wget [url]http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-devel-4.0.20-0.i386.rpm[/url]
#(Dynamic client libraries)
wget [url]http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-shared-4.0.20-0.i386.rpm[/url]
wget [url]http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-shared-compat-4.0.20-0.i386.rpm[/url]
#(Embedded Server)
wget [url]http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-embedded-4.0.20-0.i386.rpm[/url]
#(BenchMark)
wget [url]http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-bench-4.0.20-0.i386.rpm[/url]

# then to do upgrades run the follow RPM commands.

rpm -Uvh MySQL-Max-server-4.0.20-0.i386.rpm
rpm -Uvh MySQL-client-4.0.20-0.i386.rpm
rpm -Uvh MySQL-devel-4.0.20-0.i386.rpm
rpm -Uvh MySQL-embedded-4.0.20-0.i386.rpm
rpm -Uvh MySQL-shared-compat-4.0.20-0.i386.rpm
rpm -Uvh MySQL-shared-4.0.20-0.i386.rpm
rpm -Uvh MySQL-bench-4.0.20-0.i386.rpm

# Start up MySQL again.
service mysql start 
#or 
/etc/init.d/mysql start
# then do
mysql -V
# to check version
You should now have the MySQL 4.0.20 running. All privileges should remain the same as they where with 4.0.18. Again, besure you have a valid backup copy of all your databases.

Good luck :D:
Mickalo
 

Born2Kill

Well-Known Member
Jan 2, 2004
120
0
166
localhost or dev/null
error

[[email protected] mysql-src]# rpm -Uvh MySQL-server-4.0.20-0.i386.rpm
warning: MySQL-server-4.0.20-0.i386.rpm: V3 DSA signature: NOKEY, key ID 5072e1f5
error: Failed dependencies:
libmysqlclient.so.10 is needed by (installed) mod_auth_mysql-1.11-12
libmysqlclient.so.10 is needed by (installed) perl-DBD-MySQL-2.1021-3
libmysqlclient.so.10 is needed by (installed) php-mysql-4.2.2-17.2
[[email protected] mysql-src]#


what i need to do ?

is this ok ?
rpm -e perl-DBD-Mysql mysql-3.23 mysql-devel mysql-server qt-Mysql Mysql-python
php-mysql perl-DBI.rpm :)
 
Last edited:

mickalo

Well-Known Member
Apr 16, 2002
782
5
318
N.W. Iowa
strange. that should be in the /usr/lib folder on the RH 9 we've installed the RPM's on...

how was the MySQL version 4.0.18 installed, by RPM's or from source ??

is the MySQL 4.0.18 running now ??

Mickalo
 

mickalo

Well-Known Member
Apr 16, 2002
782
5
318
N.W. Iowa
Originally posted by Born2Kill
mysql -V
mysql Ver 12.22 Distrib 4.0.18, for pc-linux (i686)

from rpm
this is from our RH 9 cpanel box:
mysql Ver 12.22 Distrib 4.0.20, for pc-linux (i686) where we update MySQL yesterday.

You may to do some symbolic linking to see if that helps. Otherwise, if this on a Cpanel box, wait till Cpanel updates it via the upcp nigthly update.

Are you sure this is on a RedHat 9.0 server w/Cpanel ?

Mickalo
 

bikersraw

Active Member
Feb 16, 2004
27
0
151
Originally posted by mickalo
this is from our RH 9 cpanel box:
mysql Ver 12.22 Distrib 4.0.20, for pc-linux (i686) where we update MySQL yesterday.

You may to do some symbolic linking to see if that helps. Otherwise, if this on a Cpanel box, wait till Cpanel updates it via the upcp nigthly update.

Are you sure this is on a RedHat 9.0 server w/Cpanel ?

Mickalo
./upcp didnt update mysql, said 4.0.18 was current

also the link
http://mirror.services.wisc.edu/mysql/Downloads/MySQL-4.0/MySQL-shared-compat-4.0.20-0.i386.rpm

has no file its for MySQL-shared-compat-4.0.20-0.i386.rpm
 
Last edited:

mickalo

Well-Known Member
Apr 16, 2002
782
5
318
N.W. Iowa
Originally posted by Sinewy
[email protected] [/usr/src/rpms]# rpm -Uvh MySQL-bench-4.0.20-0.i386.rpm
warning: MySQL-bench-4.0.20-0.i386.rpm: V3 DSA signature: NOKEY, key ID 5072e1f5
error: Failed dependencies:
perl-DBI is needed by MySQL-bench-4.0.20-0


what do i need to do there?
your missing the RPM perl-DBI.

Mickalo
 

fleksi

Well-Known Member
Sep 17, 2003
125
0
166
do it @ ur own risk.

rpm -Uvh --nodeps MySQL-server-4.0.20-0.i386.rpm
rpm -Uvh MySQL-shared-compat-4.0.20-0.i386.rpm
rpm -Uvh MySQL-client-4.0.20-0.i386.rpm

service mysql stop
service mysql start

will upgrade mysql