安裝linux一些必須的包:
yum install gcc gcc-c++ gcc-g77 autoconf automake zlib* fiex* libxml* ncurses-devel libmcrypt* libtool-ltdl-devel* libevent
-
安裝mysql,mysql安裝包需要自己下載,安裝目錄 /usr/local/web/
sudo mkdir -p /usr/local/web/
sudo tar xzvf mysql-5.1.39.tar.gz
cd mysql-5.1.39
./configure --prefix=/usr/local/web/mysql.5.1.39 --enable-thread-safe-client --enable-assembler --with-big-tables --with-client-ldflags=-all-static --with-mysqld-ldflags=-all-static --with-charset=utf8 --with-collation=utf8_general_ci --with-extra-charsets=complex
make
make install
創(chuàng)建mysql用戶(hù)組等信息
sudo groupadd mysql
sudo useradd -g mysql -s /sbin/nologin mysql
sudo ./scripts/mysql_install_db --user=mysql --datadir=/usr/local/web/mysql.5.1.39/var
sudo chown -R root /usr/local/web/mysql.5.1.39
sudo chown -R mysql:mysql /usr/local/web/mysql.5.1.39/var
管理MYSQL
#啟動(dòng)mysql:
sudo /usr/local/web/mysql.5.1.39/share/mysql/mysql.server start
#重啟mysql
sudo /usr/local/web/mysql.5.1.39/share/mysql/mysql.server restart
#停止mysql
sudo /usr/local/web/mysql.5.1.39/share/mysql/mysql.server stop
本文出自:億恩科技【mszdt.com】
服務(wù)器租用/服務(wù)器托管中國(guó)五強(qiáng)!虛擬主機(jī)域名注冊(cè)頂級(jí)提供商!15年品質(zhì)保障!--億恩科技[ENKJ.COM]
|