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 special and needs to be treated differently? > > > > > >
... > > More detail: Typically one starts out with an empty QCoW2 file > created via qemu-img. Once Qemu starts and initializes the > libtpms-based TPM, it tries to read existing state from that QCoW2 > file. Since there is no state stored in the QCoW2, the TPM will > start initializing itself to an initial 'blank' state. So it looks like the problem is you access the file when guest isn't running. Delaying the initialization until the guest actually starts running will solve the problem in a way that is more consistent with other qemu devices. -- MST