Home - Help & Support - Contact Us
    

Upgrading To MySQL 4.1.18 (binary Distribution) With Fedora Core 2 And Plesk

NOTE: This process is not supported by either Red Hat or Plesk. Upgrading breaks the Fedora Core 2 package manager's ability to manage MySQL. There is a chance that this process could incapacitate your server. We strongly recommend you back up all data and do not attempt this procedure unless you are prepared to reprovision your server, if necessary.

The mysqlupgrade script is meant to be run only once. Its code assumes you are running MySQL 3.23 and upgrading to MySQL 4.1. Do not run the script if you are already running MySQL 4.1. Doing so will incapacitate your server.

Please read the legal disclaimer at the end of this article before proceeding.

This process will assist you in backing up your data so you can roll back and forward. To facilitate roll back and roll forward, MySQL 4.1.18 will be installed in the /usr/local directory, leaving MySQL 3.23 in the default /usr directory. You should, however, perform a separate backup of your data prior to starting this process.

To Upgrade to MySQL 4.1.18

  1. Backup the data on your server.
  2. Using SSH, log in to your server with the User ID and Password that you created when you set up your dedicated hosting account.
  3. At the command line, type the following and press Enter.
    su -
  4. Type the following commands and press Enter after each.
    cd /tmp/
    wget -O mysqlupgrade http://products.secureserver.net/scripts/mysqlupgrade
    sed -ie 's/r//g' mysqlupgrade
    /bin/sh mysqlupgrade
  5. Confirm you can log in to MySQL as root with the following command:
    mysql -u admin -p`cat /etc/psa/.psa.shadow`
    The following output should be generated:
    Welcome to the MySQL monitor. Commands end with ; or g.
    Your MySQL connection id is 5 to server version: 5.0.18-standard

    Type 'help;' or 'h' for help. Type 'c' to clear the buffer.

    mysql> exit

To Confirm the Results

  1. Log in to Plesk by navigating to https://[[ip address]]:8443/ where [[ip address]] is the address of your server.
  2. If you receive errors, you might have imported default table name values from MySQL 3.23 that are not compatible with MySQL 4.1. To diagnose the problem(s), run the following command:
    /usr/local/mysql/bin/mysql -u admin -p`cat /etc/psa/.psa.shadow` < /usr/local/src/mysql_3.23.dump
  3. The output may resemble the following:
    ERROR 1067 (42000) at line 2245: Invalid default value for 'srv_bandwidth'
    In this example, the default value in line 2245 of the file /usr/local/mysql_3.23.dump needs to change from:
    `srv_bandwidth` enum('0','8','16','32','64','128','256','512') NOT NULL default '',
    to:
    `srv_bandwidth` enum('0','8','16','32','64','128','256','512') NOT NULL default '0',
  4. Repeat step one until you do not encounter any errors.

To Roll Back

After the above commands have been run, you can roll back by executing the following code:

unalias cp
service mysqld stop
sleep 2
cd /etc/rc.d/init.d/
cp mysqld_3.23 mysqld
cd /etc/
cp my.cnf_3.23 my.cnf
sleep 2
cd /var/lib
mv mysql mysql_4.1.18
mv mysql_3.23 mysql
sleep 2
service mysqld start

To Roll Forward

Execute the following code to roll forward:

unalias cp
service mysqld stop
sleep 2
cd /etc/rc.d/init.d/
cp mysqld_4.1.18 mysqld
cd /etc/
cp my.cnf_4.1.18 my.cnf
sleep 2
cd /var/lib
mv mysql mysql_3.23
mv mysql_4.1.18 mysql
sleep 2
service mysqld start

LEGAL DISCLAIMER: This article is being provided "as is" and for informational purposes only. We do not recommend you perform the procedures discussed in this article. We make no warranties of any kind, either express or implied or fitness for a particular purpose with respect to the information contained in this article. In no event shall we be liable for any damages whatsoever including but not limited to direct, indirect, incidental, consequential, loss of profits, loss of data or special damages arising out of the use, misuse or inability to use this content.

Rated:NR/0 Votes
108 Views
More Articles From Plesk 7.5
More Articles From Plesk 7.5
Print Article
Print
Share |
Comments, Questions & Reviews

Comments is currently disabled for this article!
Related Articles and Readings
How can I log in as "root" on my dedicated server?
You cannot log in to your dedicated server remotely using "root." If you need "root" access on your dedicated server, ...
How Do I Log in to My Account Manager?
You can manage many of the settings for your products and services from within your Account Manager. To Log in ...
Can I enable users to log in using FTP on my Linux dedicated server?
Yes, you can set up users to log in using FTP on your Linux dedicated server, if the server is ...
Why can't I log in to Plesk Webmail?
If your password is rejected when you log in to Webmail, your email may be disabled. To Enable Plesk Email Log in ...
Why can't I log in to Plesk Webmail?
If your password is rejected when you log in to Webmail, your email may be disabled. To Enable Plesk Email Log in ...
The information provided in this article is for general information and/or the comments is the sole responsibility of their respective authors and does not necessarily reflect the opinion of zeronese.net does not endorse any article and/or comments published by our web users unless otherwise noted.