Hi,
Did you try the archive function of backuppc ?
http://backuppc.sourceforge.net/faq/BackupPC.html#archive_functions
I'm using this function in a script (found in the archives of the list) to
create some tar.gz archive of my hosts, then put them on a tape for offsite
storage, with a cron job :
DIR=/backup/backuppc/pc
HOSTS='host1 host2 host3 host4'
DIR_GZ=/backup/tmp
rm -f $DIR_GZ/*
for h in $HOSTS
do
LAST_FULL=`tail -1 $DIR/$h/backups | awk {'print $1'}`
echo "$h $LAST_FULL"
#one line command
/usr/share/backuppc/bin/BackupPC_archiveHost
/usr/share/backuppc/bin/BackupPC_tarCreate /usr/bin/split /usr/bin/par2 $h
$LAST_FULL /bin/gzip .gz 0000000 /backup/tmp 0 "*"
done
Hope that helps,
Pierre-Damien
> -----Message d'origine-----
> De : [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] De la
> part de Tomasz Chmielewski
> Envoyé : mercredi 11 octobre 2006 12:56
> À : backuppc-users
> Objet : [BackupPC-users] how to retrieve last backup for a
> host (fromcommand line)?
>
> I have X hosts, and would like to write a script to retrieve
> last backups from these hosts, and save it as host1.tar,
> host2.tar etc. - to later write it to a tape.
>
> What is the best method to do that?
>
> Should I just tar the current BackupPC archives like below?
>
> tar -cf host1-last.tar /backuppc-data/pc/hosts/host1/<last_backup>
> tar -cf host1-last.tar /backuppc-data/pc/hosts/host2/<last_backup>
>
> Or is there a better method?
>
> The above seems to have an advantage that I don't have to "repack"
> everything (i.e., uncompress from BackupPC format, than make
> a tar package out of it) - but I'm not sure if I can restore
> such a backup reliably later on.
>
>
> Or should I do it some other way?
>
>
> --
> Tomasz Chmielewski
> http://wpkg.org
>
> --------------------------------------------------------------
> -----------
> Using Tomcat but need to do more? Need to support web
> services, security?
> Get stuff done quickly with pre-integrated technology to make
> your job easier Download IBM WebSphere Application Server
> v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&
> dat=121642
> _______________________________________________
> BackupPC-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/backuppc-users
> http://backuppc.sourceforge.net/
>
______________________________________________________________________
Ce message contient des informations dont le contenu est susceptible d'etre
confidentiel.
Il est destine au(x) destinataire(s) indique(s) exclusivement.
A moins que vous ne fassiez partie de la liste des destinataires, ou que vous
soyez habilite a recevoir le mail a leur place, il vous est interdit de le
copier, de l'utiliser ou de devoiler son contenu a un tiers.
Si vous avez recu cet email par erreur, merci de prendre contact avec
l'emetteur.
Les opinions exprimees dans cet e-mail sont celles de l'emetteur et ne
refletent pas necessairement celles de l'entreprise.
Ce e-mail peut contenir des pieces jointes dont certaines pourraient contenir
des virus qui pourraient endommager votre systeme informatique.
La compagnie a pris toutes dispositions afin de minimiser ce risque et decline
toute responsabilite pour toute perte ou dommage resultant directement ou
indirectement de l'utilisation de cet email ou de son contenu.
Il vous appartient d'effectuer vos propres controles anti-virus avant d'ouvrir
la ou les pieces jointes.
______________________________________________________________________
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
BackupPC-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/backuppc-users
http://backuppc.sourceforge.net/