cancel
Showing results for 
Search instead for 
Did you mean: 

unassisted tape ejections - vmchange command

dave456
Level 2

Hi guys, 

I have a bit of a tricky problem here and was wondering if anyone can help me out? I have an official call with Symantec for this case but don’t seem to be getting anywhere with it... 

 

I am on have recently moved to netbackup 6.5 from 4.5 (via 5.1- Solaris 10) and appear to have lost the ability to retain automatically ejected tapes in the MAP. (I had a cron'ed script which ran each morning at 07:00 which selected the appropriate tapes and put them into the MAP to be picked by on-site ops) 

 

I am using the following command as taken from the /opt/openv/netbackup/script/unload_tapes.ksh script distrubuted with my orginal netbackup package: 

 

$VMCHANGE -multi_eject -w -h $VDBHOST -res -verbose -ml `cat <list of tapes>` -rn 0 -rt TLD -rh $VDBHOST << EOI
Y
EOI
 

 

It appears that the EOI function passes the Y as usual to signal the end of the ejection process - the problem appears to be that version 6.5 immediately checks the inventory, realises that the tapes are still in the MAP and pulls them back into the main robot (4.5 and 5.1 didn’t appear to do this).

 

I have tried to insert a sleep 360 command into the EOI function before the 'Y' to delay this check but to no avail: 

 

Sep 10 16:49:29 npb-backup tldcd[3977]: [ID 737109 daemon.notice] TLD(0) initiating MOVE_MEDIUM from addr 37 to addr 20
Sep 10 16:49:54 npb-backup tldcd[3977]: [ID 735078 daemon.notice] TLD(0) initiating MOVE_MEDIUM from addr 43 to addr 21
Sep 10 16:50:14 npb-backup tldcd[3977]: [ID 325223 daemon.notice] Scanning media access ports for tapes that weren't removed.
Sep 10 16:50:14 npb-backup tldcd[3977]: [ID 854075 daemon.notice] TLD(0) initiating MOVE_MEDIUM from addr 20 to addr 37
Sep 10 16:50:32 npb-backup tldcd[3977]: [ID 975142 daemon.notice] TLD(0) initiating MOVE_MEDIUM from addr 21 to addr 43

 

If I drop the '-w' , or wait option, from the command line (which is not recommended) it does leave the tapes out until the hard coded ejection timeout of 30 minutes is reached. 30 minutes is long enough for the ops to remove the tapes but it does however tie up the robot until then and I don’t think it is a viable long term option:

 

 "External request already in progress on TLD(0), from host npb-backup"

 

 It wont re-inventory or allow you to perform any admin commands on the robot and just responds with 'robot is busy' and the above message in /adm/messages.  

 

I have searched through vmchanges's options and cant seem to get any way past this problem. Currently I have to use the GUI but was wondering if anyone has got round this problem before or if anyone has any suggestions to resolve it? 

 

Thanks in advance - and apologies for the length of this post 

 

Dave

7 REPLIES 7

Doctorski
Level 5

Dave,

        I use the following vmchange command with success.

 

vmchange -res -m ${EJECT_ID} -mt ${MEDIA_TYPE} -rh ${ROBOT_HOST} -rn ${ROBOT_NUM} -rt ${ROBOT_TYPE} -rc1 ${ROBOT_SLOT} -e -sec 1

 

All the parameters are awked out of  a vmquery -m ${EJECT_ID}

 

I didnt have to supply -rh -rt -rc1 pre 6.5 days.

 

I find it strange that you have to tell Netbackup where a tape is when it already knows !

          

Patrick_Whelan_
Level 6

Change the Y to an N. That should finish up the eject, but keep the tapes in the CAP. I have noticed, from the GUI, that if you say Y, before you've removed the tapes, it puts them all back. :(

 

 

J_H_Is_gone
Level 6
I agree with Patrick.... we do that a lot,  do the eject but say N.  this leaves the tapes in the map until we can get to them ( very helpfull on holidays when we don't want two days on the same tapes, from home I just eject to the map, and take them out on tuesday).

dave456
Level 2

Hi, 

 

Changing the option to 'N' seemed like the perfect solution so I have tried it first: 

 

vmchange -multi_eject -w -h npb-backup -res -verbose -ml 2327L1 -rn 0 -rt TLD -rh npb-backup 

*** Eject volume batch #1 is ready to be removed ***
        remove 1 volume(s) from media access port(s) of robot number 0 now
        (press <RETURN> to continue)
 

 

Unfortunately it appears that the command is only waiting on a <return> rather than any input from the user. I did try entering 'N' but as expected when hit <enter> it discovered the tapes in the MAP and returned them to their original locations.. :( 

 

I'll try Darren’s suggestion and let you know how I get on. 

 

Thanks again 

Dave

 

zippy
Level 6

#NEW
        $VM_DIR/vmchange -res -m $MEDIA -mt hcart -e -rh $HOST -rt tld -rn 0 -rc1 $SLOT \
        -verbose < $EXE_DIR/enter 2>&1 |tee -a $DATA_DIR/OV_eject.log 2>&1
#####################
#OLD
#####################
#    $VM_DIR/vmchange -res -m $MEDIA -mt hcart -e -rh $HOST -rt tld -rn 0 -rc2 $SLOT \
#      -verbose < $EXE_DIR/enter 2>&1 |tee -a $DATA_DIR/OV_eject.log 2>&1

 

dave456
Level 2

Hi,

Changing the volumes residence appears to be doing the trick. Even better is that it doesnt mind that a tape is already in the MAP :) This then means it is a simple matter of putting the below script inside a loop and awk'ing in the appropriate fields :

 

vmchange -res -m <2482L1> -mt hcart -rh <npb-backup> -rt tld -rn 0 -rc1 <50> -e -sec 1.

 

Thank you all very much for this - it will make my life a lot easier.

 

Cheers

 

Dave

mph999
Level 6
Employee Accredited

Not sure which library you have but ...

 

vmchage -multi_eject .. but use -single_cycle option also might help.

 

If you library have a virtual i/o (cap) eg. IBM 3584 then disable it (on the robot).

 

Martin