I have a RasbperryPi which is connected with Ethernet (eth0) to a VLan (vlan0). This VLan has only access to the Internet and devices in the VLan (vlan0) can not communicate with each other. Furthermore, devices in (vlan0) have no access to all other devices in my house (e.g. NAS etc.) because those are in a second VLan (vlan1).

My PC has only one network interface, which is connected to vlan1. But I want to be able to access my Raspberry Pi from this PC via SSH. Since the Raspberry Pi has wlan0 as a network interface in addition to eth0, my solution would be to route all network traffic through eth0 and only allow SSH connections through wlan0, so that services running on the Pi necessarily use eth0 and wlan0 is really only used for SSH, so that there is no way for any service other than SSH to get into my "private" VLan (vlan1) where it could then access my NAS, for example.

How is this possible? I can't find a real answer on the internet or I don't know what exactly to google for.

ps: on the RaspberryPi runs Ubuntu Server 20.04.4 LTS

Thanks a lot for your answers!

  • I can't find a real answer on the internet This 'issue' is not specific to the Pi, so make sure not to put any reference to Pi in any internet searches.
    – Dirk
    Apr 1, 2022 at 15:24
  • Interesting questions, but they don't seem to be 'on topic' as defined in the 'rules of engagement' here. For that reason, I will regretfully vote to close your question. As an aside from someone who knows nothing about VLANs, your question also seems to lack any details that might be useful to someone trying to answer your question (e.g. how you are currently handling inter-vlan routing?).
    – Seamus
    Apr 2, 2022 at 13:02


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.