I initiated this page to show a view tricks that can be done with the
Pimped Apache Server status.
I hope you explore some useful hints here :-)
Q: I want to save my own settings. What do I need to backup?
A: The footprint of the tool is quite small ... just the whole application directory.
But to answer the question: the real custom data are:
Q: I want to remove a few unneeded columns. Because I don't need them and get a bit more space.
A: Use the hideCols value in the config. As array elements add the
column names like written in the table header.
Config snippet:
{ "hideCols": [ "Srv", "Acc", "SS", "Req", "Conn", "Child", "Slot" ] }
Q: I want to remove lines. I wanna hide the /server-status requests of the monitoring tool.
A: In the settings you need to set a value for hideRows.
To do so go to the "Settings" in the configuration area.
You can define an exclude rule for the column "Client"
that exactly matches ("eq" is equal) a given ip address (here: "192.168.100.107")
Config snippet:
{ "hideRows": { "*": [ [ "remove", "Client", "eq", "192.168.100.107" ] ] } }
You can define an exclude rule for the column "Request"
that matches the "regex" for a GET request to /server-status.
The character # is part of the regex. Additionally you need to quote special chars.
Config snippet:
{ "hideRows": { "requests_running": [ [ "remove", "Request", "regex", "#GET\\ \/server-status#" ] ] } }
Q: I want find where an ip address is located that makes (a lot or strange) requests to my server.
A: By default each click to a value will put it into filter field
of the table. You can change the link target. Use the tdlink
value in the config. The first key is the column name.
As subkeys add the html attributes of a link tag (<a [attributes]>..</a>
). The string %s
will be replaced by the original
value.
The ip address is in the column "Client".
To override the link target set href attribute. Here we put
a url that must handle %s as ip address.
Just to
beautify the link I add a title and let open the link in a new tab.
The result is:
Config snippet:
{ "tdlink": { "Client": { "href": "https:\/\/whatismyipaddress.com\/ip\/%s", "target": "_blank", "title": "show at whatismyipaddress.com" } } }
You can beautify any server-status page without configuring it. It requires that it is reachable by your monitoring server, i.e. it is public in the internet (what is a bad idea) or in you LAN.
Just once: Prepare a bookmark:
Go to the help page and create a bookmark by drag and drop
the bookmarklet.
As often you want:
If you see a /server-status page in default mode in your webbrowser
then click on the bookmarklet to let the magic happen.