[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: slow backup using lvm snapshots and tar

On Thu, Nov 05, 2009 at 01:18:48AM -0500, Israel Garcia wrote:
> Hi list:
> I'm using this command to create s snapshot of every LV's server,
> mount the LV, make a TGZ to a shared folder (NFS),  then umount LV
> image and remove snapshot LV. The problem is tar backup is extremely
> slow (it takes 3 hours to make backup of all servers).
> This is the command I'm using:
> for vps in `cat vps`; do lvcreate -L10G -s -n "$vps"snapshot
> /dev/vg0/"$vps".domain-disk && mount /dev/vg0/"$vps"snapshot
> /mnt/vmbackup && cd /mnt/vmbackup && nice -n 19 tar pczf
> /shared/lvbackups/"$vps"_`date +%F` . && cd ; umount /mnt/vmbackup &&
> lvremove -f /dev/vg0/"$vps"snapshot;done
> My question is:
> How can I make TAR backup faster? is it possible? Is there other
> command faster than TGZ in this case?

my guess is you have a single threaded process that is getting blocked
by the NFS - network being the slowest, previously when copy across nfs
(UDP, not tcp), I started 6 rsync to get about 600Mb across the 1G nic.

can I suggest looking at rdiff-backup. same process  snapshot each lvm

and run in parrallel a rdiff-backup of each lv across NFS or instead
across ssh with compression !

that would speed it up, by only sending diff information and compression
and parallelism


> thanks in advance.

standards, n.:
	The principles we use to reject other people's code.

Attachment: signature.asc
Description: Digital signature

Reply to: