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

    HAProxy stats page

    Scheduled Pinned Locked Moved pfSense Packages
    4 Posts 2 Posters 4.9k 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.
    • K
      kevint8
      last edited by

      Hi,

      Thanks in advance for any help or direction you can provide.  I am currently running pfSense 2.1beta and have HAProxy-full package installed.  Everything is working fine except I am unable to access the HAProxy stats page.  I believe I have everything filled in correctly, but when I try to access the HAProxy stats page it goes to the backend web server instead.

      Here's my configuration:

      /var/etc/haproxy.cfg file contents:

      global
      maxconn 9999999
      uid 80
      gid 80
      nbproc 4
      chroot /var/empty
      daemon

      listen Frontend_HTTP
      bind xxx.xxx.xxx.xxx:80
      cookie SERVERID insert indirect
      mode http
      log global
      option dontlognull
      option httpclose
      option forwardfor
      maxconn 99999
      clitimeout 30000
      balance roundrobin
      contimeout 30000
      srvtimeout 30000
      retries 2
      stats enable
      stats uri /haproxy?stats
      stats realm haproxystats
      stats auth admin:password
      stats refresh 60
      server web1_http 10.10.10.21:80  cookie web1  check inter 1000 weight 10
      server web2_http 10.10.10.22:80  cookie web2  check inter 1000 weight 20

      Whenever I go to /haproxy?stats the request gets forwarded to one of the backend server instead.  Any ideas?

      1 Reply Last reply Reply Quote 0
      • marcellocM
        marcelloc
        last edited by

        @kevint8:

        Whenever I go to /haproxy?stats the request gets forwarded to one of the backend server instead.  Any ideas?

        Did you changed you internal dns info for this site from internal direct ip to pfsense ip you configured on haproxy?

        Treinamentos de Elite: http://sys-squad.com

        Help a community developer! ;D

        1 Reply Last reply Reply Quote 0
        • K
          kevint8
          last edited by

          I am accessing the haproxy stats site using pfSense's public IP from a computer outside of the internal network.  The public IP is configured as a VIP on pfSense if that will make a difference.

          I also just tried accessing the haproxy stats site from the internal network, still no go.  I used the pfSense LAN IP.

          1 Reply Last reply Reply Quote 0
          • K
            kevint8
            last edited by

            Okay, I am not sure what exactly fixed my issue but this is the sequence of things I tried.  I decided to update to the latest 2.1beta snapshot and that broke my haproxy-full package totally (wasn't able to start the haproxy service).  To fix that issue, I re-install the haproxy-full package but kept my existing configuration.  After the re-install, haproxy service started successfully and I am able to access the haproxy stats page now!

            I hope that will help anyone with similar issue as mine.

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