Networker

Re: [Networker] Selecting the first tape an nsrclone will need

2008-10-14 08:15:16
Subject: Re: [Networker] Selecting the first tape an nsrclone will need
From: Francis Swasey <Frank.Swasey AT UVM DOT EDU>
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Date: Tue, 14 Oct 2008 08:11:42 -0400
On 10/14/08 1:20 AM, tkimball wrote:
Francis Swasey wrote:
So, my question is: What is the best algorithm to use to determine which ssid will be the first one NetWorker will decide to clone from a list of ssid's. My current algorithm is picks the first tape from the ssid that has the earliest start time. This morning, that didn't work and NetWorker mounted a different tape -- so, obviously, my algorithm isn't the best.

Is anyone else doing scripted cloning and using an algorithm to pre-mount the first source tape to force where the cloning happens?



I'm doing something like that, but it's a bit convoluted:

1) Grab a listing of SSID/volume pairs + flags
2) generate summary data containing # of complete and 'head' savesets for each 
volume
3) mount each volume in series, with the first volume being the one with the 
most full (then the most 'head' SSIDs).  Kick off the clone of that listing.
4) sleep 10 mins (allow ejects) and repeat #3 until all tapes done.

I determine 'what source pool mounts to what SN' by a config file that is 
referenced; It includes an approximate number of hosts that should be in the 
backup, so we know (in theory) if there's a miscount someplace.

Having a config file for what SN the tapes mount to, allow me to switch systems 
if a drive has failed on one of them (we only have two LTO on each of Server 
and SN right now).

I'm posting the relevant portion of the script below.  Warning, its in csh.  ;)

--TSK
Aha! Thank you! I had completely overlooked the possibility of breaking the given list of ssid's down further and running nsrclone with a set of ssid's that are known to be completely contained or at least start on the tape that I mount! That's brilliant!!!!

Now to go write that algorithm in perl -- which is slightly less likely to cause brain damage than csh :-)

Frank

To sign off this list, send email to listserv AT listserv.temple DOT edu and type 
"signoff networker" in the body of the email. Please write to networker-request 
AT listserv.temple DOT edu if you have any problems with this list. You can access the 
archives at http://listserv.temple.edu/archives/networker.html or
via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER