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

Re: [Xen-users] xl create unable to connect to console, 4.4.1-rc1 build from source



On 07/24/2014 03:13 AM, Ian Campbell wrote:
On Wed, 2014-07-23 at 13:36 -0600, David A. Van Arnem wrote:
Hello,

I am trying to create a PV guest (Ubuntu 14.04) on a host with Xen
v4.4.1-rc1, built from source (checked out stable-4.4 branch) on a
machine running Fedora 20.  Xl is unable to connect to the console of
the guest, giving the error : libxl: error:
libxl_exec.c:118:libxl_report_child_exitstatus: console child [0]
exited with error status 1.  I have verified that xenconsoled is
running.  I followed the instructions here to create my config file:
https://help.ubuntu.com/community/Xen
Please can you provide the actual cfg file, just in case...
Here's the command and output I used to create the PV guest, with the
error underlined.  It is curious to me that the elf parser is seeing
linux 2.6 and xen-3.0 when I would assume Ubuntu 14.04 contains newer
versions of both...
Modern Xen is still ABI compatible with Xen (to guests), which is why
you see that there.

The reason for Linux 2.6 is similar, but less meaningful...

# xl -vvv create /etc/xen/xen-domU-0.cfg -c
Can you try putting -c before the filename. I don't think it matters but
I'm not 100% sure...

libxl: debug: libxl_event.c:1591:libxl__ao_complete: ao 0x256e490: complete, 
rc=0
libxl: debug: libxl_event.c:1155:egc_run_callbacks: ao 0x256e490: progress 
report: callback aop=0x256ff30
libxl: debug: libxl_event.c:1563:libxl__ao__destroy: ao 0x256e490: destroy
Unable to attach console
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: console child [0] 
exited with error status 1
This seems to imply that libxl_primary_console_exec returned, which it
shouldn't do.

Can you strace the xl create?

My wild guess is that it's not finding the xenconsole binary in
$prefix/lib/xen/bin or that it is not executable for some reason. strace
would confirm what it thinks it is doing.

You'll want to use -fff to follow forks and you might want create -F to
keep it in the foreground for ease of tracing (otherwise xl will
daemonise to monitor the domain). So somethign like
         strace -fff xl create -c -F <cfg>

Perhaps "xl console <dom>" also fails? It might be easier to strace that
since it does far less.

Ian.


Just as a followup (with solution!) --

I ran into the problem again on a subsequent build of Xen, and you were correct in your assumption that xl was looking for xenconsole in the wrong place, which was easily determined with strace. Xl was looking for it in /usr/lib/xen/bin, but it had installed to /usr/lib64/xen/bin (I used --libdir=/usr/lib64 as a ./configure parameter this time, last time I used no parameters so I assume it was placed in something like /usr/local/lib/bin). Creating a symbolic link /usr/lib/xen/bin/xenconsole -> /usr/lib64/xen/bin/xenconsole solved the problem.

I also ran into a similar problem with pygrub; the python tools were installed to /usr/local/lib64/python2.7/site-packages... even with --libdir=/usr/lib64. When I tried to start up the guest using pygrub, I got an error about it not finding the bootloader and the reason is as documented here: http://wiki.xenproject.org/wiki/Compiling_Xen_From_Source#Python_Prefix_and_Module_Layout. I couldn't determine a fix for Fedora with configure options, so I created symbolic links in /usr/lib64/python2.7/site-packages to point to the /usr/local/lib64/python2.7/site-packages versions and was able to start up the guest.

Even though my problem is solved for now, is there a way to install the Python tools directly to the libdir? Is there a way to tell xl to look for xenconsole in the libdir? Appending the locations to PATH didn't seem to fix the problem, and only symbolic links worked.


_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.