Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Unable to kill a job

Status
Not open for further replies.

wamason

MIS
May 15, 2000
246
US
I tried killing a job that had a tape stuck in the drive. I got the tape out but the drive, but the job still shows active. I tried killing the job several times without success.
 
Try kill -9 on the process (if on a Unix server)
or "end process" via Task manager (if on an NT server)
or you can delete the job from /usr/openv/netbackup/db/jobs... pick up the job number from the Job Monitor, then delete the job from that directory. It is advisable to bounce Netbackup after you have done this or even better reboot the server.

Simon Goldsmith
Storage Engineer
 
Here is a script that I wrote (You need to enter in the job ID into JOBID=d:/Veritas/ScriptFiles/Delete_Hung_Jobs/job_id.txt):


#!/bin/ksh
#
#
###############################################################################
#
# Name: Delete_Hung_Jobs_KILL.ksh
# Purpose: This script is part 2. The first gathers all the
# information and this deletes the information to clear the
# event log in the GUI.
#
# Modified by: Steve Staves
# Date Created: August 19th, 2003
# Date Modified: August 19th, 2003
#
###############################################################################
#
# Set up variables

MASTER=master_server
VOLDIR=d:/VERITAS/VOLMGR/BIN
BPDIR=d:/veritas/netbackup/bin/admincmd
TMPF=d:/Veritas/ScriptFiles/Delete_Hung_Jobs/Job_Deleted_Killed.txt
JOBID=d:/Veritas/ScriptFiles/Delete_Hung_Jobs/job_id.txt
DBLOGS=d:/Veritas/Netbackup/db/Jobs
PROCESS_IDS=d:/Veritas/ScriptFiles/Delete_Hung_Jobs/process_ids.txt

##################################################################
#
# Initialize Log File

rm $TMPF

##################################################################
#
# Main body of Script

cat $JOBID | while read LINE
do
case $LINE in
*)
echo "<><><><><><><><><><><><><><><><><><><><><><><><><>" >> $TMPF
echo "<> `date` <>" >> $TMPF
echo "<><><><><><><><><><><><><><><><><><><><><><><><><>" >> $TMPF
echo "" >> $TMPF
echo "**************************************************" >> $TMPF
echo "* Cancel the Job in the GUI *" >> $TMPF
echo "" >> $TMPF
$BPDIR/bpdbjobs -cancel $LINE
sleep 120
echo "Job ID: "$LINE " has been cancelled" >> $TMPF
echo "" >> $TMPF
echo "**************************************************" >> $TMPF
echo "* Delete the Job in the GUI *" >> $TMPF
echo "" >> $TMPF
$BPDIR/bpdbjobs -delete $LINE
sleep 60
echo "Job ID: "$LINE " has been deleted" >> $TMPF
echo "" >> $TMPF
echo "**************************************************" >> $TMPF
echo "* Delete Associated Files *" >> $TMPF
echo "" >> $TMPF
rm $DBLOGS/ffilelogs/$LINE.* >> $TMPF
rm $DBLOGS/trylogs/$LINE.* >> $TMPF
rm $DBLOGS/restart/$LINE.* >> $TMPF
Sleep 60
$BPDIR/bpdbjobs -delete $LINE
echo "<><><><><><><><><><><><><><><><><><><><><><><><><>" >> $TMPF

if [ "$JOBID" != "$END_OF_LIST" ] ; then
fi
esac
done
 
I use it in Windows but I have the MKS Toolkit installed - i.e. Unix utilities for Windows.
 
perhaps you could try from a DOS command window
...\Veritas\NetBackup\bin\admincmd\bpdbjobs -cancel JobID#

Bob Stump
Incorrigible punster -- Do not incorrige
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top