

























这里我们以:CENTOS 7.6 64为例
安装宝塔
yum install -y wget && wget -O install.sh https://download.bt.cn/install/install_6.0.sh && sh install.sh ed8484bec
输入y回车确认安装
安装环境:
Nginx1.22
mysql5.6
PHP-5.6
宝塔放行端口:1-65535
关闭防火墙
systemctl stop firewalld.service
systemctl disable firewalld.service
上传data.tar.gz到服务器根目录(根目录不是root目录!!使用WinSCP或其他工具上传数据,也可以直接宝塔传!!)
解压data.tar.gz
cd /
tar zxvf data.tar.gz
安装jdk
cd /data
rpm -ivh jdk-8u144-linux-x64.rpm
宝塔添加网站
IP+端口99
目录指向:/data/cdnweb
创建第二网站
127.0.0.1:88
目录指向:/data/gameweb
网站设置 – 访问限制
加密访问目录:/yunfanManager/
名称:yunfanManager
用户名:123456
密码:456789
网站目录赋权
chown -R www:www /data/gameweb
chmod -R +x /data/gameweb
设置数据库root密码为:game10086…A123456…
调整mysql性能 选择4-8配置
宝塔–软件商店–已安装–mysql管理–二进制日志–关闭
导入数据库
cd /data/sql/ && sh initsql.sh
修改数据库
宝塔–运行环境–安装phpmyadmin4.0
宝塔–数据库–phpmyadmin–通过面板访问
修改数据库【game_manager】里【host】表
ip–服务器IP
user_name–服务器用户名root
password–服务器密码(重装系统设置的密码)
domain–服务器IP
修改服务端文件IP 替换“103.216.152.7”
/data/gameweb/yunfanManager/config/globalConfig.js
复制这条命令 把 www.syymw.com 改成你自己ip
find /data -type f -name ‘*.*’ | xargs sed -i ‘s/103.216.152.7/www.syymw.com/g’
文件不存在正常 等待就行
启动redis
cd /data/redis && ./start-redis.sh
启动tomcat
cd /data/xkm-tomcat/bin && ./startup.sh
启动log
cd /data/game/log-server/bin && sh startup.sh
进入后台
http://ip:88/yunfanManager
加密访问用户名:123456
加密访问密码:456789
后台主账号:admin
后台主密码:admin123456
登录后台点击
内线1服 点操作 开服
等待2分钟即可
游戏地址:
http://IP:99/index1.php
运营后台:
http://ip:88/yunfanManager
加密访问用户名:123456
加密访问密码:456789
后台主账号:admin
后台主密码:admin123456
关闭游戏命令:
停止redis
cd /data/redis && ./stop-redis.sh
停止tomcat
cd /data/xkm-tomcat/bin && ./shutdown.sh