Giter Site home page Giter Site logo

Comments (5)

axelhahn avatar axelhahn commented on September 13, 2024

Hi @azurit

thanks for reporting this!
I see where the division by zero occurs. I can fix that.

But I would like to know in which constellation it happens.
the file ./config/config_servers.json ... what does it contain? If you just initialized it there should be only localhost - something like that:

{
    "default": {
        "servers": {
            "localhost": {
                "label": "localhost"
            }
        }
    }
}

If so - what is the response of curl -i localhost/server-status?

Kind regards,
Axel

from pimped-apache-status.

azurit avatar azurit commented on September 13, 2024

Yes, that file contains exact data as you wrote.

Result is our custom default page (there is no mod_status set on /server-status URI, is that a requirement?):

# curl -i localhost/server-status
HTTP/1.1 200 OK
Date: Tue, 28 Nov 2023 21:10:32 GMT
Server: RANDOM
Vary: Accept-Encoding
Cache-Control: no-cache, no-store, max-age=0
Transfer-Encoding: chunked
Content-Type: text/html; charset=UTF-8

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<style type="text/css">
        html {height: 100%; width: 100%; border: 0; margin: 0}
        body {height: 100%; width: 100%; border: 0; margin: 0}
        iframe {height: 100%; width: 100%; border: 0; margin: 0}
        div {height: 100%; width: 100%; border: 0; margin: 0}
</style>
</head>
<body>
<div><iframe src="https://<censored>/pages/1//"></iframe></div>
</body>
</html>

from pimped-apache-status.

axelhahn avatar axelhahn commented on September 13, 2024

Thanks for your http response!

On a system to be monitored you need the module mod_status and the setting ExtendedStatus On.
https://www.axel-hahn.de/docs/apachestatus/get_started.htm#Onmonitoredsystems

(1)
I fixed the division by 0 in the linked branch in the datarenderer.class.php


With your response code I try to find out if there is another impact too.

(2)
On the system where the apache status is installed I add "localhost" by default. If you would install mod_status and add ExtendedStatus On then it would run without applying the datarenderer.class.php.

(3)
If you try to add other hosts to monitor the response will be checked if it is a server status response. I need to verify it for localhost too. If it is done I will merge it into master and make a new release.

Kind regards,
Axel

from pimped-apache-status.

azurit avatar azurit commented on September 13, 2024

I want to monitor external hosts, not localhost, and i thought this is possible.

from pimped-apache-status.

azurit avatar azurit commented on September 13, 2024

It works, thank you!

from pimped-apache-status.

Related Issues (12)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.