Subject: Re: How to hairpin two Ethernet interfaces together (L2 hub/repeater mode)?

From: Jamal Hadi Salim <[email-masked]>
Date: Mon, 25 Feb 2013 14:16:53 -0500

Look at tc action redirect. Add it to ingress of eth0 to match 
everything and send out on eth1.

cheers,
jamal

On 13-02-22 07:10 PM, Petri Gynther wrote:
> Hi netdev:
>
> I'd like to hairpin two Ethernet interfaces together (e.g. eth0 and
> eth1) so that any frame received on eth0 is forwarded as-is to eth1
> and vice versa.
>
> Does Linux networking code support this? I've looked at the bridging
> code, but it doesn't seem to do this (at least trivially).
> Specifically, when eth0 and eth1 are added to bridge, unicast frames
> destined to eth0 (or eth1) MAC address end up to the bridge interface
> for local consumption, rather than being flooded to other ports on the
> bridge.
>
> Any trivial solutions to this? Can Linux bridge be configured in L2
> hub/repeater mode so that it simply floods every Rx frame to all other
> ports of the bridge?
> --
> To unsubscribe from this list: send the line "unsubscribe netdev" in
> the body of a message to [email-masked]
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>