Cleverly install the MySQL database in the Ubuntu Operating System

Source: Internet
Author: User

This article describes how to install the MySQL database correctly in the Ubuntu operating system. If you are interested in installing the MySQL database, the following articles will satisfy your curiosity: The specific content is described below.

Install MySQL (the best combination with PHP)-5.0.40 requires compilation

Download and compile the required tools. These tools may not be available on the default ubuntu installation and need to be manually installed.

 
 
  1. sudo apt-get install g++ gcc make automake perl 

Install all required tools

Download required libncurses5-dev, kdelibs_dev, and kdelib

 
 
  1. sudo apt-get update  
  2. apt-get install build-essential  
  3. sudo apt-get install libncurses5-dev  
  4. sudo apt-get install kdelibs4-dev  
  5. sudo apt-get install kdelibs4c2a  

Install MySQL database with root permission

Shell> groupadd MySQL (the best combination with PHP)

Shell> useradd-g MySQL (the best combination with PHP)

Shell> gunzip <mysql()and php )))-version.tar.gz | tar-xvf-

Shell> cd MySQL (best combination with PHP)-VERSION

Shell>./configure -- prefix =/usr/local/MySQL (the best combination with PHP)

 
 
  1. shell> make  
  2. shell> make install  
  3. shell> cp support-files/my-medium.cnf /etc/my.cnf  

Shell> cd/usr/local/MySQL (best combination with PHP)

Shell> chown-R MySQL (the best combination with PHP ).

Shell> chgrp-R MySQL (the best combination with PHP ).

Shell> bin/MySQL (the best combination with PHP) _ install_db -- user = MySQL (the best combination with PHP)

 
 
  1. shell> chown -R root . 

Shell> chown-R MySQL (the best combination with PHP) var

Shell> bin/MySQL (the best combination with PHP) d_safe -- user = MySQL (the best combination with PHP )&

The above content introduces how to install MySQL database in the Ubuntu operating system.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.