Re: [libvirt-users] [Bug 1325687] network type="ethernet" not supported with LXC

Hi Team I'm trying to launch LXC VM with libvirt 1.2.12 having commit *22cff52a2b8e06c913b1f97767e5d3**90fb17fc3b *with below XML configuration.. <domain type="lxc"> <uuid>64c48da2-e318-4085-8b88-c980aab4de34</uuid> <name>test</name> <memory>524288</memory> <vcpu>1</vcpu> <os> <type machine="virt">exe</type> <cmdline>root=/dev/ram0 rw console=ttyAMA0 rootwait earlyprintk</cmdline> <init>/bin/sh</init> </os> <clock offset="utc"/> <devices> <file/> <interface type='ethernet'> <mac address='02:74:ff:9d:52:f5'/> <script path=''/> <target dev='tap74f2-f5'/> </interface> <console type="pty"/> </devices> </domain> I'm getting following errors while launching LXC VM using above XML file.. virsh -c lxc: define lxc.xml virsh -c lxc: start test error: Failed to start domain test error: internal error: guest failed to start: /usr/lib/libvirt/libvirt_lxc: option '--veth' requires an argument syntax: /usr/lib/libvirt/libvirt_lxc [OPTIONS] Options -b, --background -n NAME, --name NAME -c FD, --console FD -v VETH, --veth VETH -s FD, --handshakefd FD -S NAME, --security NAME -h, --help Unknown failure in libvirt_lxc startup Please help me regarding this. --Thanks Abhishek Jain On Mon, Apr 11, 2016 at 3:35 AM, <bugzilla@redhat.com> wrote:
https://bugzilla.redhat.com/show_bug.cgi?id=1325687
Cole Robinson <crobinso@redhat.com> changed:
What |Removed |Added
---------------------------------------------------------------------------- Status|NEW |CLOSED CC| |crobinso@redhat.com Resolution|--- |CURRENTRELEASE Last Closed| |2016-04-10 18:05:06
--- Comment #1 from Cole Robinson <crobinso@redhat.com> --- ethernet support was actually enabled for lxc via this commit:
commit 22cff52a2b8e06c913b1f97767e5d390fb17fc3b Author: Anirban Chakraborty <abchak@juniper.net> Date: Tue Nov 18 15:55:48 2014 -0800
network: Add network bandwidth support to ethernet interfaces
Which looks like libvirt v1.2.10 or v1.2.11
-- You are receiving this mail because: You are on the CC list for the bug. You reported the bug.

On 04/11/2016 09:24 AM, abhishek jain wrote:
Hi Team
I'm trying to launch LXC VM with libvirt 1.2.12 having commit *22cff52a2b8e06c913b1f97767e5d3**90fb17fc3b *with below XML configuration..
<domain type="lxc"> <uuid>64c48da2-e318-4085-8b88-c980aab4de34</uuid> <name>test</name> <memory>524288</memory> <vcpu>1</vcpu> <os> <type machine="virt">exe</type> <cmdline>root=/dev/ram0 rw console=ttyAMA0 rootwait earlyprintk</cmdline> <init>/bin/sh</init> </os> <clock offset="utc"/> <devices> <file/> <interface type='ethernet'> <mac address='02:74:ff:9d:52:f5'/> <script path=''/> <target dev='tap74f2-f5'/> </interface> <console type="pty"/> </devices> </domain>
I'm getting following errors while launching LXC VM using above XML file..
virsh -c lxc: define lxc.xml virsh -c lxc: start test
error: Failed to start domain test error: internal error: guest failed to start: /usr/lib/libvirt/libvirt_lxc: option '--veth' requires an argument syntax: /usr/lib/libvirt/libvirt_lxc [OPTIONS] Options -b, --background -n NAME, --name NAME -c FD, --console FD -v VETH, --veth VETH -s FD, --handshakefd FD -S NAME, --security NAME -h, --help Unknown failure in libvirt_lxc startup
Please help me regarding this.
Hmm indeed, it seems like that commit inadvertently dropped the error condition for type=ethernet... from reading the original thread, I think the reporter was only testing with qemu. It's probably not much work to wire up type=ethernet for LXC, but someone else will need to do it. I'll send a patch to make the error explicit again. Please reopen your RFC bug Thanks, Cole
--Thanks Abhishek Jain
On Mon, Apr 11, 2016 at 3:35 AM, <bugzilla@redhat.com <mailto:bugzilla@redhat.com>> wrote:
https://bugzilla.redhat.com/show_bug.cgi?id=1325687
Cole Robinson <crobinso@redhat.com <mailto:crobinso@redhat.com>> changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |CLOSED CC| |crobinso@redhat.com <mailto:crobinso@redhat.com> Resolution|--- |CURRENTRELEASE Last Closed| |2016-04-10 18:05:06
--- Comment #1 from Cole Robinson <crobinso@redhat.com <mailto:crobinso@redhat.com>> --- ethernet support was actually enabled for lxc via this commit:
commit 22cff52a2b8e06c913b1f97767e5d390fb17fc3b Author: Anirban Chakraborty <abchak@juniper.net <mailto:abchak@juniper.net>> Date: Tue Nov 18 15:55:48 2014 -0800
network: Add network bandwidth support to ethernet interfaces
Which looks like libvirt v1.2.10 or v1.2.11
-- You are receiving this mail because: You are on the CC list for the bug. You reported the bug.

