Re: [libvirt-users] Associating a statefile with an image

[re-adding the list] On 08/02/2011 03:18 PM, sethuraman subbiah wrote:
Libvirt shoots for monthly releases; the current schedule is feature freeze this weekend, then a release around the first of August.
The new API will allow you do to either:
virsh dumpxml --inactive --dom> file.xml edit file.xml virsh save dom dom.save --xml file.xml virsh restore file.save
or:
virsh dumpxml --inactive --dom> file.xml
Using --inactive here only works if you haven't made any changes to the inactive configuration that differs from the currently running domain. I'd amend this step to 'virsh dumpxml dom > file.xml' for both of these examples.
virsh save dom dom.save edit file.xml virsh restore file.save --xml file.xml
These two examples will be supported in 0.9.4. Additionally, I added: virsh save-file-dumpxml dom.save > file.xml virsh save-file-define dom.save file.xml virsh save-file-edit dom.save to do things inline, and to make it so you don't have to remember to 'virsh dumpxml dom' prior to 'virsh save'.
I found that the latest libvirt (libvirt 0.9.4) is out.
That's amazing, considering it hasn't been released yet :) Maybe you are referring to 0.9.4-rc2 instead? But at any rate, the official 0.9.4 will probably be released tomorrow with even more bug fixes above 0.9.4-rc2.
I tried installing in my Centos 5.6 machine. After a successful installation, when I start virsh , I get :
virsh: /lib/libvirt.so.0: version `LIBVIRT_PRIVATE_0.8.2' not found (required by virsh)
Is it possible to get the latest version of libvirt 0.9.4 work on Centos 5.6 ? Thanks a lot for your help.
Yes, it should be possible, although I haven't tried it myself on centos (but I have tried on RHEL 5.7). Are you sure you installed your self-built libvirt.so correctly? We take great pains to ensure that libvirt.so is backwards compatible (no symbols are ever removed). -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org

On Aug 2, 2011, at 5:29 PM, Eric Blake wrote:
[re-adding the list]
On 08/02/2011 03:18 PM, sethuraman subbiah wrote:
Libvirt shoots for monthly releases; the current schedule is feature freeze this weekend, then a release around the first of August.
The new API will allow you do to either:
virsh dumpxml --inactive --dom> file.xml edit file.xml virsh save dom dom.save --xml file.xml virsh restore file.save
or:
virsh dumpxml --inactive --dom> file.xml
Using --inactive here only works if you haven't made any changes to the inactive configuration that differs from the currently running domain. I'd amend this step to 'virsh dumpxml dom > file.xml' for both of these examples.
virsh save dom dom.save edit file.xml virsh restore file.save --xml file.xml
These two examples will be supported in 0.9.4. Additionally, I added:
virsh save-file-dumpxml dom.save > file.xml virsh save-file-define dom.save file.xml virsh save-file-edit dom.save
to do things inline, and to make it so you don't have to remember to 'virsh dumpxml dom' prior to 'virsh save'.
I found that the latest libvirt (libvirt 0.9.4) is out.
That's amazing, considering it hasn't been released yet :) Maybe you are referring to 0.9.4-rc2 instead? But at any rate, the official 0.9.4 will probably be released tomorrow with even more bug fixes above 0.9.4-rc2.
Yeah , I was referring to 0.9.4-rc2 :) I will install the official libvirt 0.9.4 tomorrow .
I tried installing in my Centos 5.6 machine. After a successful installation, when I start virsh , I get :
virsh: /lib/libvirt.so.0: version `LIBVIRT_PRIVATE_0.8.2' not found (required by virsh)
Is it possible to get the latest version of libvirt 0.9.4 work on Centos 5.6 ? Thanks a lot for your help.
Yes, it should be possible, although I haven't tried it myself on centos (but I have tried on RHEL 5.7). Are you sure you installed your self-built libvirt.so correctly? We take great pains to ensure that libvirt.so is backwards compatible (no symbols are ever removed).
I think so, I installed libvirt 0.9.4-rc2 on Centos 6 and it worked fine. I tried installing in Centos 5.6 (It had libvirt already installed through yum) . I did yum remove libvirt. Then I did ./configure --prefix = / , make , make install , ldconfig. When I enter virsh after finishing these steps, I get that error. I am not sure whether I am committing a mistake in-between. Please correct me if I am wrong. Thank you.
-- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org

