Centos source code installation mysql-5.1.53 CentOS
BitsCN.com
Centos installation of source code mysql-5.1.53
0. set PATH [root @ ldap-mysql-svn-trac ~] # Export PATH = "$ PATH:/usr/man/mysql/bin" 1. decompress the mysql source code package mysql-5.1.53.tar.gz, switch to the installation directory [root @ ldap-mysql-svn-trac mysql-5.1.53] #. /configure -- prefix =/usr/man/mysql -- sysconfdir =/usr/man/mysql -- localstatedir =/usr/man/mysql/data -- with-unix-socket-path = /usr/man/mysql/tmp/mysql. sock -- with-charset = gbk -- with-plugins = innobase -- with-client-ldflags =-all-static -- with-mysqld-ldflags =-all-static # sysconfdir indicates mysql configuration file path, localstatedir indicates the data file path. the socket configuration and the last two attributes are mainly used to improve the performance. # If you want to use the innodb engine, remember to add -- with-plugins = innobase2. install [root @ ldap-mysql-svn-trac mysql-5.1.53] # make [root @ ldap-mysql-svn-trac mysql-5.1.53] # make install3. config [root @ ldap-mysql-svn-trac mysql-5.1.53] # cp/usr/man/mysql/share/mysql/my-medium.cnf/usr/man/mysql/my. cnf4. switch to the mysql bin directory and run [root @ ldap-mysql-svn-trac bin] #. /mysql_install_db -- basedir =/usr/man/mysql -- datadir =/usr/man/mysql/data5. copy/usr/man/mysql/libexec/mysqld to the bin directory of mysql, start mysql service [root @ ldap-mysql-svn-trac bin] # cp/usr/man/mysql/libexec/mysqld/usr/man/mysql/bin6. run mysql service/usr /man/mysql/bin/mysqld_safe -- ledir =/usr/man/mysql/bin -- log-error =/usr/man/mysql/data/t. err -- datadir =/usr/man/mysql/data -- socket =/usr/man/mysql/tmp/mysql. sock -- pid-file =/usr/man/mysql/bin/mysqld. pid &
BitsCN.com