Hi,

07.07.2007 00:24,, Chris Morris wrote::
> Greetings!
> 
> I am using amd and snapshot

Puh... I wouldn't do this (partly due to the problems you encounter). 
Simpler, IMO, is to set up a run before job that creates and mounts 
the snapshot, and a run after job that removes it.

To be on the safe side, a daily or weekly removal of any stale 
snapshots might be reasonable.

> in conjunction with bacula to ensure that 
> our servers back up cleanly due to installed databases.  My problem 
> centers around a race issue in which I must guarantee that Bacula is 
> able to back up a snapshot directory before amd automatically unmounts 
> it.  Details are as follows.
> 
> We need to take a snapshot of the /usr and the /var filesystem.  These 
> snapshots get stored in /snap, such that we end up with 
> /snap/var:autogen_bkup.0 and /snap/usr:autogen_bkup.0 once the snapshots 
> are taken.  A frustrating detail turned up the fact that these are 
> mearly symlinks.  The actual snapshot is stored in /.am/<server 
> name>/snap/var:autogen_bkup.0.  (the same for usr:autogen_bkup.0)
> 
> This is all fairly straightforward.  We just set up the FileSet resource 
> to back up the /.am filesystem and everyone is happy. 
> 
> Except, there is that race condition.  I said we were using amd with 
> this.  It's set up in such a way that if we perform the snapshot and 
> then navigate to the /snap directory, there is nothing there.  It's not 
> until you explicitly cd into /var:autogen_bkup.0 that amd mounts the 
> filesystem (symlink) for us.  Once you explicitly cd into that 
> directory, amd will mount it for a time.  Once the mount is left alone 
> for X minutes, amd does its thing and unmounts the volume.

My first idea was to use a run before script that changes its working 
directory into these directories and simply sleeps until killed. Then, 
in a run after job script, kill the script.

> My concern is that between the time the snapshot is created and the time 
> it takes bacula to get around to backing up that directory, the mount 
> will have disappeared.  This brings me to my questions...
> 
> Does anyone out there have a snapshot system running with Bacula?

Well, the ones I know don't use automounting.

> Does anyone have enough experience with amd to get me pointed in the 
> right direction?
> 
> Also, a side question.  I first tried to get bacula to backup from /snap 
> directory.  (instead of /.am)  As it turns out, bacula was only backing 
> up the symlink.  Is there a way to get bacula to intelligently backup 
> symlinks? 

This *is* the intelligent behaviour IMO.
If you want the "real" files, you've got to point Bacula to them.

> This is my first post.  If more information is needed to answer the 
> question, I will gladly supply it.  I want to thank you in advance for 
> taking the time to help me with my problems.  I only hope that some day 
> I can return the favor.


Arno

> Thank you,
> 
> Chris Morris
> 

-- 
Arno Lehmann
IT-Service Lehmann
www.its-lehmann.de

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to