Navigation

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

    Restart Captive Portal from command line after MAC Import

    Captive Portal
    1
    2
    2352
    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.
    • X
      XBRMann last edited by

      I have a script that runs on a hourly basis to import MAC addresses from a table of "Authorized" computers from our Network Device database into the <passthrumac>section of the /conf/config.xml file.  After I import the data, I save the /conf/config.xml file, and kill the /tmp/config.cache however the /var/db/captiveportal_mac.db file never changes until I completely restart the system.  I assuming it's possible to just restart the captive portal daemon, does anyone know that command off hand?  If not I could just import the data into the /var/db/captiveportal_mac.db as well, but I'd like to keep this as simple as possible.</passthrumac>

      1 Reply Last reply Reply Quote 0
      • X
        XBRMann last edited by

        I figured out my own problem.  I found the code in the admin webpages that restarts the captive portal services after you change them and press the "Save" button and I just called them on my own.  Seems to work well for me!

        
        #!/usr/local/bin/php -q
                require_once("captiveportal.inc");
                captiveportal_configure();
        ?>
        
        
        1 Reply Last reply Reply Quote 1
        • First post
          Last post

        Products

        • Platform Overview
        • TNSR
        • pfSense
        • Appliances

        Services

        • Training
        • Professional Services

        Support

        • Subscription Plans
        • Contact Support
        • Product Lifecycle
        • Documentation

        News

        • Media Coverage
        • Press
        • Events

        Resources

        • Blog
        • FAQ
        • Find a Partner
        • Resource Library
        • Security Information

        Company

        • About Us
        • Careers
        • Partners
        • Contact Us
        • Legal
        Our Mission

        We provide leading-edge network security at a fair price - regardless of organizational size or network sophistication. We believe that an open-source security model offers disruptive pricing along with the agility required to quickly address emerging threats.

        Subscribe to our Newsletter

        Product information, software announcements, and special offers. See our newsletter archive to sign up for future newsletters and to read past announcements.

        © 2021 Rubicon Communications, LLC | Privacy Policy