Ad Widget

Collapse

NGINX Stub Status Page

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • stevefxp
    Senior Member
    • Aug 2020
    • 168

    #1

    NGINX Stub Status Page

    Hello all,

    I am trying to monitor my NGINX processes. I am using the Zabbix agent template and understand I need to have the stub status page available. My question is related to the config of the page:

    location /nginx_status {
    stub_status on;
    access_log off;
    allow 172.24.16.4;
    deny all;
    }

    Should the allow line be the IP of the main Zabbix server or should it be the server itself, since there is a Zabbix agent on the server? I continue to get a 404 not found and The requested URL /basic_status was not found on this server.

    Thanks,
    Steve
  • Hamardaban
    Senior Member
    Zabbix Certified SpecialistZabbix Certified Professional
    • May 2019
    • 2713

    #2
    If http://bablabla/nginx_status is configured, then request it. Not URL /basic_status !
    The agent's access from the 127.0.0.1 address is sufficient.

    Comment

    • stevefxp
      Senior Member
      • Aug 2020
      • 168

      #3
      I think part of the problem could be that the default port for NGINX to respond is port 80. When I try to hit htttp://blahblahblah/nginx_status it pushes me to HTTPS.

      Comment

      • Hamardaban
        Senior Member
        Zabbix Certified SpecialistZabbix Certified Professional
        • May 2019
        • 2713

        #4
        If you check the url on your computer with a modern browser, it automatically changes the scheme to httpS. Zabbix uses curl and doesn't do that.
        The second possible option is that you have redirection configured in nginx. Here you manage the settings yourself.

        Comment

        • stevefxp
          Senior Member
          • Aug 2020
          • 168

          #5
          All good...you were correct and NGINX was redirecting. Curl is my friend! Thank you!

          Comment

          Working...