Bug 576796 - virNetworkIsActive() and virNetworkIsPersistent() don't work with Xen
Summary: virNetworkIsActive() and virNetworkIsPersistent() don't work with Xen
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libvirt
Version: unspecified
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Daniel Veillard
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-03-25 09:06 UTC by Philipp Hahn
Modified: 2011-03-17 14:33 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-03-17 14:33:41 UTC


Attachments (Terms of Use)
Script to test virNetworkIsActive(). (8.07 KB, text/plain)
2010-03-25 09:06 UTC, Philipp Hahn
no flags Details

Description Philipp Hahn 2010-03-25 09:06:42 UTC
Created attachment 402503 [details]
Script to test virNetworkIsActive().

Description of problem:
When I trie to invoke virNetworkIsActive() or virNetworkIsPersistent() on a "xen:///" connection, I get a segmentation fault.
I tracked this down to "src/remote/remote_driver.c#remoteIO()" calling "virEventUpdateHandle()" while no Event loop was registered using "virEventRegisterImpl()".

So after adding an simple event loop implementation the crash is gone, but the calls don't return; they hang indefinitly.

Version-Release number of selected component (if applicable):
0.7.6, 0.7.7

How reproducible:
Every time.

Steps to Reproduce:
1. gcc -O0 -g -I/usr/include/libvirt -lvirt net.c
2. ./a.out xen+unix:///
3. ./a.out xen:///
  
Actual results:
Network default: 0
[HANG]

Expected results:
Network default: 0
Network default: 0

Additional info:
My simple event-loop implementation might contain errors, it's only slightly tested. At least it should be documanted, that for xen you must register an implementation. It would also probably be good to register a default implementation which just errors out.


Note You need to log in before you can comment on or make changes to this bug.