109 lines
6.2 KiB
Plaintext
109 lines
6.2 KiB
Plaintext
combine setp:
|
|
1、maintain server
|
|
cd /data/git/dev_ops/wjtx_tools/ops_tools
|
|
python wjtx_global_tools.py -m maintain -s 1-3
|
|
|
|
2、 close auto load in ops:
|
|
|
|
3、stop service && backup redis && backup mysql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_241 >legend_241.sql
|
|
4、run scripts
|
|
cd /root/opensource/migrate_server/wjtx/tools/combine_db/script
|
|
python combine_db.py
|
|
python combine_redis.py
|
|
drop database
|
|
cd /data/git/dev_ops/wjtx_tools/ops_tools && python wjtx_tools.py -t initdb -s 2008
|
|
cd /root/opensource/migrate_server/wjtx/tools/combine_db/script/out
|
|
mysql -uroot -p0usmUwROtWjf -h10.10.6.2 legend_237 -e"source all.sql"
|
|
cd ..
|
|
python import_redis.py 10.10.6.59 6381 out/game_redis.script
|
|
python import_redis.py 10.10.6.4 6379 out/global_redis.script
|
|
5、start service && change service to open && autoload
|
|
python wjtx_global_tools.py -m open -s 1-3
|
|
cd /data/git/dev_ops/wjtx_tools/ops_tools && python wjtx_tools.py -t autoload
|
|
====================================================step 1===============================================
|
|
10.10.6.59 61-64
|
|
|
|
python wjtx_global_tools.py -m maintain -s 237-247
|
|
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_237 >legend_237.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_242 >legend_242.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_243 >legend_243.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_244 >legend_244.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_245 >legend_245.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_246 >legend_246.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_247 >legend_247.sql
|
|
|
|
python wjtx_tools.py -t initdb -s 237
|
|
mysql -uroot -p0usmUwROtWjf -h10.10.6.2 legend_237 -e"source all.sql"
|
|
python import_redis.py 10.10.6.59 6381 out/game_redis.script
|
|
python import_redis.py 10.10.6.4 6379 out/global_redis.script
|
|
|
|
====================================================step 2===============================================
|
|
10.10.6.162 165-170
|
|
|
|
python wjtx_global_tools.py -m maintain -s 4024-4039
|
|
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4024 >legend_4024.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4032 >legend_4032.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4033 >legend_4033.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4030 >legend_4030.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4035 >legend_4035.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4036 >legend_4036.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4037 >legend_4037.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4038 >legend_4038.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4039 >legend_4039.sql
|
|
|
|
|
|
python wjtx_tools.py -t initdb -s 4024
|
|
mysql -uroot -p0usmUwROtWjf -h10.10.6.2 legend_4024 -e"source all.sql"
|
|
python import_redis.py 10.10.6.162 6382 out/game_redis.script
|
|
python import_redis.py 10.10.6.4 6379 out/global_redis.script
|
|
====================================================step 3===============================================
|
|
10.10.6.203 208-210
|
|
|
|
python wjtx_global_tools.py -m maintain -s 5002-5019
|
|
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_5005 >legend_5005.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_5015 >legend_5015.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_5016 >legend_5016.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_5017 >legend_5017.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_5018 >legend_5018.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_5019 >legend_5019.sql
|
|
|
|
|
|
python wjtx_tools.py -t initdb -s 5005
|
|
mysql -uroot -p0usmUwROtWjf -h10.10.6.2 legend_5005 -e"source all.sql"
|
|
python import_redis.py 10.10.6.203 6381 out/game_redis.script
|
|
python import_redis.py 10.10.6.4 6379 out/global_redis.script
|
|
======================================0729=====================================================================
|
|
python wjtx_global_tools.py -m maintain -s 237-251
|
|
10.10.6.59
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_237 >legend_237.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_248 >legend_248.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_249 >legend_249.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_250 >legend_250.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_251 >legend_251.sql
|
|
|
|
|
|
python wjtx_tools.py -t initdb -s 237
|
|
mysql -uroot -p0usmUwROtWjf -h10.10.6.2 legend_237 -e"source all.sql"
|
|
python import_redis.py 10.10.6.59 6381 out/game_redis.script
|
|
python import_redis.py 10.10.6.4 6379 out/global_redis.script
|
|
===========================================================================================================
|
|
10.10.6.162 165-170
|
|
|
|
python wjtx_global_tools.py -m maintain -s 4024-4042
|
|
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4024 >legend_4024.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4040 >legend_4040.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4041 >legend_4041.sql
|
|
mysqldump --default-character-set=utf8 -uwjtx -pmMWA4DKCfeOL -h10.10.6.2 legend_4042 >legend_4042.sql
|
|
|
|
|
|
|
|
python wjtx_tools.py -t initdb -s 4024
|
|
mysql -uroot -p0usmUwROtWjf -h10.10.6.2 legend_4024 -e"source all.sql"
|
|
python import_redis.py 10.10.6.162 6382 out/game_redis.script
|
|
python import_redis.py 10.10.6.4 6379 out/global_redis.script
|
|
=========================================================================================================== |