#!/bin/ksh
if [[ "${1}" = "" ]]
then
print "\nEnter labname: \c"
read LAB
else
LAB="${1}"
fi
if [[ ! -f /home/fsbu/logs/reloadlog-${LAB} ]]
then
print "\nInvalid labname .. Goodbye!\n"
exit 1
fi
print "\nLast reload data is: \n"
DATA="$(grep "Started user=" /home/fsbu/logs/reloadlog-${LAB} | tail -1)"
if [[ "$(print "${DATA}" | grep fsbu)" != "" ]]
then
DATA="$(grep " ${LAB} " /home/fsbu/data/labtool/jobs/.log | tail -1)"
fi
print "${DATA}\n"
if [[ "${1}" = "" ]]
then
print "\nEnter labname: \c"
read LAB
else
LAB="${1}"
fi
if [[ ! -f /home/fsbu/logs/reloadlog-${LAB} ]]
then
print "\nInvalid labname .. Goodbye!\n"
exit 1
fi
print "\nLast reload data is: \n"
DATA="$(grep "Started user=" /home/fsbu/logs/reloadlog-${LAB} | tail -1)"
if [[ "$(print "${DATA}" | grep fsbu)" != "" ]]
then
DATA="$(grep " ${LAB} " /home/fsbu/data/labtool/jobs/.log | tail -1)"
fi
print "${DATA}\n"

2263

被折叠的 条评论
为什么被折叠?



