Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    OpenVPN with both incoming and outgoing peer to peer connection

    Scheduled Pinned Locked Moved OpenVPN
    3 Posts 2 Posters 534 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • D Offline
      dweick
      last edited by

      I have three locations all with WAN and LAN port

      Site 1: LAN 10.10.50.x, has a peer-to-peer OpenVPN server
      Site 2: LAN 10.10.5.x, has a peer-to-peer OpenVPN client connecting to Site 1 and an peer-to-peer OpenVPN server
      Site 3: LAN 10.10.4.x, has a peer-to-peer OpenVPN client connecting to Site 2

      It usually have Site 2 connected to Site 1 for the purpose of exiting all my Internet traffic through Site 1

      If I don't have Site 2 connected to Site 1 I can have Site 3 connect to Site 2 for the purpose of having all its Internet traffic go through Site 2

      That all works fine

      However, I would like Site 3 to be able to connect to Site 2 at the same time Site 2 is connected to Site 1 and have Site 3's traffic exit at Site 2 with Site 2's traffic exits at Site 1

      When I do have both connections running and connected I can't browse the web from Site 3 (hard coded DNS 8.8.8.8 settings on machine at Site 3 used to test).  Site 2 continues to work fine.

      Any suggestions/help would be appreciated

      1 Reply Last reply Reply Quote 0
      • V Offline
        viragomann
        last edited by

        At site 2 you have a firewall rule allowing the traffic from site 3 to anywhere, presumably. To send traffic from site 3 out to WAN gateway you have to set the gateway in that rule in the Advanced Options.

        Presumably you also want to access the LAN at site 2 from site 3, so you have to split that rule. One allowing access to LAN without the gateway set and another one allowing internet destinations with WAN gateway set.

        1 Reply Last reply Reply Quote 0
        • D Offline
          dweick
          last edited by

          I wasn't sure if you were saying I needed to modify the Firewall->Rules->WAN rule for that VPN connection or modify the default OpenVPN rule to change the default gateway, I changed the OpenVPN rule and success.  Thanks!

          I didn't actually want Site 3 to be able to access anything on the Site 2 LAN

          1 Reply Last reply Reply Quote 0
          • First post
            Last post
          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.