[Xymon] Multiple graphs on one web page - not being shown - solved

John Horne john.horne at plymouth.ac.uk
Thu May 30 13:08:24 CEST 2019


On Fri, 2019-05-24 at 07:30 +0000, Norbert Kriegenburg1 wrote:
>
> Why don't you create your graph link in your own test?
>
Hi,

Mainly because this is something that Xymon should be able to do, and from my
understanding can do. The custom tests we have should just run the test and
report the results.

It turns out that enabling this is actually relatively easy. I had to work
through the xymon code, but it seems that the GRAPHS variable is checked to see
if the graph for a test exists. If the test isn't included in that variable,
then no graph is shown.

Unfortunately I was going by the comments in the 'xymonserver.cfg' file,
especially the bit where it said that for the GRAPHS variable this referred to
tests which would be shown in the 'trends' web page. I did not want my 'es'
gaphs in the trends page, so did not include it in the GRAPHS variable.

I initially had set the following (for the 'es' test):
TEST2RRD="...,es"
GRAPHS_es="es-heap,es-latency,es-rates"

What was additionally required to do what I wanted was:
GRAPHS="...,es"
(In the 'hosts.cfg' file) 0.0.0.0 .default. # ... TRENDS:*,!es

The last one above tells xymon not to show the 'es' graphs in the trends
column. By using the above settings I get what I want - an 'es' column with the
web page containing 3 graphs and not appearing in the 'trends' page.
(I should add that we already run an external script to handle our extra tests,
and so had to also modify that script and the 'tasks.cfg' file to include the
'es' test.)




John.

>
> -----"Xymon" <xymon-bounces at xymon.com> wrote: -----
> To: "xymon at xymon.com" <xymon at xymon.com>
> From: John Horne
> Sent by: "Xymon"
> Date: 05/23/2019 06:37PM
> Subject: [EXTERNAL] [Xymon] Multiple graphs on one web page - not being shown
>
> Hi,
>
> Using the Terabithia RPMs I have created a custom test called 'es' (it's for
> some stats from an elasticsearch search engine). I created a client-side
> script to gather the current status and data for the graphs.
>
> The 'status' message gets sent okay, and an 'es' column is created and the
> web page shows a one-line summary of the search engine - e.g. 'It's fine',
> 'It's not fine' etc. It changes colour depending on the colour being sent by
> the client-side script. This works too.
>
> The 'data' message from the script is also sent okay, and has created 3 RRD
> files for the host. These are named 'es_heap.rrd', 'es_rates.rrd' and
> 'es_latency.rrd'. The values within them are being updated, and if I use a
> crafted URL (using showgraph.sh) I can see that graphs for them are valid.
>
> However, what I wanted was all 3 graphs to appear on the 'es' status page.
> I have added 'es' as a test name to the hosts in the 'hosts.cfg' file. I have
> also added 'es' to the TEST2RRD definition, but I'm not sure that is needed
> in this case. I have also added 'GRAPHS_es="es-rates,es-latency,es-heap"' to
> the 'xymonserver.cfg' file. Within the 'graphs.cfg' file I have created the 3
> graph definitions using the 'GRAPHS_es' names.
>
> For some reason though the graphs do not appear. We have several custom tests
> which produce a single graph, but this is the first where we want more than
> one graph shown.
>
> Anyone any ideas about this?
>

--
John Horne | Senior Operations Analyst | Technology and Information Services
University of Plymouth | Drake Circus | Plymouth | Devon | PL4 8AA | UK
________________________________
[http://www.plymouth.ac.uk/images/email_footer.gif]<http://www.plymouth.ac.uk/worldclass>

This email and any files with it are confidential and intended solely for the use of the recipient to whom it is addressed. If you are not the intended recipient then copying, distribution or other use of the information contained is strictly prohibited and you should not rely on it. If you have received this email in error please let the sender know immediately and delete it from your system(s). Internet emails are not necessarily secure. While we take every care, University of Plymouth accepts no responsibility for viruses and it is your responsibility to scan emails and their attachments. University of Plymouth does not accept responsibility for any changes made after it was sent. Nothing in this email or its attachments constitutes an order for goods or services unless accompanied by an official order form.


More information about the Xymon mailing list