Robb Walker
2014-Jul-10 21:06 UTC
[libvirt-users] starting lxcs from within a vm using libvirt
my goal for testing/simulations is to be able to run a vm on my desktop and within that vm run linux containers currently I can start an ubuntu trusty vm using libvirt as my broker to qemu or qemu-system-x86_64 directly and start a saucy-based lxc using lxc-tools. I invoke lxc-start -n name -f configfile and within a few seconds I'm logged into my saucy based lxc. I can't start the lxc thru libvirt i.e. virsh -c lxc:/// start domain Again, if I try to use libvirt to "install" and start the lxc from within the vm, no joy. Results below:>>>root@vullbvrt69:~# virt-install --connect lxc:/// -n vulslxc01 -r 512 --filesystem /qemu_lxc/ss_140521/,/ --serial pty --serial pty Starting install... Creating domain... | 0 B 00:00 error: failed to get domain '22542' error: Domain not found: No domain with matching name '22542' Domain creation completed. You can restart your domain by running: root@vullbvrt69:~# virsh -c lxc:/// list --all Id Name State ---------------------------------------------------- - vulslxc01 shut off root@vullbvrt69:~# virsh -c lxc:/// start vulslxc01 Domain vulslxc01 started root@vullbvrt69:~# virsh -c lxc:/// console vulslxc01 --devname serial1 error: The domain is not running root@vullbvrt69:~# virsh -c lxc:/// list --all Id Name State ---------------------------------------------------- - vulslxc01 shut off>>>My physical desktop is running precise 12.04.4 ----qemu-kvm 1.0+noroms-0ubuntu14.15 ----libvirt-bin 0.9.8-2ubuntu17.19 ----lxc 0.7.5-3ubuntu69 This physical machine launches the trusty vm from which in turn I'm trying to run lxcs via libvirt Trusty vm ----libvirt-bin 1.2.2-0ubuntu13.1.1 ----lxc 1.0.4-0ubuntu0.1 The saucy lxc was not created using lxc templates just a normal minbase debootstrap. I have run virt-install with -d. Nothing obvious jumps out except the above Domain not found virsh -c lxc:/// -d4 -l debug.out start domain_name dumps nothing into debug.out thx in advance for any and all help and apolgies in advance if I've dropped critical info to help sort this out This e-mail and any attachments may contain information that is confidential and proprietary and otherwise protected from disclosure. If you are not the intended recipient of this e-mail, do not read, duplicate or redistribute it by any means. Please immediately delete it and any attachments and notify the sender that you have received it in error. Unintended recipients are prohibited from taking action on the basis of information in this e-mail or any attachments. The DRW Companies make no representations that this e-mail or any attachments are free of computer viruses or other defects.
Robb Walker
2014-Jul-15 14:29 UTC
Re: [libvirt-users] starting lxcs from within a vm using libvirt
Just another ping, and please let me know if this is not the proper format to re-ask my submitted question, but anyone else having any joy on running lxcs via libvirt launched from within a vm? ________________________________________ From: libvirt-users-bounces@redhat.com <libvirt-users-bounces@redhat.com> on behalf of Robb Walker <rwalker@DRWHoldings.com> Sent: Thursday, July 10, 2014 4:06 PM To: libvirt-users@redhat.com Subject: [libvirt-users] starting lxcs from within a vm using libvirt my goal for testing/simulations is to be able to run a vm on my desktop and within that vm run linux containers currently I can start an ubuntu trusty vm using libvirt as my broker to qemu or qemu-system-x86_64 directly and start a saucy-based lxc using lxc-tools. I invoke lxc-start -n name -f configfile and within a few seconds I'm logged into my saucy based lxc. I can't start the lxc thru libvirt i.e. virsh -c lxc:/// start domain Again, if I try to use libvirt to "install" and start the lxc from within the vm, no joy. Results below:>>>root@vullbvrt69:~# virt-install --connect lxc:/// -n vulslxc01 -r 512 --filesystem /qemu_lxc/ss_140521/,/ --serial pty --serial pty Starting install... Creating domain... | 0 B 00:00 error: failed to get domain '22542' error: Domain not found: No domain with matching name '22542' Domain creation completed. You can restart your domain by running: root@vullbvrt69:~# virsh -c lxc:/// list --all Id Name State ---------------------------------------------------- - vulslxc01 shut off root@vullbvrt69:~# virsh -c lxc:/// start vulslxc01 Domain vulslxc01 started root@vullbvrt69:~# virsh -c lxc:/// console vulslxc01 --devname serial1 error: The domain is not running root@vullbvrt69:~# virsh -c lxc:/// list --all Id Name State ---------------------------------------------------- - vulslxc01 shut off>>>My physical desktop is running precise 12.04.4 ----qemu-kvm 1.0+noroms-0ubuntu14.15 ----libvirt-bin 0.9.8-2ubuntu17.19 ----lxc 0.7.5-3ubuntu69 This physical machine launches the trusty vm from which in turn I'm trying to run lxcs via libvirt Trusty vm ----libvirt-bin 1.2.2-0ubuntu13.1.1 ----lxc 1.0.4-0ubuntu0.1 The saucy lxc was not created using lxc templates just a normal minbase debootstrap. I have run virt-install with -d. Nothing obvious jumps out except the above Domain not found virsh -c lxc:/// -d4 -l debug.out start domain_name dumps nothing into debug.out thx in advance for any and all help and apolgies in advance if I've dropped critical info to help sort this out This e-mail and any attachments may contain information that is confidential and proprietary and otherwise protected from disclosure. If you are not the intended recipient of this e-mail, do not read, duplicate or redistribute it by any means. Please immediately delete it and any attachments and notify the sender that you have received it in error. Unintended recipients are prohibited from taking action on the basis of information in this e-mail or any attachments. The DRW Companies make no representations that this e-mail or any attachments are free of computer viruses or other defects. _______________________________________________ libvirt-users mailing list libvirt-users@redhat.com https://www.redhat.com/mailman/listinfo/libvirt-users This e-mail and any attachments may contain information that is confidential and proprietary and otherwise protected from disclosure. If you are not the intended recipient of this e-mail, do not read, duplicate or redistribute it by any means. Please immediately delete it and any attachments and notify the sender that you have received it in error. Unintended recipients are prohibited from taking action on the basis of information in this e-mail or any attachments. The DRW Companies make no representations that this e-mail or any attachments are free of computer viruses or other defects.
Eric Blake
2014-Jul-15 16:47 UTC
Re: [libvirt-users] starting lxcs from within a vm using libvirt
On 07/15/2014 08:29 AM, Robb Walker wrote:> Just another ping, and please let me know if this is not the proper format to re-ask my submitted question, but anyone else having any joy on running lxcs via libvirt launched from within a vm?This is the right forum, even if no one has answered so far. Running lxc guests inside an L1 kvm guest should be possible (I haven't tried it myself, but doesn't seem like there should be any major obstacles).> > root@vullbvrt69:~# virt-install --connect lxc:/// -n vulslxc01 -r 512 --filesystem /qemu_lxc/ss_140521/,/ --serial pty --serial pty > > Starting install... > Creating domain... | 0 B 00:00 > error: failed to get domain '22542' > error: Domain not found: No domain with matching name '22542'Not sure where that error is coming from, since you named your domain vulslxc01 rather than 22542. I'm not much of an Ubuntu user myself, so I don't know how well lxc guests fare on that build; you may get faster response if you open a Launchpad ticket?> > This e-mail and any attachments may contain information that is confidential and proprietaryThis disclaimer is unenforceable on publicly archived lists; you may be better off sending from a personal account rather than from an employer's account that slams on bogus legalese. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org