Networker

Re: [Networker] VMWARE Backups

2007-11-16 14:36:07
Subject: Re: [Networker] VMWARE Backups
From: Ken Gehring <ken.gehring AT GMAIL DOT COM>
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Date: Fri, 16 Nov 2007 12:30:01 -0700
Well, this is what we do (a bit dumb, but it works for us). First, we
don't really need to backup "all" of the vmware instances, so we've
have a policy that says that if there is a space in the name of the
instance, skip it. So, this is what we do (on each esx 3 server), and
it is run via savepnpc.

1) get a list of all the names of all of the instances to be backed up
on the server
       /usr/sbin/vcbVmName -s any | grep name | grep -v " " >>
/tmp/save-results
2) for each host in the list, do a snapshot into a separate disk area,
backup the snapshot, release (undo) the snapshot
3) after all that is done via savepnpc, then backup the server.

Here is the script we use. Hope it helps.

# Change the variables below to reflect your environment
#
# The POOL variable can be changed to whatever pool you need as required.

HASH="#########################################################################"
HOST=`hostname`
POOL="Default"
DEST="some-disk-area-on-the-san"
SRVR="networker-server-name"

echo "Subject: save results for $HOST" > /tmp/save-results$HOST
echo "" >> /tmp/save-results$HOST
echo "" >> /tmp/save-results$HOST
echo "VM Instances that will be backed up" >> /tmp/save-results$HOST
/usr/sbin/vcbVmName -s any | grep name | grep -v " " >> /tmp/save-results$HOST
echo "" >> /tmp/save-results$HOST


/usr/sbin/vcbVmName -s any | grep name | grep -v " " > /tmp/vm-instances
for I in `cat /tmp/vm-instances`
       do
               echo $HASH >> /tmp/save-results$HOST
               date >> /tmp/save-results$HOST
               /usr/sbin/vcbMounter -a $I -r /vmfs/volumes/$DEST/$I
               echo "$I" >> /tmp/save-results$HOST
               date >> /tmp/save-results$HOST
               /usr/sbin/save -s $SRVR -b $POOL -l full -c $HOST -N
"/vmfs/volumes/$DEST/$I"  /vmfs/volumes/$DEST/$I 2>>
/tmp/save-results$HOST
               date >> /tmp/save-results$HOST
               echo "" >> /tmp/save-results$HOST
               /usr/sbin/vcbMounter -U /vmfs/volumes/$DEST/$I
               echo $HASH >> /tmp/save-results$HOST
       done

On Nov 16, 2007 12:10 PM,  <Fazil.Saiyed AT anixter DOT com> wrote:
>
> sure, i would like to look at your method and even try it in our test
> environment, meanwhile i would also be interested in know how the vranger
> project goes, what i am not cear on is once the vranger presents the luns to
> the proxy server, what method do you employ ( Tapes, backup software) to get
> it to VTL or Tape?
> How do the recovery work, do you have to restore the lun to proxy server and
> let vranger then do the restore ?
> How do you keep track of guests and vmservers while all this different luns
> are getting mounted ?
> More detail you can give it may be better.
> Thanks



-- 
They that can give up essential liberty to obtain a little
temporary safety deserve neither liberty nor safety.
--Benjamin Franklin

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

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