I have two machines on 2 different networks which are interconnected.

First network:


Second network:


The first network is running an OpenVPN under with ipv4_forwarding enabled.

The second network is running a bastion server under with ipv4_forwarding enabled.

The second network has a routing rule to access some S2S with this range:

I'm trying to figure out how can I receive packets on the OpenVPN client that will be forwarded to the bastion server and from there to the S2S only when the packets are actually heading towards this specific range (

Do I need to alter the iptables on the bastion server or forwarding is sufficient?

Thank you very much :)

  • Lets talk about the route statement for a moment. Is it supposed to accommodate first and second network? Jun 12 at 17:16
  • @BruceMalaudzi Nope, will cover both the first and second one, I'm talking about a route on the second network which is accessible from the first network despite there's no direct routing between them (only through the second network).
    – Yaron
    Jun 12 at 21:43
  • Share the output of "ip route show" from the bastion server Jun 12 at 21:48
  • @BruceMalaudzi all the routing is handled externally so OpenVPN has a connection to the outside world with a route to the local subnet and a peering connection to the bastion server, the bastion server is quite the same in this aspect.
    – Yaron
    Jun 18 at 13:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.