[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt-users] Questions related to the snapshot



Hi,

I faced two problems with the snapshot:

First issue, I can use the snapshot functions via the virsh correctly such as snapshot-list. And when I removed the snapshot XML files from /var/lib/libvirt/qemu/snapshot/**/, I don't see the snapshot of the Virtual Machine any more. That's correct. 
But after I copying  the XML files back, I can't see the the snapshot as well. Only if I restart my laptop can I see them. However, restarting is what I want to avoid. Because I wish I could utilize the functions in a server in the future.
Does anyone have ideas about this, Did I do something wrong or  it's a limitation. 
So far, I am using the qemu-img command to check the snapshot and do the revert without restarting my laptop. Because the snapshots are already embedded in the img file.

Second issue, I find if I create the XML file of snapshot by using getXMLDesc and output to a new file in python, there is a slightly different. But, the new XML file can't be recognized even if I restart my laptop. The new XML file miss the attribute <active>  as far as I can see, is it so important?
Here is one example:
The original XML in the default folder:
<domainsnapshot>
  <name>Ex</name>
  <description>Snapshot of OS updates</description>
  <state>running</state>
  <parent>
    <name>1342427860</name>
  </parent>
  <creationTime>1342428835</creationTime>
  <domain>
    <uuid>2c853de2-6bba-ad26-bf05-0045e5f1beb9</uuid>
  </domain>
  <active>0</active>
</domainsnapshot>

The new XML file I created:
<domainsnapshot>
  <name>Ex</name>
  <description>Snapshot of OS updates</description>
  <state>running</state>
  <parent>
    <name>1342427860</name>
  </parent>
  <creationTime>1342428835</creationTime>
  <domain>
    <uuid>2c853de2-6bba-ad26-bf05-0045e5f1beb9</uuid>
  </domain>
</domainsnapshot>

Thank you so much.

Best Regards

Tan

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]