Thanks Cole. I need to use network type="ethernet" with LXC instead of Qemu. I have reopened my bug. On Mon, Apr 11, 2016 at 8:25 PM, Cole Robinson <crobinso@redhat.com> wrote:
On 04/11/2016 09:24 AM, abhishek jain wrote:
Hi Team
I'm trying to launch LXC VM with libvirt 1.2.12 having commit *22cff52a2b8e06c913b1f97767e5d3**90fb17fc3b *with below XML configuration..
<domain type="lxc"> <uuid>64c48da2-e318-4085-8b88-c980aab4de34</uuid> <name>test</name> <memory>524288</memory> <vcpu>1</vcpu> <os> <type machine="virt">exe</type> <cmdline>root=/dev/ram0 rw console=ttyAMA0 rootwait earlyprintk</cmdline> <init>/bin/sh</init> </os> <clock offset="utc"/> <devices> <file/> <interface type='ethernet'> <mac address='02:74:ff:9d:52:f5'/> <script path=''/> <target dev='tap74f2-f5'/> </interface> <console type="pty"/> </devices> </domain>
I'm getting following errors while launching LXC VM using above XML file..
virsh -c lxc: define lxc.xml virsh -c lxc: start test
error: Failed to start domain test error: internal error: guest failed to start: /usr/lib/libvirt/libvirt_lxc: option '--veth' requires an argument syntax: /usr/lib/libvirt/libvirt_lxc [OPTIONS] Options -b, --background -n NAME, --name NAME -c FD, --console FD -v VETH, --veth VETH -s FD, --handshakefd FD -S NAME, --security NAME -h, --help Unknown failure in libvirt_lxc startup
Please help me regarding this.
Hmm indeed, it seems like that commit inadvertently dropped the error condition for type=ethernet... from reading the original thread, I think the reporter was only testing with qemu.
It's probably not much work to wire up type=ethernet for LXC, but someone else will need to do it. I'll send a patch to make the error explicit again. Please reopen your RFC bug
Thanks, Cole
--Thanks Abhishek Jain
On Mon, Apr 11, 2016 at 3:35 AM, <bugzilla@redhat.com <mailto:bugzilla@redhat.com>> wrote:
https://bugzilla.redhat.com/show_bug.cgi?id=1325687
Cole Robinson <crobinso@redhat.com <mailto:crobinso@redhat.com>>
changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |CLOSED CC| |crobinso@redhat.com <mailto:crobinso@redhat.com> Resolution|--- |CURRENTRELEASE Last Closed| |2016-04-10 18:05:06
--- Comment #1 from Cole Robinson <crobinso@redhat.com <mailto:crobinso@redhat.com>> --- ethernet support was actually enabled for lxc via this commit:
commit 22cff52a2b8e06c913b1f97767e5d390fb17fc3b Author: Anirban Chakraborty <abchak@juniper.net <mailto:
abchak@juniper.net>>
Date: Tue Nov 18 15:55:48 2014 -0800
network: Add network bandwidth support to ethernet interfaces
Which looks like libvirt v1.2.10 or v1.2.11
-- You are receiving this mail because: You are on the CC list for the bug. You reported the bug.

