background image
<< B. Oracle on the AIX OS Scripts | Running Scripts as Root >>
<< B. Oracle on the AIX OS Scripts | Running Scripts as Root >>

Dispaly whirl durring operations

Oracle on the AIX OS Scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
B-2
Remote Mirroring of an Oracle Database Using Data Replicator Software
TMP_FILE[1]=./~tmp1.erm
TMP_FILE[2]=./~tmp2.erm
TMP_FILE[3]=./~tmp3.erm
typeset -u ANS=N ANS2=N
typeset -i COUNTER=0 STATUS=0 CHOICE=0
typeset X TEMP TMP_SID TMP_HOME
# Used to improve readability
B1=`tput setaf 1``tput setab 0`
B2=`tput setaf 2``tput setab 0`
B3=`tput setaf 3``tput setab 0`
B4=`tput setaf 4``tput setab 0`
EB=`tput sgr0`
#-------------------------------------------------------------
# Start Function definitions
#-------------------------------------------------------------
prompt_usr ()
{
# Function used to automate responses
echo "Correct (Y or N)? [Y]\b\b\c"
read ANS
if [[ ! -n $ANS || $ANS == 'Y' ]]; then
return 0
else
return 1
fi
}
rotate ()
{
# FUNCTION used to dispaly whirl durring operations
INTERVAL=0
TCOUNT="0"
while :
do
TCOUNT=`expr $TCOUNT + 1`
case $TCOUNT in
"1") echo "|\b\c"
sleep $INTERVAL
ps > /dev/null; ps > /dev/null; ps > /dev/null ;;
"2") echo "/\b\c"
sleep $INTERVAL
ps > /dev/null; ps > /dev/null; ps > /dev/null ;;
"3") echo '-'"\b\c"
sleep $INTERVAL
ps > /dev/null; ps > /dev/null; ps > /dev/null ;;
"4") echo '\\'"\b\c"
sleep $INTERVAL