mysql installation

This blog is dedicated for mysql installations and settings on ubuntu operating system. I love ubuntu so all the settings mentioned bellow are tested on ubuntu. It also covers few more basic tricks on configure like enable mysql error log.

Run the following command prompt to install MySQL.

  sudo apt-get install mysql-server

While installation you can set the password for root user. Once installalation is done, MySQL server should be started automatically.
How to check the mysql service is running or not.

 sudo netstat -tap | grep mysql

If you want to start the service yourself you can do this by executing following command. chose only one option out of these {start | stop | restart | status}.

  sudo /etc/init.d/mysql {start | stop | restart | status}

Once you are done with mysql installation you can make it little secure by changing the my.cnf file by making it listenable on specific IP, log file, port number, etc.
my.cnf file default located is /etc/mysql/my.cnf

   bind-address  =
   # enable mysql error log
   general_log_file = /var/log/mysql/mysql.log
   general_log  = 1
   log_error = /var/log/mysql/error.log
   slow_query_log_file = /var/log/mysql/slow_query_error.log

Note: If the error.log files does not exists then please create them and assign permission 777.

Hope this help!

Share this nice post:

9 thoughts on “mysql installation

  1. Congrats ~ Found your blog on Google while searching for a related topic, your site came up, it looks good, keep them coming !

  2. Nice post. I used to be checking constantly this blog and I am impressed! Very useful info specially the final part:) I take care of such info much. I used to be seeking this particular info for a long time. Thanks and good luck.

  3. Great, I should certainly pronounce, impressed with your website. I had no trouble navigating through all tabs and related information ended up being truly easy to do to entry. I just found what I hoped for before very long in the least. Reasonably unusual. May well appreciate it for those that add forums or something, website theme. a tones way for your customer to communicate. Excellent task..

  4. I simply could not leave your site prior to suggesting that I really enjoyed the usual info a person supply in your visitors? Is going to be back regularly in order to check up on new posts

  5. I’m not sure the place you’re getting your information, however great topic. I needs to spend some time finding out more or understanding more. Thank you for wonderful information I was searching for this info for my mission.

  6. I just want to say I’m newbie to weblog and truly loved your web site. Very likely I’m likely to bookmark your blog post . You really have tremendous articles. Kudos for revealing your website.

Comments are closed.