文件: allstop.sh allstart.sh
路径 $HOME/ggscript/ggoperat
l运维OGG过程中,曾经遇到非数据同步运维同事需要配合数据库DBA维护启停所有数据同步链路的情况
因此特别编写了这两套全进程启停脚本,一套用于全进程停止,会调用长事务跳过脚本,跳过长事务,以及停止进程和MGR监控进程。一套用于全部OGG进程启动。
allstop.sh#!/bin/bash
echo $dir
cd $HOME/ggscript/ggoperat
dir=$PWD
cd $HOME
if [ -f .profile ];then
. .profile
fi
if [ -f .bash_profile ];then
. .bash_profile
fi
cd $dir
echo "All process will be stop! Are you sure will do this job?(press any key to continue)"
select ch in "yes" "no"
do
case $ch in
"yes")
echo "execute the process stop operation"
break;
;;
"no")
echo "process break"
exit 2;
;;
*)
echo "Please select your c