Bug 833110

Summary: Kernel Crash after unloading the bonding moudle
Product: Red Hat Enterprise Linux 6 Reporter: Talat <talatb>
Component: kernelAssignee: Veaceslav Falico <vfalico>
Status: CLOSED DUPLICATE QA Contact: Red Hat Kernel QE team <kernel-qe>
Severity: urgent Docs Contact:
Priority: unspecified    
Version: 6.3CC: mishu, nhorman, peterm, redhat-bugzilla, talatb, tis, vlad
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-06-24 13:04:46 EDT Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
Attachments:
Description Flags
Screenshot none

Description Talat 2012-06-18 11:15:47 EDT
Created attachment 592688 [details]
Screenshot

Description of problem:
The machine get Kernel Crash after creating an bond of two interfaces, creating vlan on the bond and unload the bonding moudle.
  
Version-Release number of selected component (if applicable):2.6.32-274.el6.x86_64 


How reproducible:
This failure is 100% reproducible.


Steps to Reproduce:
1. Create an balance- alb bond.
2. Create a tagged vlan interface on said bond
3. unload the bonding moudle "modprobe -r bonding"
  
Actual results:
Kernel Panic

Expected results:
1. Delete all the vlans that on the bond.
2. Delete the bond.
3. detach the slave interfaces  

Additional info:
Comment 2 Michael Chapman 2012-06-22 20:46:38 EDT
I have encountered this bug as well. The panic is "kernel BUG at net/8021q/vlan.c:796".

Reverting the kernel patches:

- [net] bonding: assign slaves their own vlan_groups (Neil Horman) [804232]
- [net] vlan: Add helper functions to manage vlans on bonds and slaves (Neil Horman) [804232]

appears to fix the problem.
Comment 3 Neil Horman 2012-06-24 13:04:46 EDT
This should be fixed in kernel-2.6.32-280.el6 forward

*** This bug has been marked as a duplicate of bug 823822 ***
Comment 4 Michael Chapman 2012-06-26 22:39:49 EDT
I just tested the patch for this that was posted in bug 834764 comment 16 (patch URL: https://bugzilla.redhat.com/attachment.cgi?id=594190). It doesn't appear to fix the problem: I still hit a kernel bug at net/8021q/vlan.c:796.

Looking at what the patch does to bond_del_vlans_from_slave, it looks like sgrp->nr_vlans is not decremented if the slave doesn't support NETIF_F_HW_VLAN_FILTER, even though it may have been incremented in bond_vlan_rx_add_vid. I think this means it's still possible for the vlan group to leak, leading to the crash when the 8021q module is unloaded.
Comment 5 Neil Horman 2012-06-27 06:58:39 EDT
yup, looks like you're right, please open a new bz to track that and I'll square it away.  Thanks!