Results 1 to 5 of 5

Thread: How to enable server-status?

  1. #1
    Join Date
    Jun 2019
    Posts
    9

    How to enable server-status?

    I cant get it to work somehow.

    i editted the /etc/httpd/conf/extra/httpd-info.conf file and set:

    Code:
    <Location /server-status>
        SetHandler server-status
        Require host www.ourserverhostname.tld
        Require ip 213.61.xx.xxx
    </Location>
    next i did a config check:

    Code:
    apachectl -t
    Syntax OK
    also made sure the needed modules are loaded:
    Code:
    httpd -M |grep authz
     authz_host_module (static)
     authz_groupfile_module (static)
     authz_user_module (static)
     authz_dbm_module (static)
     authz_owner_module (static)
     authz_dbd_module (static)
     authz_core_module (static)
    
    httpd -M |grep info
     info_module (static)
    
    httpd -M |grep status
     status_module (static)
    restart apache and vistied the url:
    Code:
    www.ourserverhostname.tld/server-status
    and get:

    Forbidden
    You don't have permission to access this resource.


    error_log says:

    [Mon Sep 02 12:16:37.666608 2019] [access_compat:error] [pid 29236:tid 140170980239104] [client 213.61.xx.xxx:43470] AH01797: client denied by server configuration: /var/www/html/server-status


    so how to fix this?

    I'm on centos 7 with the latest directadmin and everything updated

  2. #2
    Join Date
    Apr 2005
    Location
    GMT +7.00
    Posts
    13,556
    Hello,

    From here everything is looking fine. Will it work if you remove the both lines:

    Code:
      Require host www.ourserverhostname.tld
      Require ip 213.61.xx.xxx
    Do you have a reverse-proxy in front of Apache? Nginx probably?
    Regards, Alex G.

    - Get the best commercial DirectAdmin support and hire me on poralix.com
    - Follow and like @Poralix on Facebook

  3. #3
    Join Date
    Jun 2019
    Posts
    9
    yes it works when removing the requires... but this server doesnt use nginx. Also no other reverse-proxy as far as i can tell.

  4. #4
    Join Date
    Jun 2019
    Posts
    9
    seems that without the requires and looking at the output of server-status, the server status page's client is not my ip address but that from the webserver itself?!

    that sounds like a proxy but whenever i visit any other webpage it does show my ip as the client ip.

  5. #5
    Join Date
    Jun 2019
    Posts
    9
    never mind... seems my ip number had changed overnight.

    it does work.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •