Mysql installation and configuration tutorial in Ubuntu 14.04 and 14.04 installation and configuration tutorial

Source: Internet
Author: User

Mysql installation and configuration tutorial in Ubuntu 14.04 and 14.04 installation and configuration tutorial

Mysql is an open-source Relational Database Management System of Oracle. It is widely used in various small and medium websites and is a cross-platform database management system, now we will introduce how to install and configure mysql on Ubuntu 14.04.

Method/step

1. Update the source list

Open the terminal window and enter "sudo apt-get update" --> press enter --> "enter the password of the root user" --> press Enter. If you do not run this command and install mysql directly, an error message "you can run apt-get update ------" appears, causing installation failure.

2. Install mysql

Open the terminal window ", enter "sudo apt-get install mysql-server mysql-client" --> press enter --> enter "y" --> press enter --> in the "package Settings dialog box", enter mysql as "root ""user's password --> press enter --> re-enter the password --> press enter, installation is complete.

3. How to determine whether mysql is successfully installed

Open the terminal window and enter "sudo service mysql restart" --> press enter --> If mysql is started successfully and is running, mysql is installed successfully.

4. Enable apache to support mysql

Open the terminal window, enter sudo apt-get install libapache2-mod-auth-mysql --> press enter --> Installation successful, after this module is installed, apache can support mysql.

5. Let php support mysql

Open the terminal window, enter sudo apt-get install php5-mysql --> press enter --> Installation successful, after installing this module, php can support mysql.

6. log on to mysql

Open the terminal window and enter mysql-u root-p. --> press enter --> enter the password of the "root" user in mysql --> press enter --> log on successfully.

Add moreUbuntu14.04 how to uninstall mysql?

1. Delete mysql Data Files
Sudo rm/var/lib/mysql/-R
2. Delete the mqsql configuration file:
Sudo rm/etc/mysql/-R
3. Automatically uninstall the mysql program:
Sudo apt-get autoremove mysql * -- purge
Sudo apt-get remove apparmor

The above are the detailed steps for installing and configuring mysql on Ubuntu 14.04. Do you like it?

Related Article

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.