Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-08 Thread Michael S. Tsirkin
On Wed, Sep 07, 2011 at 08:31:45PM -0400, Stefan Berger wrote: > On 09/07/2011 02:49 PM, Michael S. Tsirkin wrote: > >On Wed, Sep 07, 2011 at 12:08:22PM -0400, Stefan Berger wrote: > >>On 09/07/2011 11:16 AM, Michael S. Tsirkin wrote: > >>> > >>>So it's a bug in the code then? > >>> > >> From what

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Stefan Berger
On 09/07/2011 02:49 PM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 12:08:22PM -0400, Stefan Berger wrote: On 09/07/2011 11:16 AM, Michael S. Tsirkin wrote: So it's a bug in the code then? From what I saw, yes. Migration is not complete until the passwords had been entered. Though the

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Michael S. Tsirkin
On Wed, Sep 07, 2011 at 12:08:22PM -0400, Stefan Berger wrote: > On 09/07/2011 11:16 AM, Michael S. Tsirkin wrote: > >On Wed, Sep 07, 2011 at 11:06:42AM -0400, Stefan Berger wrote: > >>On 09/07/2011 10:35 AM, Michael S. Tsirkin wrote: > >>>On Wed, Sep 07, 2011 at 10:25:08AM -0400, Stefan Berger wro

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Stefan Berger
On 09/07/2011 11:16 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 11:06:42AM -0400, Stefan Berger wrote: On 09/07/2011 10:35 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 10:25:08AM -0400, Stefan Berger wrote: On 09/07/2011 10:10 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Michael S. Tsirkin
On Wed, Sep 07, 2011 at 11:06:42AM -0400, Stefan Berger wrote: > On 09/07/2011 10:35 AM, Michael S. Tsirkin wrote: > >On Wed, Sep 07, 2011 at 10:25:08AM -0400, Stefan Berger wrote: > >>On 09/07/2011 10:10 AM, Michael S. Tsirkin wrote: > >>>On Wed, Sep 07, 2011 at 09:56:52AM -0400, Stefan Berger wro

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Stefan Berger
On 09/07/2011 10:35 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 10:25:08AM -0400, Stefan Berger wrote: On 09/07/2011 10:10 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 09:56:52AM -0400, Stefan Berger wrote: On 09/07/2011 09:16 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Michael S. Tsirkin
On Wed, Sep 07, 2011 at 10:25:08AM -0400, Stefan Berger wrote: > On 09/07/2011 10:10 AM, Michael S. Tsirkin wrote: > >On Wed, Sep 07, 2011 at 09:56:52AM -0400, Stefan Berger wrote: > >>On 09/07/2011 09:16 AM, Michael S. Tsirkin wrote: > >>>On Wed, Sep 07, 2011 at 09:06:05AM -0400, Stefan Berger wro

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Stefan Berger
On 09/07/2011 10:10 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 09:56:52AM -0400, Stefan Berger wrote: On 09/07/2011 09:16 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 09:06:05AM -0400, Stefan Berger wrote: First: There are two ways to encrypt the data. One comes with the Q

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Michael S. Tsirkin
On Wed, Sep 07, 2011 at 09:56:52AM -0400, Stefan Berger wrote: > On 09/07/2011 09:16 AM, Michael S. Tsirkin wrote: > >On Wed, Sep 07, 2011 at 09:06:05AM -0400, Stefan Berger wrote: > First: There are two ways to encrypt the data. > > One comes with the QCoW2 type of image and it comes

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Stefan Berger
On 09/07/2011 09:16 AM, Michael S. Tsirkin wrote: On Wed, Sep 07, 2011 at 09:06:05AM -0400, Stefan Berger wrote: First: There are two ways to encrypt the data. One comes with the QCoW2 type of image and it comes for free. Set the encryption flag when creating the QCoW2 file and one has to provi

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Michael S. Tsirkin
On Wed, Sep 07, 2011 at 09:06:05AM -0400, Stefan Berger wrote: > >>First: There are two ways to encrypt the data. > >> > >>One comes with the QCoW2 type of image and it comes for free. Set > >>the encryption flag when creating the QCoW2 file and one has to > >>provide a key to access the QCoW2. I f

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Stefan Berger
On 09/07/2011 07:18 AM, Michael S. Tsirkin wrote: On Tue, Sep 06, 2011 at 07:55:48PM -0400, Stefan Berger wrote: On 09/04/2011 03:32 PM, Michael S. Tsirkin wrote: On Thu, Sep 01, 2011 at 09:53:40PM -0400, Stefan Berger wrote: Generally, what all other devices do is perform validation as the la

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-07 Thread Michael S. Tsirkin
On Tue, Sep 06, 2011 at 07:55:48PM -0400, Stefan Berger wrote: > On 09/04/2011 03:32 PM, Michael S. Tsirkin wrote: > >On Thu, Sep 01, 2011 at 09:53:40PM -0400, Stefan Berger wrote: > >>>Generally, what all other devices do is perform validation > >>>as the last step in migration when device state >

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-06 Thread Stefan Berger
On 09/04/2011 03:32 PM, Michael S. Tsirkin wrote: On Thu, Sep 01, 2011 at 09:53:40PM -0400, Stefan Berger wrote: Generally, what all other devices do is perform validation as the last step in migration when device state is restored. On failure, management can decide what to do: retry migration o

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-04 Thread Michael S. Tsirkin
On Thu, Sep 01, 2011 at 09:53:40PM -0400, Stefan Berger wrote: > >Generally, what all other devices do is perform validation > >as the last step in migration when device state > >is restored. On failure, management can decide what to do: > >retry migration or restart on source. > > > >Why is TPM sp

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-01 Thread Stefan Berger
On 09/01/2011 01:32 PM, Michael S. Tsirkin wrote: On Wed, Aug 31, 2011 at 10:35:59AM -0400, Stefan Berger wrote: This patch introduces file locking via fcntl() for the block layer so that concurrent access to files shared by 2 Qemu instances, for example via NFS, can be serialized. This feature

Re: [Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-09-01 Thread Michael S. Tsirkin
On Wed, Aug 31, 2011 at 10:35:59AM -0400, Stefan Berger wrote: > This patch introduces file locking via fcntl() for the block layer so that > concurrent access to files shared by 2 Qemu instances, for example via NFS, > can be serialized. This feature is useful primarily during initial phases of >

[Qemu-devel] [PATCH V8 08/14] Introduce file lock for the block layer

2011-08-31 Thread Stefan Berger
This patch introduces file locking via fcntl() for the block layer so that concurrent access to files shared by 2 Qemu instances, for example via NFS, can be serialized. This feature is useful primarily during initial phases of VM migration where the target machine's TIS driver validates the block