On 2 August 2011 18:28, sethuraman subbiah <sethusubbiah@gmail.com> wrote:
On Aug 2, 2011, at 5:29 PM, Eric Blake wrote:
[re-adding the list]
On 08/02/2011 03:18 PM, sethuraman subbiah wrote:
Libvirt shoots for monthly releases; the current schedule is feature freeze this weekend, then a release around the first of August.
The new API will allow you do to either:
virsh dumpxml --inactive --dom> file.xml edit file.xml virsh save dom dom.save --xml file.xml virsh restore file.save
or:
virsh dumpxml --inactive --dom> file.xml
Using --inactive here only works if you haven't made any changes to the inactive configuration that differs from the currently running domain. I'd amend this step to 'virsh dumpxml dom > file.xml' for both of these examples.
virsh save dom dom.save edit file.xml virsh restore file.save --xml file.xml
These two examples will be supported in 0.9.4. Additionally, I added:
virsh save-file-dumpxml dom.save > file.xml virsh save-file-define dom.save file.xml virsh save-file-edit dom.save
to do things inline, and to make it so you don't have to remember to 'virsh dumpxml dom' prior to 'virsh save'.
I tried changing the disk image and it works fine. But if I try to change the mac address , I get error: unsupported configuration. My aim was to perform cloning and change the mac of the cloned image and also doing some changes inside the vm to make sure it obtains a new ip. Is there a possibility to get this working with the current API ?
I found that the latest libvirt (libvirt 0.9.4) is out.
That's amazing, considering it hasn't been released yet :) Maybe you are referring to 0.9.4-rc2 instead? But at any rate, the official 0.9.4 will probably be released tomorrow with even more bug fixes above 0.9.4-rc2.
I tried installing in my Centos 5.6 machine. After a successful installation, when I start virsh , I get :
virsh: /lib/libvirt.so.0: version `LIBVIRT_PRIVATE_0.8.2' not found (required by virsh)
Is it possible to get the latest version of libvirt 0.9.4 work on Centos 5.6 ? Thanks a lot for your help.
Yes, it should be possible, although I haven't tried it myself on centos (but I have tried on RHEL 5.7). Are you sure you installed your self-built
Yeah , I was referring to 0.9.4-rc2 :) I will install the official libvirt 0.9.4 tomorrow . libvirt.so correctly? We take great pains to ensure that libvirt.so is backwards compatible (no symbols are ever removed).
I think so, I installed libvirt 0.9.4-rc2 on Centos 6 and it worked fine. I tried installing in Centos 5.6 (It had libvirt already installed through yum) . I did yum remove libvirt. Then I did ./configure --prefix = / , make , make install , ldconfig. When I enter virsh after finishing these steps, I get that error. I am not sure whether I am committing a mistake in-between. Please correct me if I am wrong. Thank you.
-- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org
Thanks a lot for your time. - Regards, Sethuraman Subbiah Graduate Student - NC state University M.S in Computer Science

On 08/02/2011 07:06 PM, sethuraman subbiah wrote:
I tried changing the disk image and it works fine. But if I try to change the mac address , I get error: unsupported configuration.
That's correct - changing the MAC address would be a guest-visible change, with possibly fatal consequences to a guest (your hardware doesn't change MAC addresses on the fly, so why should your virtual hardware allow it?).
My aim was to perform cloning and change the mac of the cloned image and also doing some changes inside the vm to make sure it obtains a new ip. Is there a possibility to get this working with the current API ?
Cloning is not a trivial operation. There is no support for cloning a running machine; it is only safe to clone offline disk images, at which point, you _can_ modify MAC addresses for the clone, since a guest booting with a new MAC address is no different than swapping out hardware while your machine was offline. Virt-manager is able to do cloning, and it involves multiple libvirt API calls; perhaps studying that source will give you some better ideas. It is unlikely that libvirt will ever be able to support cloning in a single API call; rather it will continue to support enough API to be used in sequence to do a clone. Likewise, cloning a live machine (even one whose state was saved by 'virsh save' or 'virsh snapshot') is unlikely to ever be possible. -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org
participants (2)
-
Eric Blake
-
sethuraman subbiah