Ask Your Question
0

No log or console for instance in libvirt and Xen

asked 2015-04-06 00:51:56 -0500

jilingshu gravatar image

updated 2015-04-07 21:55:36 -0500

Hi all, I have configured my OpenStack Juno installation with official instructions on Ubuntu. The compute node is Xen with libvirt as suggested in a http://wiki.xenproject.org/wiki/Xen_via_libvirt_for_OpenStack_juno (blog post)of http://xen.org. I can successfully launch a instance, 'xl show' confirmed the domain is running. However, in Horizon, 'Log' tab always said

Unable to get log for instance "xxxxx".

And I get following error message from nova log:

2015-04-06 03:05:42.564 1730 TRACE oslo.messaging.rpc.dispatcher     output = self.driver.get_console_output(context, instance)
2015-04-06 03:05:42.564 1730 TRACE oslo.messaging.rpc.dispatcher   File "/usr/lib/python2.7/dist-packages/nova/virt/libvirt/driver.py", line 2705, in get_console_output
2015-04-06 03:05:42.564 1730 TRACE oslo.messaging.rpc.dispatcher     data = self._flush_libvirt_console(pty)
2015-04-06 03:05:42.564 1730 TRACE oslo.messaging.rpc.dispatcher UnboundLocalError: local variable 'pty' referenced before assignment
2015-04-06 03:05:42.564 1730 TRACE oslo.messaging.rpc.dispatcher 
2015-04-06 03:05:42.575 1730 ERROR oslo.messaging._drivers.common [req-e84c58ba-24a7-4730-bc90-7928b40c3a42 ] Returning exception local variable 'pty' referenced before assignment to caller

The console, however, shows no error message in log, but it always says:

Guest has not initialized the display (yet).

Any suggestion?

EDIT: It turns out that the problem is in my libvirt. libvirt from Ubuntu utopic (14.10) is 1.2.8. This version is too old and includes a bug which prevent it fill in the path for pty when dumping xml from the instance. Upgrading it to the latest version (1.2.12) solve this problem. However, the console problem remains. It keep saying "Guest has not initialized the display (yet)."

edit retag flag offensive close merge delete

Comments

Exactly, which instructions at Xen.org you've been followed ?

dbaxps gravatar imagedbaxps ( 2015-04-06 10:14:25 -0500 )edit

@dbaxps I added the link in my post.

jilingshu gravatar imagejilingshu ( 2015-04-06 16:17:22 -0500 )edit

Regarding Libvirt version there is notice @Xen.org pointing to 1.2.9 as minimal acceptable.

dbaxps gravatar imagedbaxps ( 2015-04-07 22:26:33 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2015-04-06 16:49:58 -0500

dbaxps gravatar image

updated 2015-04-06 23:56:54 -0500

Here is an answer for devstack machine

ubuntu@ubuntu-svc:/opt/stack$ nova list
+--------------------------------------+------------------+--------+------------+-------------+------------------------------------+
| ID                                   | Name             | Status | Task State | Power State | Networks                           |
+--------------------------------------+------------------+--------+------------+-------------+------------------------------------+
| d5ba082d-3f9f-4e05-8e9c-c9b6cc480830 | UbuntuVVDevstack | ACTIVE | -          | Running     | private=10.254.1.4, 192.168.12.152 |
| 56840d0f-3084-452c-b798-0b4fdf714df8 | VF21Devstack     | ACTIVE | -          | Running     | private=10.254.1.3, 192.168.12.151 |
+--------------------------------------+------------------+--------+------------+-------------+------------------------------------+
ubuntu@ubuntu-svc:/opt/stack$ cat ./data/nova/instances/56840d0f-3084-452c-b798-0b4fdf714df8/console.log

However, on normal RDO Juno installation it won't be a problem to find :-

../../nova/instances/56840d0f-3084-452c-b798-0b4fdf714df8/console.log

I did it a couple of times, just cannot remind an exact path which will have last folders name ( including server-id) exactly as above. Name of file is console.log. Of course I mean KVM Hypervisor, just check the same for Xen.

Yes , RDO Juno on F21

/var/lib/nova/instances/7c23628a-60ad-4c45-a749-a7e40f0a0392/console.log
edit flag offensive delete link more

Comments

The log problem has been solved. Please my updated post. Thank you.

jilingshu gravatar imagejilingshu ( 2015-04-07 21:55:57 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2015-04-06 00:51:56 -0500

Seen: 58,341 times

Last updated: Apr 07 '15