I am trying to connect to the virtualbox hypervisor through libvirt java binding.
I
am on Ubuntu 10.04 and I have installed libvirt-0.85,
libvirt-java-0.4.6 and virtualbox-ose-dkms. I have configured libvirt
project and its java binding at Eclipse and the default test of the
binding runs properly. When I try to run a simple test in java with the
connection:
conn = new Connect("vbox:///session", false)
I get the following exception: "exception caught:org.libvirt.
LibvirtException: Failed to start the nwfilter driver: Is the daemon running ?"
If I try to do the same thing, but instead of using the java biding
I use virsh, it works. I am able to connect and start the virtual
machine successfully, although none of the nwfilter commands work in
virsh.
(The nwfilter-list command shows this error: Failed to list network
filters. This function is not supported by the connection driver:
virConnectNumOfNWFilters)
If I run the same java test using the Test hypervisor connection, things work properly.
I don't know if I have to install or configure something else in
order to get the nwfilter working or if virtualbox doesn't provide
support for it, and if it doesn't provide, how can I get rid of this
exception and use virtualbox virtual machine connection through java
binding ?
My objective is being able to use libvirt library commands in a
software (in java) which uses virtualization to run jobs in different
machines, but without the connection to the hypervisor I can't do
anything.
I apologize if this question has been already
answered. I have tried hard to get the answers for it looking at forums
and also in the discussions of this list, but I couldn't.
What am I missing?
Thanks!
--
Tarciso Braz de Oliveira Filho
Graduando em Ciência da Computação
LSD - Laboratório de Sistemas Distribuídos
UFCG
2011