The following is a summary of installing MySQL in Ubuntu 12.04 over the past few days:
There are three ways to install MySQL in Linux: the first is to install the rpmbinary file separately, the second is to install the source code after compilation, and the last is to install the tar.gz file.
Among the three types, since the last is a unified overall file, I personally feel the simplest, so this article will use this method for installation:
First, download the latest tar.gz package from the mysqldownload center:
1. Enter Workbench in the browser. Here, we select the MySQL Community Server link to download the mysql database Server:
As shown above, click the "MySQL Community Server" link to go To the download page, select the myql platform, and select the Linux-Generic platform:
Then, select a tar.gz file to download it:
Select a 32-bit or 64-bit download. Select a 32-bit download file, download the file mysql-5.5.28-linux2.6-i686.tar.gz, decompress it, rename it as mysql, and use the mv command to move it to the/usr/local directory:
Sudo mv ~ /Download/mysql/usr/local
The directory structure is as follows:
Tip: The text file INSTALL-BINARY details the installation method of mysql in Linux.