Ubuntu install MySQL

Source: Internet
Author: User

Use Ubuntu10.04lts to install the MySQL steps as follows:

1. Install database: sudo apt-get install Mysql-server

The password needs to be set during installation.

2. Install the client: sudo apt-get install mysql-client

3. Login Mysql:mysql-u root-p

4. configuration file:/etc/mysql/my.cnf

A. Set remote access: Bind-address = 127.0.0.1 in 127.0.0.1 to native IP, which enables the database to support network remote access. After Setup is complete, restart the MySQL service: service mysql restart

B. Database on/off/restart, etc.:/etc/init.d/mysql [Start|stop|restart|reload|force-reload|status]

5. Exit the database: Exit

6. Uninstall mySQL:

A. Delete MySQL

1sudo apt-Get Autoremove--Purge MySQL-server
2 sudo apt- get remove mysql- server
3 -get autoremove mysql-server
4 -get remove mysql-common (very important)

In fact, some of the above is redundant, it is recommended to follow the order
B. Cleaning up residual data
Dpkg -l | grep ^RC| awk '{print $}' | sudo xargs dpkg -P

Ubuntu install MySQL

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.