Vagrant causing XCP-ng VM (with Nested Virtualization ON) to abruptly reboot
Am experiencing a weird behavior and wondering if anybody experienced something similar or has some hints/guidance about it.
On a server running XCP-ng, VMs (running Ubuntu 18.04) with nested virtualization ON are rebooting abruptly when Vagrant (2.2.14) is trying to bring up a libvirt/kvm “sub-guest” machine (NO issue if the machine uses QEMU rather… although too slow for the purpose!). The last line logged by vagrant before the XCP-ng VM restarts itself are something like:
==> vagrant-5-project-2-concurrent-0-job-681: Creating shared folders metadata... ==> vagrant-5-project-2-concurrent-0-job-681: Starting domain. ==> vagrant-5-project-2-concurrent-0-job-681: Error when updating domain settings: undefined method 'strip' for nil:NilClass ==> vagrant-5-project-2-concurrent-0-job-681: Waiting for domain to get an IP address... ==> vagrant-5-project-2-concurrent-0-job-681: Waiting for SSH to become available...
The VM just blows up and it reboots. It was working fine until some time ago. It looks like an update of XCP-ng might have broken it?
Anyone experiencing similar problems?
Is anyone able to provide some advice?
Nested code in Xen is not ultra-stable (it's also sensitive to your hardware). So I'm not really surprised about this...
@olivierlambert sad to know! Most of all as it was working beautifully until very recently...
Thanks for the feedback though.
Do you have suggestion for CI using Vagrant to spin up machines hosted on XCP-ng? Is Vagrant xen-server plug-in considered robust enough? (Not judging from its latest version number... 0.0.6... double-O is license to kill, right?!)
That's a good question. If I could, I would do a Vagrant plugin for XO (instead of XCP-ng).
I know @ddelnano started to work on a Packer plugin, but I don't know how hard it is to write a Vagrant plugin.
I never used Vagrant myself, but anyone interested to work on that is very welcome!
@olivierlambert was thinking about this specifically...
It looks like it did not receive that much love recently, but it should work...
@itnok yea it appears the project uses the plugin api for Vagrant 1.x which may not work with Vagrant 2.x (the latest version) I'm not sure if the plugin api has changed significantly since I haven't written any plugins myself.
@itnok I would prefer a Vagrant plugin for XO, not XCP-ng.
@olivierlambert probably dumb question... but where can I find a clear complete overall document listing all endpoints for the Xen Orchestra API?
Tried the Vagrant plug-in mentioned above but I do agree it would be better to have a version of it targeting XO API rather than directly Xen/XCP-ng XAPI...
@itnok Good question Take a look there: https://xen-orchestra.com/docs/architecture.html#api and here for the list of all endpoints: https://xen-orchestra.com/docs/architecture.html#xo-cli-cli