Bug 851874

Summary: networking halts when mirred target device disappears
Product: Red Hat Enterprise Linux 6 Reporter: Dan Kenigsberg <danken>
Component: kernelAssignee: Red Hat Kernel Manager <kernel-mgr>
Status: CLOSED DUPLICATE QA Contact: Red Hat Kernel QE team <kernel-qe>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 6.3CC: gcheresh, jasowang, lpeer, mavital
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: network
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-08-27 11:27:04 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Dan Kenigsberg 2012-08-26 19:36:50 UTC
Description of problem:
Host is configured with eth0 connected to a bridge, the latter carrying an IP address. tc ingress rules on the bridge mirror all IP traffic to the tap device associated with a vNIC of qemu-kvm guest.

When qemu dies, the tap device is removed, and host connectivity is lost.

On 08/15/2012 09:25 AM, Jason Wang wrote:
> Unfortunately, current kernel would drop packet when the mirred device
> is removed. It depends on the management to do the correct configuration
> to make things work I think. Vdsm or other mgmt should take care of the
> filter configuration. Maybe we can change the behavior but I'm not sure
> whether or not it would break anything.

Version-Release number of selected component (if applicable):
2.6.32-279.5.2.el6.x86_64

How reproducible:
Ask Genadi for exact probability.

Steps to Reproduce:
- brctl addbr ovirtmgmt
- brctl addif ovirtmgmt eth0
- ifconfig ovirtmgmt host.ip.add.ress
- start qemu with a tap device called vnet0
- /sbin/tc qdisc add dev ovirtmgmt ingress
- /sbin/tc filter add dev ovirtmgmt parent ffff: protocol ip u32 match u8 0 0 action mirred egress mirror dev vnet0
- /sbin/tc qdisc add dev ovirtmgmt parent root prio
- /sbin/tc qdisc show dev ovirtmgmt
- /sbin/tc filter add dev ovirtmgmt parent <prio_qdisc_id>: protocol ip u32 match u8 0 0 action mirred egress mirror dev vnet0

traffic is now mirred into the VM.

- kill the VM (may happen due to qemu bugs)

Actual results:
- host looses connectivity

Expected results:
- host continues to see incoming traffic. Filter to a no-longer-existing device is ignored, not blocking packets.