Considerations for installing MySQL source code scr. rpm
The rpm installation package is usually a Binary package or a Source package. When using the source code to install MySQL, the source code package downloaded on the official website is usually scr. rpm format, rather than the direct tar package. To solve this problem, you must first use the rpm command to install the source code and then compile and install it. This article describes this method.
1. Download the source code package
Http://mirrors.sohu.com/mysql/MySQL-5.6/
Http://dev.mysql.com/downloads/mysql/
2. Install rpm
# Environment
SUSE11 :~ # Cat/etc/issue
Welcome to SUSE Linux Enterprise Server 11 SP3 (x86_64)-Kernel \ r (\ l ).
Suse11:/usr/local/src # rpm-ivh MySQL-5.6.21-1.sles11.src.rpm
1: mySQL ####################################### #### [100%]
# After installation, the tar file of its source code is usually located in the/usr/src directory.
# The following two directories are added in/usr/src/packages/: SPECS and SOURCES.
Suse11:/usr/local/src # ls-hltr/usr/src/packages/
Total 20 K
Drwxrwxrwt 2 root 4.0 K Apr 25 2013 SRPMS
Drwxrwxrwt 2 root 4.0 K Apr 25 2013 BUILD
Drwxrwxrwt 4 root 4.0 K Aug 7 11: 09 RPMS
Drwxr-xr-x 2 root 4.0 K Oct 17 SPECS
Drwxr-xr-x 2 root 4.0 K Oct 17 SOURCES
For example, the installation source file of mysqlis mysql-5.6.21.tar.gz.
Suse11:/usr/local/src # cd/usr/src/packages/SOURCES
Suse11:/usr/src/packages/SOURCES # ls
Mysql-5.6.21.tar.gz
# Decompress the tar file
Suse11:/usr/src/packages/SOURCES # tar-xvf mysql-5.6.21.tar.gz
3. Install MySQL with source code
Refer to: Install the full version of MySQL source code in Linux.
-------------------------------------- Split line --------------------------------------
Install MySQL in Ubuntu 14.04
MySQL authoritative guide (original book version 2nd) Clear Chinese scan PDF
Ubuntu 14.04 LTS install LNMP Nginx \ PHP5 (PHP-FPM) \ MySQL
Build a MySQL Master/Slave server in Ubuntu 14.04
Build a highly available distributed MySQL cluster using Ubuntu 12.04 LTS
Install MySQL5.6 and Python-MySQLdb in the source code of Ubuntu 12.04
MySQL-5.5.38 universal binary Installation
-------------------------------------- Split line --------------------------------------
This article permanently updates the link address: