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

    Add a gateway outside the current subnet interface ?

    Scheduled Pinned Locked Moved OpenVPN
    7 Posts 3 Posters 2.5k 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.
    • N
      nsteinmetz
      last edited by

      Hello,

      I have two LANs, one at home and one at my wife's office, connected by a site to site openvpn connection. This works like a charm.

      At office's side, I had to set up some static routes to acces a dedicated platfom via a custom box inside my lan.

      I would like to set up the routing also at home so that my wife can connect the platform from home and not only from office. But as IP is outside of the interface subnet, I can't add it.

      What would be the best way to add it if it's possible ?

      • Pfsense Office : 192.168.7.1

      • Office LAN : 192.168.7.0 (wired) & 192.168.3.0 (wireless)

      • Pfsense Home : 192.168.4.1

      • Home LAN : 192.168.4.0 (wireless)

      • Site to site openvpn : use 192.168.5.0 as virtual IP

      • Custom Box : 192.168.7.198

      • Static route : access to 172.30.0.0/16  via 192.168.7.198

      1 Reply Last reply Reply Quote 0
      • H
        heper
        last edited by

        just add a route to the vpn options on your home-pfsense for 172.30.0.0/16 via the openvpn-server-ip on the office-pfsense ?

        1 Reply Last reply Reply Quote 0
        • C
          cmb
          last edited by

          don't add static routes like that with OpenVPN, add them in the custom options box instead. "route x.x.x.x 255.255.x.x"

          1 Reply Last reply Reply Quote 0
          • N
            nsteinmetz
            last edited by

            Thanks, I'll do this way.

            1 Reply Last reply Reply Quote 0
            • N
              nsteinmetz
              last edited by

              Hi,

              Can I add a route when the Site to site OpenVPN is from Office (client) to Home (server) or do I need to switch the roles first ?

              Thanks,
              Nicolas

              1 Reply Last reply Reply Quote 0
              • C
                cmb
                last edited by

                it can be done either way, doesn't matter which end is which.

                1 Reply Last reply Reply Quote 0
                • N
                  nsteinmetz
                  last edited by

                  Perfect, it works like a charm  8)

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