Hi Cole I tested the LXC VM with libvirt 1.2.12 after applying the patch http://www.redhat.com/archives/libvir-list/2016-April/msg00505.html I'm now getting following errors.. virsh -c lxc: start test error: Failed to start domain test error: internal error: Unsupported network type ethernet I'm using the below XML file for launching LXC VM.. <domain type="lxc"> <uuid>64c48da2-e318-4085-8b88-c980aab4de34</uuid> <name>test</name> <memory>524288</memory> <vcpu>1</vcpu> <os> <type machine="virt">exe</type> <cmdline>root=/dev/ram0 rw console=ttyAMA0 rootwait earlyprintk</cmdline> <init>/bin/sh</init> </os> <clock offset="utc"/> <devices> <file/> <interface type='ethernet'> <mac address='02:74:ff:9d:52:f5'/> <script path=''/> <target dev='tap74f2-f5'/> </interface> <console type="pty"/> </devices> </domain> Thanks Abhishek Jain On Tue, Apr 12, 2016 at 12:05 AM, abhishek jain <ashujain9727@gmail.com> wrote:
Thanks Cole.
I need to use network type="ethernet" with LXC instead of Qemu. I have reopened my bug.
On Mon, Apr 11, 2016 at 8:25 PM, Cole Robinson <crobinso@redhat.com> wrote:
On 04/11/2016 09:24 AM, abhishek jain wrote:
Hi Team
I'm trying to launch LXC VM with libvirt 1.2.12 having commit *22cff52a2b8e06c913b1f97767e5d3**90fb17fc3b *with below XML configuration..
<domain type="lxc"> <uuid>64c48da2-e318-4085-8b88-c980aab4de34</uuid> <name>test</name> <memory>524288</memory> <vcpu>1</vcpu> <os> <type machine="virt">exe</type> <cmdline>root=/dev/ram0 rw console=ttyAMA0 rootwait earlyprintk</cmdline> <init>/bin/sh</init> </os> <clock offset="utc"/> <devices> <file/> <interface type='ethernet'> <mac address='02:74:ff:9d:52:f5'/> <script path=''/> <target dev='tap74f2-f5'/> </interface> <console type="pty"/> </devices> </domain>
I'm getting following errors while launching LXC VM using above XML file..
virsh -c lxc: define lxc.xml virsh -c lxc: start test
error: Failed to start domain test error: internal error: guest failed to start: /usr/lib/libvirt/libvirt_lxc: option '--veth' requires an argument syntax: /usr/lib/libvirt/libvirt_lxc [OPTIONS] Options -b, --background -n NAME, --name NAME -c FD, --console FD -v VETH, --veth VETH -s FD, --handshakefd FD -S NAME, --security NAME -h, --help Unknown failure in libvirt_lxc startup
Please help me regarding this.
Hmm indeed, it seems like that commit inadvertently dropped the error condition for type=ethernet... from reading the original thread, I think the reporter was only testing with qemu.
It's probably not much work to wire up type=ethernet for LXC, but someone else will need to do it. I'll send a patch to make the error explicit again. Please reopen your RFC bug
Thanks, Cole
--Thanks Abhishek Jain
On Mon, Apr 11, 2016 at 3:35 AM, <bugzilla@redhat.com <mailto:bugzilla@redhat.com>> wrote:
https://bugzilla.redhat.com/show_bug.cgi?id=1325687
Cole Robinson <crobinso@redhat.com <mailto:crobinso@redhat.com>>
changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |CLOSED CC| |
crobinso@redhat.com
<mailto:crobinso@redhat.com> Resolution|--- |CURRENTRELEASE Last Closed| |2016-04-10 18:05:06
--- Comment #1 from Cole Robinson <crobinso@redhat.com <mailto:crobinso@redhat.com>> --- ethernet support was actually enabled for lxc via this commit:
commit 22cff52a2b8e06c913b1f97767e5d390fb17fc3b Author: Anirban Chakraborty <abchak@juniper.net <mailto:
abchak@juniper.net>>
Date: Tue Nov 18 15:55:48 2014 -0800
network: Add network bandwidth support to ethernet interfaces
Which looks like libvirt v1.2.10 or v1.2.11
-- You are receiving this mail because: You are on the CC list for the bug. You reported the bug.

On 04/12/2016 09:12 AM, abhishek jain wrote:
Hi Cole
I tested the LXC VM with libvirt 1.2.12 after applying the patch
http://www.redhat.com/archives/libvir-list/2016-April/msg00505.html
I'm now getting following errors..
virsh -c lxc: start test error: Failed to start domain test error: internal error: Unsupported network type ethernet
Yes, that was the point of the patch, to make the error explicit. As stated in the other email, it will take more work to make type=ethernet actually functional with LXC. - Cole

Hi Cole Thanks. Please let us know when the support for network-type="ethernet" is enabled in libvirt.
participants (2)
-
abhishek jain
-
Cole Robinson