hi all, What is the preferred method/tool to backup Xen guests? Xm save and DD seems to work but ''xm save'' stops the virtual machine and DD is slow. Any better option? I am under CentOS/DRBD Thanks Paras. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
> hi all, > > What is the preferred method/tool to backup Xen guests? > > Xm save and DD seems to work but ''xm save'' stops the virtual machineand> DD is slow. > > Any better option? > > I am under CentOS/DRBD >I use Bacula and treat the VM''s like normal computers. Alternatively you could use LVM to create a snapshot and back that up, assuming you are using LVM in the first place. James _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
With DRBD I disconnect the node that is currently on secondary using drbdadm, make it primary, take an image with DD and then make it secondary again, reconnect and resynch. Actually very easy and no downtime. Rob -----Original Message----- From: xen-users-bounces@lists.xensource.com [mailto:xen-users-bounces@lists.xensource.com] On Behalf Of James Harper Sent: 19 November 2008 02:17 To: Paras pradhan; Xen Users Subject: RE: [Xen-users] Backup> hi all, > > What is the preferred method/tool to backup Xen guests? > > Xm save and DD seems to work but ''xm save'' stops the virtual machineand> DD is slow. > > Any better option? > > I am under CentOS/DRBD >I use Bacula and treat the VM''s like normal computers. Alternatively you could use LVM to create a snapshot and back that up, assuming you are using LVM in the first place. James _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users The SAQ Group Registered Office: 18 Chapel Street, Petersfield, Hampshire GU32 3DZ SEMTEC Limited Trading as SAQ is Registered in England & Wales Company Number: 06481952 http://www.saqnet.co.uk AS29219 SAQ Group Delivers high quality, honestly priced communication and I.T. services to UK Business. DSL : Domains : Email : Hosting : CoLo : Servers : Racks : Transit : Backups : Managed Networks : Remote Support. Find us in http://www.thebestof.co.uk/petersfield _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Tue, Nov 18, 2008 at 8:16 PM, James Harper <james.harper@bendigoit.com.au> wrote:> > hi all, > > > > What is the preferred method/tool to backup Xen guests? > > > > Xm save and DD seems to work but ''xm save'' stops the virtual machine > and > > DD is slow. > > > > Any better option? > > > > I am under CentOS/DRBD > > > > I use Bacula and treat the VM''s like normal computers. > > Alternatively you could use LVM to create a snapshot and back that up, > assuming you are using LVM in the first place. > > JamesThank you all for the reply. Here''s what I did: To backup: 1) Saved the virtual machines'' state using: xm save guest01 /guest01.save 2) lvcreate -s -L 2G -n guest01-snap /dev/vg/guest01-disk 3) Restored the VM xm restore /guest01.save 4) Used DD to create the image dd if=/dev/vg/guest01-snap of=/guest01.img 5) lvremove /dev/vg/guest01-snap To restore: 1) I turned off the VM (i don''t like this) xm shutdown guest01 2) Then run: dd if=/guest01.img of=/dev/vg/guest01-disk 3) Turn back the VM on -- My virtual machine is consuming 11GB of space. Now when i do DD while restoring it took a lot of time. --- 10737418240 bytes (11 GB) copied, 1189.42 seconds, 9.0 MB/s --- Is this normal? I don''t know if the process that I have used is fine or not. Need views on this. Thanks Paras. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
"Paras pradhan" <pradhanparas@gmail.com> writes:> Here''s what I did: > > To backup: > > 1) Saved the virtual machines'' state using: > > xm save guest01 /guest01.save > > 2) lvcreate -s -L 2G -n guest01-snap /dev/vg/guest01-disk > > 3) Restored the VM > > xm restore /guest01.save > > 4) Used DD to create the image > > dd if=/dev/vg/guest01-snap of=/guest01.img > > 5) lvremove /dev/vg/guest01-snap > > To restore: > > 1) I turned off the VM (i don''t like this) > > xm shutdown guest01 > > 2) Then run: > > dd if=/guest01.img of=/dev/vg/guest01-disk > > 3) Turn back the VM on > > -- > > My virtual machine is consuming 11GB of space. Now when i do DD while > restoring it took a lot of time. > > > --- > 10737418240 bytes (11 GB) copied, 1189.42 seconds, 9.0 MB/s > > --- > > > Is this normal?Impossible to tell without knowing a lots of details about your storage system.> I don''t know if the process that I have used is fine or not. Need > views on this.Looks OK, but be prepared that your filesystems will be unclean after restore. If instead of turning the VM on you did an xm restore again, then your filesystems would be OK, but some operations could be carried out again in the restored domain. -- Cheers, Feri. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi Paras, I''m not sure if your question was performance related but if your storage system is local then you should see about 50Mbytes/second on a single 7200RPM SATA disk or about 100Mbytes/sec for a single 15000Rpm SAS drive; assuming they have very little disk activity from other VMs. Raid 0 and Raid 5 arrays should be an order of magnitude faster. So speed wise that 9Mbytes/second looks too low. Rob -----Original Message----- From: xen-users-bounces@lists.xensource.com [mailto:xen-users-bounces@lists.xensource.com] On Behalf Of Ferenc Wagner Sent: 20 November 2008 13:41 To: Paras pradhan Cc: Xen Users Subject: [Xen-users] Re: Backup "Paras pradhan" <pradhanparas@gmail.com> writes:> Here''s what I did: > > To backup: > > 1) Saved the virtual machines'' state using: > > xm save guest01 /guest01.save > > 2) lvcreate -s -L 2G -n guest01-snap /dev/vg/guest01-disk > > 3) Restored the VM > > xm restore /guest01.save > > 4) Used DD to create the image > > dd if=/dev/vg/guest01-snap of=/guest01.img > > 5) lvremove /dev/vg/guest01-snap > > To restore: > > 1) I turned off the VM (i don''t like this) > > xm shutdown guest01 > > 2) Then run: > > dd if=/guest01.img of=/dev/vg/guest01-disk > > 3) Turn back the VM on > > -- > > My virtual machine is consuming 11GB of space. Now when i do DD while > restoring it took a lot of time. > > > --- > 10737418240 bytes (11 GB) copied, 1189.42 seconds, 9.0 MB/s > > --- > > > Is this normal?Impossible to tell without knowing a lots of details about your storage system.> I don''t know if the process that I have used is fine or not. Need > views on this.Looks OK, but be prepared that your filesystems will be unclean after restore. If instead of turning the VM on you did an xm restore again, then your filesystems would be OK, but some operations could be carried out again in the restored domain. -- Cheers, Feri. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users The SAQ Group Registered Office: 18 Chapel Street, Petersfield, Hampshire GU32 3DZ SEMTEC Limited Trading as SAQ is Registered in England & Wales Company Number: 06481952 http://www.saqnet.co.uk AS29219 SAQ Group Delivers high quality, honestly priced communication and I.T. services to UK Business. DSL : Domains : Email : Hosting : CoLo : Servers : Racks : Transit : Backups : Managed Networks : Remote Support. Find us in http://www.thebestof.co.uk/petersfield _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Thu, Nov 20, 2008 at 7:45 AM, Robert Dunkley <Robert@saq.co.uk> wrote:> Hi Paras, > > I''m not sure if your question was performance related but if your > storage system is local then you should see about 50Mbytes/second on a > single 7200RPM SATA disk or about 100Mbytes/sec for a single 15000Rpm > SAS drive; assuming they have very little disk activity from other VMs. > Raid 0 and Raid 5 arrays should be an order of magnitude faster. So > speed wise that 9Mbytes/second looks too low. > > Rob > > -----Original Message----- > From: xen-users-bounces@lists.xensource.com > [mailto:xen-users-bounces@lists.xensource.com] On Behalf Of Ferenc > Wagner > Sent: 20 November 2008 13:41 > To: Paras pradhan > Cc: Xen Users > Subject: [Xen-users] Re: Backup > > "Paras pradhan" <pradhanparas@gmail.com> writes: > > > Here''s what I did: > > > > To backup: > > > > 1) Saved the virtual machines'' state using: > > > > xm save guest01 /guest01.save > > > > 2) lvcreate -s -L 2G -n guest01-snap /dev/vg/guest01-disk > > > > 3) Restored the VM > > > > xm restore /guest01.save > > > > 4) Used DD to create the image > > > > dd if=/dev/vg/guest01-snap of=/guest01.img > > > > 5) lvremove /dev/vg/guest01-snap > > > > To restore: > > > > 1) I turned off the VM (i don''t like this) > > > > xm shutdown guest01 > > > > 2) Then run: > > > > dd if=/guest01.img of=/dev/vg/guest01-disk > > > > 3) Turn back the VM on > > > > -- > > > > My virtual machine is consuming 11GB of space. Now when i do DD while > > restoring it took a lot of time. > > > > > > --- > > 10737418240 bytes (11 GB) copied, 1189.42 seconds, 9.0 MB/s > > > > --- > > > > > > Is this normal? > > Impossible to tell without knowing a lots of details about your > storage system. > > > I don''t know if the process that I have used is fine or not. Need > > views on this. > > Looks OK, but be prepared that your filesystems will be unclean after > restore. If instead of turning the VM on you did an xm restore again, > then your filesystems would be OK, but some operations could be carried > out again in the restored domain. > -- > Cheers, > Feri. > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users > > The SAQ Group > > Registered Office: 18 Chapel Street, Petersfield, Hampshire GU32 3DZ > SEMTEC Limited Trading as SAQ is Registered in England & Wales > Company Number: 06481952 > > > > http://www.saqnet.co.uk AS29219 > > SAQ Group Delivers high quality, honestly priced communication and I.T. > services to UK Business. > > DSL : Domains : Email : Hosting : CoLo : Servers : Racks : Transit : > Backups : Managed Networks : Remote Support. > > Find us in http://www.thebestof.co.uk/petersfield > >As recommended by agent, I have tested/restored with bs=4096 and now i am getting around 35mb/s in my 7200 RPM SATA drive. It works for me but still it should be more than that I guess. Thanks Paras. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Thu, Nov 20, 2008 at 7:41 AM, Ferenc Wagner <wferi@niif.hu> wrote:> "Paras pradhan" <pradhanparas@gmail.com> writes: > > > Here''s what I did: > > > > To backup: > > > > 1) Saved the virtual machines'' state using: > > > > xm save guest01 /guest01.save > > > > 2) lvcreate -s -L 2G -n guest01-snap /dev/vg/guest01-disk > > > > 3) Restored the VM > > > > xm restore /guest01.save > > > > 4) Used DD to create the image > > > > dd if=/dev/vg/guest01-snap of=/guest01.img > > > > 5) lvremove /dev/vg/guest01-snap > > > > To restore: > > > > 1) I turned off the VM (i don''t like this) > > > > xm shutdown guest01 > > > > 2) Then run: > > > > dd if=/guest01.img of=/dev/vg/guest01-disk > > > > 3) Turn back the VM on > > > > -- > > > > My virtual machine is consuming 11GB of space. Now when i do DD while > > restoring it took a lot of time. > > > > > > --- > > 10737418240 bytes (11 GB) copied, 1189.42 seconds, 9.0 MB/s > > > > --- > > > > > > Is this normal? > > Impossible to tell without knowing a lots of details about your > storage system. > > > I don''t know if the process that I have used is fine or not. Need > > views on this. > > Looks OK, but be prepared that your filesystems will be unclean after > restore. If instead of turning the VM on you did an xm restore again, > then your filesystems would be OK, but some operations could be carried > out again in the restored domain. > -- > Cheers, > Feri. >xm restore looks to be fine when i restored. Thanks Paras. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users