Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have installed MySQL 5.5.31 in Opensolaris. When I tried starting the MySQL server, it says bash: mysql: command not found So, I decided to uninstall the whole lot and try doing again. But I could not find any spporting documents online to do so, because either they refer to .rpm file unistallation pkgrm. I used .tar extension and pkgrm is not supported in my machine.

share|improve this question
There is no reason to "uninstall" and try again. You either extracted the files to your server, or you didn't, and if you did, then all you're doing with this approach is wasting time, because the result will be the same... Most likely you just need to set your $PATH correctly so that bash can find the mysql binaries, or fully-qualify the or use the full path to the executable. – Michael - sqlbot Dec 30 '13 at 21:49

Check MySQL service use following command:

ps -ef | grep mysql

If MySQL process is running then first stop mysql process.

kill -9 mysql_pid   


/etc/init.d/mysql stop

Remove mysql base and data dir. By default it's location is /usr/local/mysql. Use following command:

rm -r mysql

Start with fresh installation: Ref this link or this for MySQL binary installation.

share|improve this answer

Do a "which mysql" and/or "which mysqld". These will tell you if your mysql executables are on your path or not. If they are not on your $PATH, go to the root directory and issue a "find . -name "mysql*" | more" to see if you do really have these files on your system. If you do have them, point your $PATH to them in your .profile/.bashrc.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.