手游《三国我为王》Linux手工端+安卓端+搭建教程+GM后台
搭建教程
1.安装环境 服务器必须32位 6.x
yum install -y gcc
yum install -y vim
yum install -y e2fsprogs-devel
yum install -y uuid-devel
yum install -y libuuid-devel
yum install -y bison bison-devel
yum install -y psmisc
yum install -y unzip zip
-----------------------------------------------------------------------------------------------------------------------------------------------------
2.上传home.targz到根目录
cd /
tar -zxvf home.tar.gz
chmod -R 777 /home
-----------------------------------------------------------------------------------------------------------------------------------------------------
3.安装openssl
cd /home/soft/
tar -zxvf openssl-1.0.0.tar.gz && cd openssl-1.0.0
./config --prefix=/usr/local --openssldir=/usr/local/ssl && make clean && make && make install
./config --prefix=/usr/local --openssldir=/usr/local/ssl shared && make clean && make && make install
-----------------------------------------------------------------------------------------------------------------------------------------------------
4.安装mysql
groupadd mysql
useradd mysql -g mysql -s /sbin/nologin
cd /home/soft/ && tar -zxvf mysql-5.5.62-linux-glibc2.12-i686.tar.gz
mv -f mysql-5.5.62-linux-glibc2.12-i686 /home/local/mysql5.5.62
chown -R mysql:mysql /home/local/mysql5.5.62
-----------------------------------------------------------------------------------------------------------------------------------------------------
cd /home/local/mysql5.5.62
scripts/mysql_install_db --basedir=/home/local/mysql5.5.62 --datadir=/home/local/mysql5.5.62/data --user=mysql
cp /home/local/mysql5.5.62/support-files/mysql.server /etc/init.d/mysqld
chmod +x /etc/init.d/mysqld && chkconfig --add mysqld && chkconfig --level 2345 mysqld on && chkconfig --list
-----------------------------------------------------------------------------------------------------------------------------------------------------
编辑/etc/init.d/mysqld 46 47 行
basedir=/home/local/mysql5.5.62/
datadir=/home/local/mysql5.5.62/data/
编辑 /etc/profile
export PATH=$PATH:/home/local/mysql5.5.62/bin
然后
source /etc/profile
-----------------------------------------------------------------------------------------------------------------------------------------------------
my.cnf 上传到 etc目录
-----------------------------------------------------------------------------------------------------------------------------------------------------
编辑/etc/ld.so.conf
加入
/usr/local/lib/
/home/local/mysql5.5.62/lib
然后
ldconfig
ln -s /home/local/mysql5.5.62/lib/libmysqlclient.so.18 /usr/lib/
-----------------------------------------------------------------------------------------------------------------------------------------------------
service mysqld start
chkconfig mysqld on
-----------------------------------------------------------------------------------------------------------------------------------------------------
mysqladmin -u root password 12345
mysql -uroot -p12345
GRANT ALL PRIVILEGES ON *.* TO root@'127.0.0.1' IDENTIFIED BY '12345' WITH GRANT OPTION;
GRANT ALL PRIVILEGES ON *.* TO root@'%' IDENTIFIED BY 'sants.cn' WITH GRANT OPTION;
flush privileges;
quit
-----------------------------------------------------------------------------------------------------------------------------------------------------
原文链接:https://vuesite.cn/17184.html,转载请注明出处。