# Upgrading MySql 5.1 to MySql 5.5

I followed a tutorial to update My MySql 5.1 to 5.5 (actually i wanted to upgrade to 5.6, but the tutorial mentioned that i should upgrade to 5.5 first and then to 5.6).

However, after removing previous version and updating mysql configuration and path environment variable, i'm stuck at starting the server and upgrading. I'm a newbie i this field and i don't know what to do now.

These are the steps i followed:

1. Stopped mysql service, Copied mysql data files and configuration files.
2. Removed version 5.1.
4. Updated start-up script to register the new installation.
5. Updated Path Environment Variable.
6. Updated MySql Configuration.
7. Made appropriate changes to path to mysql plugins directory.
8. Creates mysqld symbolic link in /usr/sbin/ directory.

Now the final step was to start the server and upgrade it. So i tried sudo /usr/sbin/mysqld --skip-grant-tables, but it says sudo: /usr/sbin/mysqld: command not found.

i don't know what to do now. I'm stuck at this from the last 4 hours. I was following this tutorial.

Edit:

i found out that the problem was with the command responsible for the creation of symbolic link in /use/sbin directory.

I had used sudo ln -s /opt/mysql/server5.5/bin/mysqld /usr/sbin/mysqld instead of sudo ln -s /opt/mysql/server-5.5/bin/mysqld /usr/sbin/mysqld. Dash was not present. Now, i am able to execute the command sudo /usr/sbin/mysqld --skip-grant-tables.

After executing, i tried mysql_upgrade -uroot -p --verbose, but it showed an error

The program 'mysql_upgrade' can be found in the following packages:
* mysql-server-core-5.1
* mysql-cluster-server-5.1
* mysql-server-5.0
Try: sudo apt-get install <selected package>

-
At first glance, this looks like a Unix issue, not a database one. Do a "ls -lista mysql*" in /usr/sbin and post the result here. –  Vérace May 31 '14 at 12:28
I found out that the problem was with the symbolic link. Now there is a new problem. i have updated my question. –  Kanav May 31 '14 at 12:36
What does "nothing is happening after that" mean? Do you get an error? If so, what is it? Is the command prompt returned? If so, type "ps -ef | grep mysql" and tell us what you see. –  Vérace May 31 '14 at 12:38
i was able to execute sudo /usr/sbin/mysqld --skip-grant-tables now. After that, i tried mysql_upgrade -uroot -p --verbose and it showed an error The program 'mysql_upgrade' can be found in the following packages: * mysql-server-core-5.1 * mysql-cluster-server-5.1 * mysql-server-5.0 –  Kanav May 31 '14 at 12:42
After executing ps -ef | grep mysql, i got root 10890 1 0 16:55 ? 00:00:15 /opt/sublime_text/sublime_text /etc/apparmor.d/usr.sbin.mysqld mysql 11844 10838 0 17:51 ? 00:00:00 /usr/sbin/mysqld --skip-grant-tables –  Kanav May 31 '14 at 12:42