I am using pppd (in linux) to send ethernet data over a serial line to another computer. How can I preserve L2 headers while sending Ethernet frames over serial line? It seems the ppp protocol sends only the "L3 data" as its payload thus dropping the L2 headers including src/dst MAC addresses. What protocol, etc. should I use to preserve L2 headers?
closed as off-topic by PeterJ, Matt Young, Daniel Grillo, alexan_e, Vladimir Cravero Jul 10 '14 at 17:19
- This question does not appear to be about electronics design within the scope defined in the help center.
pppd acts as a router, selecting which packets to forward over the serial link, since the speed of the serial link will generally be much lower than the rest of the LAN, and you don't want it to be any more of a bottleneck than necessary.
It sounds like you want the serial link in your application to function more like a bridge that connects two physically separate but logically unified network segments. This can be done, but it usually involves a communication link that has at least the same order of magnitude of speed as the LAN (e.g., T1, Frame Relay, etc.). If you want to do this over an asynchronous serial line, I think you're going to have to create that software yourself, since it sounds like a fairly unique requirement.