BackupPC-users

Re: [BackupPC-users] Backing up the backup to an external USB drive

2008-12-11 07:47:10
Subject: Re: [BackupPC-users] Backing up the backup to an external USB drive
From: Adam Goryachev <mailinglists AT websitemanagers.com DOT au>
To: "General list for user discussion, questions and support" <backuppc-users AT lists.sourceforge DOT net>
Date: Thu, 11 Dec 2008 23:45:20 +1100
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Rodrigo Real wrote:
> Hello,
> 
> I've been quiet for some months, but I've been trying to read the 
> messages in the way I can.
> 
> Now I am running to the list to ask a question that has been discussed 
> here some time before (maybe many times), but I could not find a 
> solution that fits exactly on my needs, maybe I wasn't able to identify 
> it...
> 
> Let me tell you the full story...
> 
> I have a backuppc server with 3 250GB Sata disks running in Software 
> RAID-5 with LVM built on top of it. This systems is been running for 
> quite some time now. This server is in a different building from where 
> we have most of our computers and our servers. But now we got a little 
> more paranoid, so we want to backup the backuppc server, and take it 
> home. We want to do this process at least once a month, by now we don't 
> believe that we need a greater frequency.
> 
> So, I bought an USB external drive with 500GB and now I am thinking 
> about what is the best way to do it.
> 
> My first attempt is to dd each partition of the backuppc server and save 
> it as files on the usb disk. This seems to be a simple solution and 
> maybe it is good enough. But I was wondering if it wouldn't be possible 
> to dd the entire installation, and have a sort of "LiveHD". That would 
> be really good and easy to use in case of panic.
> 
> My installation looks like this:
> 
> /dev/mapper/vg-root on / type reiserfs (rw)
> /dev/md0 on /boot type reiserfs (rw,notail)
> /dev/mapper/vg-backup on /var/lib/backuppc type reiserfs (rw)
> 
> I am thinking about creating 3 partitions on the usb hard drive and to 
> dd each of this disks to its corresponding partition. I guess that this 
> could work, but I see that there will be some issues:
>    * After dd I will have to mount the usb system and adjust fstab
>    * I will have to boot on the system on a liveCD to do this, or I will 
> have to remount the root system as read-only to run dd
>    * install grub on the usb disk (never did this...). maybe some 
> adjustments on menu.lst will be needed.
>    * don't know if I can boot the usb drive directly on any computer ( I 
> guess that this is not a problem since I can get a "not old" computer)
> 
> What do you think of this? Does it seems to be reasonable?
> 
> Thanks for any comments or help,
> Rodrigo

Step 1) Use LVM's snapshot feature to take a snapshot of your root and
backuppc partitions.
Step 2) dd the snapshot to the two partitions on your USB HDD

You won't be able to boot from the USB directly, because as you said,
you would need to install grub, adjust the menu.lst, etc to make it
work. If you had a USB drive larger than 500GB, eg, a 750GB drive, then
you could do so much more :)

ie, setup the 3rd partition as the "active" partition, install grub to
this partition, and configure the menu.lst file as needed. Then use the
first two partitions the same as above.

BTW, I think LVM will ensure your FS is in a good state when you do the
snapshot... if not, then you may like to try and ensure you do a sync,
and try to ensure no backups/etc are in progress (ie, the system is as
idle as possible).

Either way, you should be able to boot from a livecd of some sort, but
then use the root FS on the USB, plus some adjustments to the rootfs...

Oh, and in case you were thinking about it, you could just archive the
latest backup to the external drive... though it only gives you a single
backup...

Hope that helps...

Regards,
Adam
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAklBC1sACgkQGyoxogrTyiV39QCffx9oxT6BLid+GVMDWk8BCYvG
xl8AoLbwVvDCksgdZbVzE9k4g52XnleN
=Pzwf
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you.  Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
BackupPC-users mailing list
BackupPC-users AT lists.sourceforge DOT net
List:    https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:    http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/