To set up a bridge named br0 (part 1)
- apt install bridge-utils
- brctl addbr br0
- brctl addif eth0 br0
- brctl addif eth1 br0
To set up a bridge named br0 (part 2)
- ip link add br0 type bridge
- ip link set eth0 master br0′
- ip link set eth1 master br0
To set up a bridge without bridging and name (part 3)
- tc qdisc add dev eth0 ingress
- tc qdisc add dev eth1 ingress
- tc filter add dev eth0 parent ffff: protocol all u32 match u32 0 0 action mirred egress mirror dev eth1
- tc filter add dev eth1 parent ffff: protocol all u32 match u32 0 0 action mirred egress mirror dev eth0