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

    Captiveportal Status – Where can I find this file (what directory)?

    Captive Portal
    2
    4
    1.2k
    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.
    • S
      scmaccal
      last edited by

      Greetings,

      Where can I find the Captiveportal Status file (what directory)? I'd like to use it for statistical purposes and make sure a backup of it is stored somewhere as I noticed that upon reboot of my psSense device previous days where gone.

      Thank you,

      Scott

      Scott

      1 Reply Last reply Reply Quote 0
      • GertjanG
        Gertjan
        last edited by

        Hello,

        Look here /usr/local/www - it's there.

        Btw: I use this 'self-made scrpit' that a 'Munin' plugin uses:

        #!/usr/local/bin/php -q
        
        require_once("/etc/inc/util.inc");
        require_once("/etc/inc/functions.inc");
        require_once("/etc/inc/captiveportal.inc");
        
        /* read in captive portal db */
        $cpzone ="cpzone"; /* hard code */
        $cpdb = captiveportal_read_db();
        /* determine number of logged in users */
        echo count($cpdb);
        
        ?>
        

        to make this  http://www.test-domaine.fr/munin/dyndns.org/brithotelfumel.dyndns.org/index.html#portalusers

        No "help me" PM's please. Use the forum, the community will thank you.
        Edit : and where are the logs ??

        1 Reply Last reply Reply Quote 0
        • S
          scmaccal
          last edited by

          Gertjan,

          Thank you for the response and sharing your code.

          Right now I have a simple click button Captive Portal with defaults configured. Do you happen to know how long a device has before it has to re-authenticate with the CP? I want to make sure I understand the data being collected… Whether the authentication in the log represents a unique one time event or is something that may reoccur again in given amount of time.

          Scott

          1 Reply Last reply Reply Quote 0
          • GertjanG
            Gertjan
            last edited by

            Well,

            Toy a little bit with the two time-out settings (hard and soft) and you'll understand quickly how they interact.

            No "help me" PM's please. Use the forum, the community will thank you.
            Edit : and where are the logs ??

            1 Reply Last reply Reply Quote 0
            • GertjanG Gertjan referenced this topic on
            • First post
              Last post
            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.