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

    Openvpn on pfsense as client

    Scheduled Pinned Locked Moved OpenVPN
    4 Posts 2 Posters 3.0k 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
      dan2010
      last edited by

      Hi All,

      I am trying to connect from my pfsense, 2.0-RC2, built on Tue Jun 14 21:13:02 EDT 2011, to a remote ubuntu box running Ubuntu 11.04, with Openvpn as a server.

      I was able to connect from my pfsense box, using command line, and can ping the server vpn box. I get an ip eg. 192.168.2.10

      From the lan behind pfsense, where all clients have a subnet of 192.168.1.xxx, I can ping the pfsense box with it's new vpn client ip, eg. 192.168.2.10, but I cannot connect the remote open vpn server, which have an ip of 192.168.2.1.
      I can stil, from my pfsense box, ping the remote openvpn server, using 192.168.2.1.

      My question is, how can I enable my pfsense to allow clients behind the pfsense box, on subnet 192.168.1.xx to connect to the remote openvpn server box (192.168.2.1, ubuntu running as an openvpn box). What commands should I use ?

      Thanks

      :-D

      1 Reply Last reply Reply Quote 0
      • jimpJ
        jimp Rebel Alliance Developer Netgate
        last edited by

        You can either setup NAT so that your LAN clients get NAT applied as they leave the OpenVPN tunnel so they show up to the far side as .2.10.

        -or-

        You can set a route/iroute on the server side so that it knows to route your LAN subnet back over the OpenVPN to you. The exact method will differ there based on how the setup is done (shared key, ssl, etc)

        Remember: Upvote with the ๐Ÿ‘ button for any user/post you find to be helpful, informative, or deserving of recognition!

        Need help fast? Netgate Global Support!

        Do not Chat/PM for help!

        1 Reply Last reply Reply Quote 0
        • D
          dan2010
          last edited by

          Thanks for your email.

          So is there a way to avoid using one ip for all clients, eg. nat clients would have a specific ip.
          For example, client 1 : 192.168.1.70 would still be visible from the remote / far end (opvn server) as this connection is coming from ip 192.168.1.70.

          Could you elaborate please or point me to a url?

          Thanks,

          1 Reply Last reply Reply Quote 0
          • jimpJ
            jimp Rebel Alliance Developer Netgate
            last edited by

            Yes, that's the second option I mentioned. The OpenVPN server needs a route back to the client. Search on the doc wiki (see my sig) for openvpn site-to-site and look at the docs. The exact method is different for SSL/TLS or Shared Key, so it depends on what you have.

            Remember: Upvote with the ๐Ÿ‘ button for any user/post you find to be helpful, informative, or deserving of recognition!

            Need help fast? Netgate Global Support!

            Do not Chat/PM for help!

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