As n subject, is there a safe way to "hot" copy the VMs based on files. The best is using LVM Snapshot, I guess, but what if I can''t for other reason? Thanks, Jan _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Wed, Mar 18, 2009 at 4:41 AM, Jan Kalcic <jandot@googlemail.com> wrote:> As n subject, is there a safe way to "hot" copy the VMs based on files. The > best is using LVM Snapshot, I guess, but what if I can''t for other reason?to be safe, it has to be an ''atomic'' copy from the point of view of the guest. in fact, it has to be both atomic and synchronous with a copy of the machine state. if you don''t copy the machine state, it will look like a ''pulled cord'' shutdown. and if the copy isn''t atomic, it will look like a disk that passed a period of erratic behavior, some writes would be performed, some won''t. -- Javier _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Wed, Mar 18, 2009 at 4:41 PM, Jan Kalcic <jandot@googlemail.com> wrote:> As n subject, is there a safe way to "hot" copy the VMs based on files. The > best is using LVM Snapshot, I guess, but what if I can''t for other reason? >You could probably use "xm pause" or "xm save" first, and copy the VM files then. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Javier Guerra wrote:> On Wed, Mar 18, 2009 at 4:41 AM, Jan Kalcic <jandot@googlemail.com> wrote: > >> As n subject, is there a safe way to "hot" copy the VMs based on files. The >> best is using LVM Snapshot, I guess, but what if I can''t for other reason? >> > > to be safe, it has to be an ''atomic'' copy from the point of view of > the guest. in fact, it has to be both atomic and synchronous with a > copy of the machine state. > >What do you mean with "atomic" copy? Thanks, Jan _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Fajar A. Nugraha wrote:> On Wed, Mar 18, 2009 at 4:41 PM, Jan Kalcic <jandot@googlemail.com> wrote: > >> As n subject, is there a safe way to "hot" copy the VMs based on files. The >> best is using LVM Snapshot, I guess, but what if I can''t for other reason? >> >> > > You could probably use "xm pause" or "xm save" first, and copy the VM > files then. > >Yes, but in that case the VM is not available for the clients. I would looking for the best solution in terms of availability to backup a VM. Moreover, what does your experience suggest for the copy, just copy using the cp command or better dumping data with dd (like LVM in fact)? Thanks, Jan _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Wed, Mar 18, 2009 at 10:46 AM, Jan Kalcic <jandot@googlemail.com> wrote:> > What do you mean with "atomic" copy? >when talking about storage (or data access in general), an operation is ''atomic'' from some point of view if it''s ''indivisible''. that is, there wasn''t any point in time when it was ''halfway done''. LVM snapshots manage this, because it''s not a real copy (it''s more like a fork, but it works like a copy in most cases), and because it taps the main stream of storage operations. most other kinds of copy can''t be really atomic, that''s why Fajar tells you to suspend the guest while you do the copy. that way, even if there was a time when the copy was half-done, the guest wasn''t really there, so from it''s point of view, the copy was atomic. -- Javier _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Wed, Mar 18, 2009 at 10:50 AM, Jan Kalcic <jandot@googlemail.com> wrote:> Fajar A. Nugraha wrote: >> You could probably use "xm pause" or "xm save" first, and copy the VM >> files then. >> > > Yes, but in that case the VM is not available for the clients. I would > looking for the best solution in terms of availability to backup a VM.if you want backup, it''s better and more reliable to use a backup solution running on the guest. -- Javier _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Javier Guerra wrote:> On Wed, Mar 18, 2009 at 10:46 AM, Jan Kalcic <jandot@googlemail.com> wrote: > >> What do you mean with "atomic" copy? >> >> > > when talking about storage (or data access in general), an operation > is ''atomic'' from some point of view if it''s ''indivisible''. that is, > there wasn''t any point in time when it was ''halfway done''. > > LVM snapshots manage this, because it''s not a real copy (it''s more > like a fork, but it works like a copy in most cases), and because it > taps the main stream of storage operations. > > most other kinds of copy can''t be really atomic, that''s why Fajar > tells you to suspend the guest while you do the copy. that way, even > if there was a time when the copy was half-done, the guest wasn''t > really there, so from it''s point of view, the copy was atomic. > >I see. Really thanks, Jan _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users