Selective Timed Staging

From Mesopoly 3.0
Revision as of 08:39, 26 July 2012 by Zlatko (talk | contribs)
Jump to navigation Jump to search
  • To stage savesets from one jukebox to another selectively after some time - a script.
  • Should work with any OS, only the bold lines are really used
REM with mminfo we prepare list of savesets to be cloned
REM selected are savesets that are in their original pool, from client OurClient, that are more than 7 days old
REM list is saved to a file
REM you have to set 'pool', 'client', 'savetime' (age) and 'name' (saveset)  variables according to need as well as name and location of a file that will contain saveset list
REM of course you can use less or more variables, or use entirely different variables (see man mminfo)
mminfo -q "pool=InitialPool,client=OurClient, savetime<7days ago,name=/save/set" -r ssid > C:\ssidvtl1.txt
REM here we instruct Networker to stage savesets whose ssid's are in a file to a Clone pool and log the activity to a file 
nsrstage -m -b DestinationClonePool -S -f C:\ssidvtl1.txt  >> C:\staging_log.txt 2>&1
  • Take care you supply full path info on files used in script or otherwise provide path info
  • If you get following info in your log ..
Successfully deleted original clone 1342605613 of save set 3305539895 from media database.
Recovering space from volume 1358056466 failed with the error 'Space can only be recovered from adv_file and file type devices.'.
Refer to the NetWorker log for details.
6365:nsrstage: Space can only be recovered from adv_file and file type devices.

.. its normal. If you want to free entire space on the tape, take care all savesets are staged first (then relabel)

  • If you already have multiple clones of saveset you are cloning, take care you are using
    ssid/cloneid
    format for saveset list generation as otherwise all other savesets will be deleted at the end of stage-ing process