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

    OpenVPN Commands

    Scheduled Pinned Locked Moved OpenVPN
    4 Posts 2 Posters 1.2k 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.
    • T Offline
      TreeDark
      last edited by

      Good Morning,
      I would like to know where I get Commands for OpenVPN, I need to make a script for when to drop a tunnel, disable one and upload another. I would like to know if you have any documentation pages for pfSense openvpn commands.

      Tks.

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

        you'll be in for a rough ride

        https://doc.pfsense.org/index.php/Using_the_PHP_pfSense_Shell

        example from devshell

        
        pfSense shell: playback svc start openvpn client 1
        
        

        example from shell:

        pfSsh.php playback svc stop openvpn client 1
        
        1 Reply Last reply Reply Quote 0
        • T Offline
          TreeDark
          last edited by

          Thanks,
          I would like to disable the tunnel, is there a command for this?
          My situation is as follows:
          I have a main tunnel in ipv6 and a secondary tunnel for ipv4 failover.
          So I need to disable the tunnel that I'm not using.

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

            you'd need to script a marcro to write the config (examples can be found in the wiki link i posted before)

            i posted some examples for someone who wished to change settings to captive-portal here:
            https://forum.pfsense.org/index.php?topic=121762.msg673072#msg673072

            its not all that difficult but will need some experimenting.

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