Friday, December 31, 2010

BaculaFS v0.1.7: Batch Mode

Last night I released BaculaFS v0.1.7. I've added two main features:
  1. batch mode: in this mode BaculaFS behaves as a frontend for the bextract utility, and will launch it in order to extract the list of files, specified by BaculaFS' cache prefetch options, to the path pointed to by the mount point parameter
  2. cache prefetch from a list of files
These two features were designed to allow operations like the following:
  1. incremental update of a snapshot on a mounted storage device, in a single command:
    baculafs -o batch_extract,prefetch_diff=/path/to/snapshot,cleanup -o client=client-fd,fileset=client-fileset /path/to/snapshot/
  2. if the destination snapshot is on a remote file system, you can either mount it as a local filesystem (e.g. with sshfs) and then use -o prefetch_diff to prefetch the modified files before copying them with rsync, or generate the file prefetch list with rsync like this:
    # mount a view of the current bacula backup
    baculafs -o client=client-fd,fileset=client-fileset,prefetch_symlinks /path/to/first/mount/point
    # mount another view, this time with prefetch list generated by rsync
    rsync -in --out-format='/%n' -a /path/to/first/mount/point/ /url/or/path/of/remote/snapshot/ | baculafs -o prefetch_list=-,client=client-fd,fileset=client-fileset /path/to/second/mount/point
    # and now copy files for real
    rsync -a /path/to/second/mount/point/ /url/or/path/of/remote/snapshot/
    fusermount -u /path/to/first/mount/point
    fusermount -u /path/to/second/mount/point
Happy New Year!

No comments:

Post a Comment