Live data from Hacker News

Raspberry Pi WiFi to ethernet bridge

willhaley.com

11–20 of 67 posts

Re: Raspberry Pi WiFi to ethernet bridge

#12
I did something similar to bring a legacy cable-only printer online for wifi clients where there were no cabled uplink. Worked well. Tried to add airprint with cups as well but that was hit&miss.

parprouted & dhcp-helper are secret gems!

Re: Raspberry Pi WiFi to ethernet bridge

#13

I might as well just dump this question in this thread: Would this be easy to combine with openvpn? Basically what I'd like is to hook (say) my Apple TV into my pi by ethernet and then use the pi's wifi to connect to my router. Finally I'd like to be able to connect the pi to a VPN and have the Apple TV transparently use that connection. Is this straight-forward to achieve?

Yep, rather straight-forward. Little bit of iptables forwarding and you're all set: echo 1 > /proc/sys/net/ipv4/ip_forward iptables -A FORWARD -i eth0 -o wlan0 -j ACCEPT iptables -A FORWARD -i wlan0 -o eth0 -m state --state ESTABLISHED,RELATED -j ACCEPT iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE I'd recommend wireguard[0] in preference to openvpn. refs: [0] https://www.wireguard.com/

May I ask where I might start learning things like this?

Re: Raspberry Pi WiFi to ethernet bridge

#14

Ah yes, network configuration by way of executing a random bash script from a blog. With tasty morsels like: ># I have to admit, I do not understand ARP and IP forwarding enough to explain exactly what is happening here.

I mean, the number of people on this site who could intelligently explain ARP and IP forwarding in detail is probably 10x higher than in the general population—and that percentage here is probably in the low single digits.

Re: Raspberry Pi WiFi to ethernet bridge

#16

I might as well just dump this question in this thread: Would this be easy to combine with openvpn? Basically what I'd like is to hook (say) my Apple TV into my pi by ethernet and then use the pi's wifi to connect to my router. Finally I'd like to be able to connect the pi to a VPN and have the Apple TV transparently use that connection. Is this straight-forward to achieve?

Has anyone tried this and successfully blocked ads from services like YouTube and Hulu? uBlock works on my computer but I've always had a hard time with pihole. It'll work for like a day then go back to serving ads.

Re: Raspberry Pi WiFi to ethernet bridge

#17
post #4

You can also do this with an old OpenWrt router, which also gets you a management interface and a gigabit Ethernet switch as part of the plastic box. I used to have such a bridge (OpenWrt on Netgear WNDR3800 hardware) Velcro'd to the underside of a TV cart, so that an appliance on the cart that only had Ethernet and 2.4 GHz WiFi built-in could do a more reliable 5 GHz across the room.

I agree that this is a much better option. Also, if you use two OpenWrt devices, you can enable WDS mode to build a true layer 2 bridge. That is, you won't need Proxy ARP and DHCP relay. For example, DHCP and IPv6 will just work out of the box.

Edit: From what I can tell, support for WDS depends on the WiFi chipset. "iw list" must explicitly include "WDS" as a "supported interface mode". At least the Broadcom chipset on the Raspberry Pi Zero does not support this, but, for example, the Atheros chipsets used in a variety of routers do.

Re: Raspberry Pi WiFi to ethernet bridge

#18
This can also be set up graphically using OpenWRT (which is a lighter-weight OS if you just want to do some networking and not use the Pi for anything else.

I should note that while the onboard WiFi is 802.11ac, I've never seen it get more than 60-70 Mbps in my own testing (in a variety of network environments), so if you want more speed, you might want to get an old n or ac router and flash it with OpenWRT instead.

Re: Raspberry Pi WiFi to ethernet bridge

#20

This can also be set up graphically using OpenWRT (which is a lighter-weight OS if you just want to do some networking and not use the Pi for anything else. I should note that while the onboard WiFi is 802.11ac, I've never seen it get more than 60-70 Mbps in my own testing (in a variety of network environments), so if you want more speed, you might want to get an old n or ac router and flash it with OpenWRT instead.

Yeah, this. I've used Ethernet bridge on old Netgear 802.11n routers, and it's quite fast.
Post reply on HN