New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
docker container fails to build examples #154
Comments
And after installing the missing python-libvirt: root@11f083760dfc:/home/elbe/elbe# apt-get install python-libvirt |
both problems are fixed by: e6cdc7e and will be in the next elbe-testing release. |
After rebuilding the docker container (v2.9.9) I got this:
We can see that libvirtd is not running. I used ssh to login to the container as user "elbe". Logging in as "root" does not work. |
seems that the user is not in the libvirt group |
I am using Ubuntu as the host OS. The libvirt apparmor profile needs to be disabled on the host as follows:
|
And here is the next problem:
User "elbe" does not have the correct permissions to use KVM. I resolved it by accessing the container directly using "docker exec -it <container id> bash". It seems to be working now. It would be nice to have a step by step documentation to build the examples using docker on an Ubuntu host machine. |
Unfortunately, there are even more problems when the virtual machine gets restarted:
|
The problem "libvirt: XML-RPC error : Failed to connect socket to '/var/run/libvirt/virtlogd-sock': No such file or directory
After that, the build still fails as follows:
|
I also resolved the above problem with:
But unfortunately, it's still not working yet:
I am using a corporate proxy. But http_proxy and https_proxy are set accordingly. It seems that the "ValidationError" in the last line is generated here: Line 204 in f971494
I guess that the proxy environment is not set up correctly within the vm. Access to http://ftp.de.debian.org//debian/dists/stretch/ works perfectly well from my browser on the host system. |
This is a proxy related issue which can be fixed by modifying the example .xml file. A <primary_proxy>myproxy:myproxy_port<primary_proxy> section must be put right below the <primary_proto><primary_proto> section. Putting all of my findings together, the build within a proxied environment on an Ubuntu host works as follows:
Please update your docs. The build should work on Ubuntu. Also note, that most companies do have a corporate proxy. There should be an extra section which explains all the necessary steps. |
Thanks for your efforts and good description! You're also welcome to send pathes against docs/quickstart.txt that is shown if you click on 'Start using elbe' on elbe-rfs.org. We will keep your findings in mind, because we're planning to providue ubuntu binary packages. Therefore i'd liko to keep this issue open. Because of http_proxy environment variables. I like the idea! Feel free to open a new issue for this, or send a patch to elbe-devel@linutronix.de |
The proxy related problems (2 and 6) are fixed by 8a39dd2. However, step 7 is still required! To build the image behind a corporate proxy use: To create/run the container behind a corporate proxy use: |
You must enable the hardware virtualization in the bios. The cpu-checker is very useful too. You must download this from the Ubuntu webpage ( packages.ubuntu.com ). I was able to setup it on Debian with: Then just write: INFO: /dev/kvm exists Then the Elbe can work too. |
Cannot reproduce. More info needed. Please reopen if nessesary. |
Within the docker container (branch release/v2.9.9), it is not possible to build the elbe examples:
root@11f083760dfc:/home/elbe/elbe# ./elbe initvm create ./examples/armhf-ti-beaglebone-black.xml
Traceback (most recent call last):
File "./elbe", line 62, in
mod = import(modname)
File "/home/elbe/elbe/elbepack/commands/initvm.py", line 25, in
from elbepack.initvmaction import InitVMAction, InitVMError
File "/home/elbe/elbe/elbepack/initvmaction.py", line 35, in
import libvirt
ImportError: No module named libvirt
The text was updated successfully, but these errors were encountered: