bug disabling guest interface
Hi all
We have recently encountered a bug in xen causing guest interface to be disabled in certain conditions:
- dom0 with this patch https://patchwork.kernel.org/patch/2164311/
- guest kernel built in way that makes guest MAX_SKB_FRAGS larger than MAX_SKB_FRAGS on dom0
For example dom0 kernel from here
http://au1.mirror.crc.id.au/repo/el6/x86_64/
Linux blade-b.maemo.org 3.7.9-1.el6xen.x86_64 #1 SMP Mon Feb 18 14:46:35 EST 2013 x86_64 x86_64 x86_64 GNU/Linux
And domU
Linux stage.maemo.org 2.6.32-33-server #72-Ubuntu SMP Fri Jul 29 21:21:55 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux
In this example dom0 MAX_SKB_FRAGS is at 17 while MAX_SKB_FRAGS at domU is 18
I did find a post making a comment about it
http://lists.xen.org/archives/html/xen-devel/2012-11/msg01072.html
Quoted 2 lines
This highlights a couple of issues, the main one is that implicitly including
MAX_SKB_FRAGSin the PV net protocol is just madness.
More details from host:
xenbr1: port 8(vif51.0) entered forwarding state vif vif-51-0 vif51.0: Too many frags
vif vif-51-0 vif51.0: fatal error; disabling device
xenbr1: port 8(vif51.0) entered disabled state
[root@blade-b ~]# xm info
host : blade-b.maemo.org
release : 3.7.9-1.el6xen.x86_64
version : #1 SMP Mon Feb 18 14:46:35 EST 2013
machine : x86_64nr_cpus : 12nr_nodes : 1cores_per_socket : 6threads_per_core : 2cpu_mhz : 2000hw_caps :
bfebfbff:2c100800:00000000:00003f40:17bee3ff:00000000:00000001:00000000virt_caps : hvm hvm_directiototal_memory : 32735free_memory : 1076free_cpus : 0xen_major : 4xen_minor : 2xen_extra : .1xen_caps : xen-3.0-x86_64 xen-3.0-x86_32p hvm-3.0-x86_32
hvm-3.0-x86_32p hvm-3.0-x86_64xen_scheduler : creditxen_pagesize : 4096platform_params : virt_start=0xffff800000000000xen_changeset : unavailablexen_commandline : dom0_mem=1024M loglvl=all guest_loglvl=all
cpuidle=0 cpufreq=nonecc_compiler : gcc (GCC) 4.4.6 20120305 (Red Hat 4.4.6-4)cc_compile_by : mockbuildcc_compile_domain : crc.id.aucc_compile_date : Sat Feb 16 19:16:38 EST 2013xend_config_format : 4
Quoted 7 lines · Jacek Milewicz
Hi all
We have recently encountered a bug in xen causing guest interface to be disabled in certain conditions:
- dom0 with this patch https://patchwork.kernel.org/patch/2164311/
- guest kernel built in way that makes guestMAX_SKB_FRAGSlarger thanMAX_SKB_FRAGSon dom0
I'm interested in knowing more information. Have you always been using MAX_SKB_FRAGS > default_value (16 or 17) for you DomUs?
If it is this case, you're likely to be hitting this error path all the time. It is just that XSA-39 chooses to shutdown vif if there is something wrong. So my further questions is, do you notice any performance problem in the case that netback silently drops your packets?
Wei.
Quoted 2 lines
I'm interested in knowing more information. Have you always been using
MAX_SKB_FRAGS>default_value(16 or 17) for you DomUs?
18 used to be default value on older kernels (anything older than
https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/include/linux/skbuff.h?id=9d4dde5215779f4099730194ad30624fdba3d8b2 -
2011-12-23 21:51:18)
Quoted 6 lines
If it is this case, you're likely to be hitting this error path all the time. It is just
that XSA-39 chooses to shutdown vif if there is something wrong. So my further questions is, do you notice any performance problem in the case that
netback silently drops your packets?
Basically what happened in our case is VMs were migrated to new host with new kernel, before that dom0 used to run kernel with MAX_SKB_FRAGS==18 so it was same for both dom0 and domU.
New host has kernel with XSA-39 fixes and smaller MAX_SKB_FRAGS (17), and that's when we encountered that bug, we've never tried kernel with smaller MAX_SKB_FRAGS but without XSA_39 fix.
Quoted 14 lines · Jacek Milewicz
Quoted 2 lines
I'm interested in knowing more information. Have you always been using
MAX_SKB_FRAGS>default_value(16 or 17) for you DomUs?18 used to be default value on older kernels (anything older than
https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/commit/include/linux/skbuff.h?id=9d4dde5215779f4099730194ad30624fdba3d8b2 -2011-12-23 21:51:18)Quoted 6 lines
If it is this case, you're likely to be hitting this error path all the time. It is just
that XSA-39 chooses to shutdown vif if there is something wrong. So my further questions is, do you notice any performance problem in the case that
netback silently drops your packets?
Quoted 6 lines
Basically what happened in our case is VMs were migrated to new host with new kernel, before that dom0 used to run kernel with MAX_SKB_FRAGS==18 so it was same for both dom0 and domU.
New host has kernel with XSA-39 fixes and smallerMAX_SKB_FRAGS(17), and that's when we encountered that bug, we've never tried kernel with smallerMAX_SKB_FRAGSbut withoutXSA_39fix.
Sorry for my intrusion of this thread. I would like to highlight that this also affect guests/domUs running Windows Server 2003 in HVM and the logs are similar with the OP:
kernel: vif vif-2-0 vifvm104.0: Too many frags
kernel: vif vif-2-0 vifvm104.0: fatal error; disabling device
kernel: eth0: port 4(vifvm104.0) entered disabled state
Thanks.
Kindest regards,
Giam Teck Choon