[Bridge] Ethernet Bridging.

Johnnie alan johnniealan at gmail.com
Thu May 28 01:28:49 PDT 2009


Hi all ,

I saw your posts on the net, I need one help from you.

I am creating a bridge br0 for eth0 and tap0 ( virtual ). The bridge will
actually receives the message and routes it to ethernet devices connected.

I was able to route the ethernet frames from tap0 to the outer world via the
bridge. But while receiving the response, all the frames with TCP is routed
to the eth0 device. The network knows only the MAC address of eth0. So while
receiving the ehternet frames, the destination MAC is that of eth0.

I used ebtables to translate the MAC address of the incomming packet using
the Brouting table and nat table . It works fine, but still the ethernet
frame goes to the eth0 device. I am puzzled to see this behaviour.
 Code:
ebtables -t broute -A BROUTING -i br0  -p ipv4 --ip-dst 10.66.67.247   -j
ACCEPT
ebtables -t broute -A BROUTING -i br0   -p ipv4 --ip-dst 10.66.67.247  -j
ACCEPT ebtables -t nat -A PREROUTING -i eth0 -p ipv4 --ip-dst 10.66.67.247
-j dnat --to-dst 72:CC:9B:60:D0:0E
Here  72:CC:9B:60:D0:0E is the MAC address of tap0.

My neccessity is to get only the ethernet frame to a particular IP address
on tap0 device.

Ex: I need to get ethernet frames is destined for 10.66.67.247 on the tap0
device.
I have the enabled the ipv4 forwarding and enabled the

Can you help me out. I am stuck here almost a week.
waiting for your response.

Thanks in advance
Alan J
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.linux-foundation.org/pipermail/bridge/attachments/20090528/9f650304/attachment.htm 


More information about the Bridge mailing list