Re: LXC: autostart feature does set all interfaces to state up.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 07/05/2013 04:45 AM, Richard Weinberger wrote:
> Hi,
> 
> Am 03.07.2013 12:04, schrieb Gao feng:
>> Hi,
>> On 07/01/2013 03:45 PM, Richard Weinberger wrote:
>>> Hi!
>>>
>>> If you have multiple LXC containers with networking and the autostart feature enabled libvirtd fails to
>>> up some veth interfaces on the host side.
>>>
>>> Most of the time only the first veth device is in state up, all others are down.
>>>
>>> Reproducing is easy.
>>> 1. Define a few containers (5 in my case)
>>> 2. Run "virsh autostart ..." on each one.
>>> 3. stop/start libvirtd
>>>
>>> You'll observe that all containers are running, but "ip a" will report on the host
>>> side that not all veth devices are up and are not usable within the containers.
>>>
>>> This is not userns related, just retested with libvirt of today.
>>
>> I can not reproduce this problem on my test bed...
> 
> Strange.
> 
>> maybe you should wait some seconds for the starting of these containers.
> 
> Please see the attached shell script. Using it I'm able to trigger the issue on all of
> my test machines.
> run.sh creates six very minimal containers and enables autostart. Then it kills and restarts libvirtd.
> After the script is done you'll see that only one or two veth devices are up.
> 
> On the over hand, if I start them manually using a command like this one:
> for cfg in a b c d e f ; do /opt/libvirt/bin/virsh -c lxc:/// start test-$cfg ; done
> All veths are always up.
> 


I still can not reproduce even use your script.

[root@Donkey-I5 Desktop]# ./run.sh
Domain test-a defined from container_a.conf

Domain test-a marked as autostarted

Domain test-b defined from container_b.conf

Domain test-b marked as autostarted

Domain test-c defined from container_c.conf

Domain test-c marked as autostarted

Domain test-d defined from container_d.conf

Domain test-d marked as autostarted

Domain test-e defined from container_e.conf

Domain test-e marked as autostarted

Domain test-f defined from container_f.conf

Domain test-f marked as autostarted

2013-07-05 01:26:47.155+0000: 27163: info : libvirt version: 1.1.0
2013-07-05 01:26:47.155+0000: 27163: debug : virLogParseOutputs:1334 : outputs=1:file:/home/gaofeng/libvirtd.log
waiting a bit....
167: veth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master virbr0 state UP qlen 1000
169: veth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master virbr0 state UP qlen 1000
171: veth2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master virbr0 state UP qlen 1000
173: veth3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master virbr0 state UP qlen 1000
175: veth4: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master virbr0 state UP qlen 1000
177: veth5: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master virbr0 state UP qlen 1000


Can you post your libvirt debug log?

Thanks

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]