Re: [Networker] Cloning all incrementals for a client or group

2008-05-30 18:04:01
Subject: Re: [Networker] Cloning all incrementals for a client or group
From: Tim Mooney <Tim.Mooney AT NDSU DOT EDU>
Date: Fri, 30 May 2008 16:58:45 -0500
In regard to: [Networker] Cloning all incrementals for a client or group,...:

I would like to be able to clone all incremental backups since the last
full for a client  or group to a tape each day. I cannot figure out how
to do this, or if it is even possible.

The hard part is answering "when was the last full?", in a robust way.  It
gets complicated when you account for the fact that different filesystems
may have had their most recent fulls on different days (for any number of
reasons, backup failures being the most common).

The way I would do it is to first figure out all of the filesystems for
a particular client.  That can be done with something like this (on

for f in `mminfo -q "client=$client,level=full" -r 'name' | sort -u`
        last_full=`mminfo -ot \
                -q "client=$client,level=full,name=$f" -r 'savetime' | tail -n 
        echo "Last full for $client fs=$f was $last_full"

Once you have that figured out, finding the incrementals is easy: you just
replace the "echo" with

        mminfo -ot \
                -q "client=$client,level=incr,savetime>$last_full,name=$f" \
                -r 'ssid'

That should generate the list of ssids for all incrementals since the
most recent full for all filesystems for the specified client.  Stick
those in a file and run nsrclone with that list of ssids, and it should
accomplish what you want.

Tim Mooney                                        Tim.Mooney AT ndsu DOT edu
Information Technology Services                   (701) 231-1076 (Voice)
Room 242-J6, IACC Building                        (701) 231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164

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 or
via RSS at

<Prev in Thread] Current Thread [Next in Thread>