[[email protected] ~]# whoamiroot[[email protected] ~]# uname - r2.6.32-358.el6.x86_64[[email protected] ~]# cat /etc/redhat-release centos release 6.4 (Final) [[email protected] ~]# ifconfig eth0eth0 Link encap:Ethernet HWaddr 00:0C:29:0D:D5:9F inet addr:172.16.10.88 bcast:172.16.255.255 Mask:255.255.0.0 inet6 addr: Fe80::20c:29ff:fe0d:d59f/64 scope:link up BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:506 errors:0 dropped:0 overruns:0 Frame:0 tx packets:91 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:41642 (40.6 kib) tx bytes :10715 (10.4 kib)
1). Add a virtual user MySQL
[[email protected] ~]# useradd-r-s/sbin/nologin mysql[[email protected] ~]# ID mysqluid=498 (mysql) gid=498 (MySQL) group s=498 (MySQL) [[email protected] ~]# tail-1/etc/passwdmysql:x:498:498::/home/mysql:/sbin/nologin
2). Install the OpenSSL and Openssl-devel packages
[email protected] ~]# Yum install OpenSSL openssl-devel-y
3). Install the Ncurses-devel package
[email protected] mysql-5.5.32]# Yum install ncurses-devel-y
4). Install the cmake-2.8.8 Compilation tool wget https://cmake.org/files/v2.8/cmake-2.8.0.tar.gz
[Email protected] tools]# lltotal 29580-rw-r--r--. 1 root root 5691656 June 10:26 cmake-2.8.8.tar.gz #软件包-rw-r--r--. 1 root root 24596474 June 10:10 Mysql-5.5.32.tar.gz[[email protected] tools]# tar xf cmake-2.8.8.tar.gz #解压软件 [[Emai L protected] tools]# CD cmake-2.8.8 #切入到cmake -2.8.8 directory [[email protected] cmake-2.8.8]# pwd/root/tools/cmake-2.8.8[[ Email protected] cmake-2.8.8]#./configure./bootstrap #开始编译
[email protected] cmake-2.8.8]# make && make install #编译并开始安装 .....
5). Start the MySQL database installation
[[EMAIL PROTECTED] TOOLS]# PWD/ROOT/TOOLS[[EMAIL PROTECTED] TOOLS]# TAR XF mysql-5.5.32.tar.gz [[email protected] tools]# lltotal 29588drwxr-xr-x. 13 root root 4096 Jul 14 21:23 Cmake-2.8.8-rw-r--r--. 1 root root 5691656 jun 13 10:26 cmake-2.8.8.tar.gzdrwxr-xr-x. 31 7161 wheel 4096 jul 2 2013 mysql-5.5.32-rw-r--r--. 1 root root 24596474 jun 13 10:10 mysql-5.5.32.tar.gz [[email protected] tools]# cd mysql-5.5.32 cmake . -dcmake_install_prefix=/usr/local/mysql -dmysql_datadir=/ Mydata/data -dsysconfdir=/etc -dwith_innobase_storage_engine=1 -dwith_archive_storage_engine=1 -DWITH_BLACKHOLE_STORAGE_ENGINE=1 -dwith_readline=1 -dwith_ssl=system -dwith_zlib=system -dwith_libwrap=0 -dmysql_unix_addr= /tmp/mysql.sock -ddefault_charset=utf8 -ddefault_collation=utf8_general_ci
[[email protected] mysql-5.5.32]# echo $?0[[email protected] mysql-5.5.32]# make && make install #开始编译 and install
01-mysql5.5.32 Installation