Re: [libvirt] Libvirt Xen daemon interaction in Red Hat Enterprise with virtualization

Thanks a lot for the reply. I checked the setting in my config file and they look correct as specified by the webpage. I am able to connect to the unix socket but my login to xend is failing. What I am looking for is the exact function call that is made by libvirt to connect to xen daemon. i.e. the function that makes libvirt send out xml RPC message for xend to read. session.login_with_password() is not supported by xenAPI version being used in Red Hat. Please help me with the substitute of this method in Red Hat. Thanks Vaibhav
On Wed, Aug 20, 2008 at 10:18 AM, Daniel P. Berrange <berrange@redhat.com>wrote:
On Wed, Aug 20, 2008 at 10:15:49AM -0700, vaibhav chugh wrote:
Hi,
I am new to libvirt and I am trying to figure out that how libvert connects to Xend in Red Hat Enterprise with virtualization. I read a few posts but was not able to find this out.
The eariler versions of Xen were using xen_session_login_with_password() function call to connect to Xen daemon but I am not able to find anything similar to this in libvirt.
Libvirt talks to XenD using its UNIX socket, and SEXPR interface. This page gives a quick list of config settings you need in XenD to make it work with libvirt:
http://libvirt.org/drvxen.html
Daniel -- |: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :| |: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ <http://search.cpan.org/%7Edanberr/> :| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
-- Vaibhav Chugh

On Wed, Aug 20, 2008 at 03:34:38PM -0700, vaibhav chugh wrote:
What I am looking for is the exact function call that is made by libvirt to connect to xen daemon. i.e. the function that makes libvirt send out xml RPC message for xend to read.
see src/xend_internal.[ch] code in the source of libvirt.
session.login_with_password() is not supported by xenAPI version being used in Red Hat. Please help me with the substitute of this method in Red Hat.
Very simple, you have the source, take a debugger and see how libvirt connects. If you don't want to spend the effort, use libvirt directly, it was designed explicitely for people like you to not have to mess with the internals of Xen, it's complex, it's hard, sometimes inefficient, and tend to changes between release. The code available from libvirt is the best we have to offer, read it, learn it, and use it ! And please don't post the same request many time, you will get less help if you try to proceed that way. Daniel -- Red Hat Virtualization group http://redhat.com/virtualization/ Daniel Veillard | virtualization library http://libvirt.org/ veillard@redhat.com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/ http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/

On Wed, Aug 20, 2008 at 03:34:38PM -0700, vaibhav chugh wrote:
Thanks a lot for the reply. I checked the setting in my config file and they look correct as specified by the webpage. I am able to connect to the unix socket but my login to xend is failing.
Urm, there is no 'login' process with the SEXPR RPC mechanism libvirt uses, so I'm not exactly sure what's failing. Could you proivide the actual error messages you get when using libvirt with Xen ?
What I am looking for is the exact function call that is made by libvirt to connect to xen daemon. i.e. the function that makes libvirt send out xml RPC message for xend to read.
session.login_with_password() is not supported by xenAPI version being used in Red Hat. Please help me with the substitute of this method in Red Hat.
libvirt does not use Xen-API. We use the SEXPR RPC mechanism. As such we never call login_with_password() Daniel -- |: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :| |: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|

Thanks Mr. Berrange & Mr.Veillard for your replies, I was trying to connect to Xend directly without going through libvirt so was curious to know changes that have been made by Red Hat on the Xen Daemon end to support libvirt. I read the source code of libvirt last night and figured out there is a function xenDaemonOpen() is being used to do the work I was looking for and there is no password checking being done. I will try to figure out stuff about SEXPR RPC to get my stuff working. I am sorry for the multiple post thing, it happened because I had posted the first email from a different email address which was not registered on the list serv. Thanks again Vaibhav On Thu, Aug 21, 2008 at 1:12 AM, Daniel P. Berrange <berrange@redhat.com>wrote:
Thanks a lot for the reply. I checked the setting in my config file and
On Wed, Aug 20, 2008 at 03:34:38PM -0700, vaibhav chugh wrote: they
look correct as specified by the webpage. I am able to connect to the unix socket but my login to xend is failing.
Urm, there is no 'login' process with the SEXPR RPC mechanism libvirt uses, so I'm not exactly sure what's failing. Could you proivide the actual error messages you get when using libvirt with Xen ?
What I am looking for is the exact function call that is made by libvirt to connect to xen daemon. i.e. the function that makes libvirt send out xml RPC message for xend to read.
session.login_with_password() is not supported by xenAPI version being used in Red Hat. Please help me with the substitute of this method in Red Hat.
libvirt does not use Xen-API. We use the SEXPR RPC mechanism. As such we never call login_with_password()
Daniel -- |: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/:| |: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org:| |: http://autobuild.org -o- http://search.cpan.org/~danberr/<http://search.cpan.org/%7Edanberr/>:| |: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|
-- Vaibhav Chugh
participants (4)
-
Daniel P. Berrange
-
Daniel Veillard
-
vaibhav chugh
-
vaibhav chugh