[PVE-User] vzmigrate: use --sparse on the first rsync

Dietmar Maurer dietmar at proxmox.com
Mon Sep 19 16:57:01 CEST 2011


Please can you post that the the openvz list (or openvz bug tracker)?

(vzmigrate is part of openvz)

> -----Original Message-----
> From: pve-user-bounces at pve.proxmox.com [mailto:pve-user-
> bounces at pve.proxmox.com] On Behalf Of John O. Stevens
> Sent: Montag, 19. September 2011 14:31
> To: pve-user at pve.proxmox.com
> Subject: Re: [PVE-User] vzmigrate: use --sparse on the first rsync
> 
> I thought that vzdump was called during migration of containers, but it seems it's
> not, so I added the same option to the first rsync in vzmigrate, to help with
> sparse files during a migration.
> 
> I tested it with:
> 
>   vzmigrate -r no --keep-dst -v host2 CTID
> 
> And with this patch, sparse files are not expanded, as expected.
> 
> jos
> 
> --- vzmigrate.orig      2011-09-19 14:14:43.000000000 +0200
> +++ vzmigrate   2011-09-19 14:16:37.000000000 +0200
> @@ -443,7 +443,7 @@
>  fi
> 
>  log 1 "Syncing private"
> -$RSYNC "$VE_PRIVATE" "root@$host:${VE_PRIVATE%/*}"
> +$RSYNC --sparse "$VE_PRIVATE" "root@$host:${VE_PRIVATE%/*}"
>  # Ignore rsync error 24 "Partial transfer due to vanished source files"
>  if [ $? != 24 ] && [ $? != 0 ]; then
>         log 0 "Failed to sync container private areas"
> _______________________________________________
> pve-user mailing list
> pve-user at pve.proxmox.com
> http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-user





More information about the pve-user mailing list