[SOLVED] NagiosXI does not show graphic

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
sincorchetes
Posts: 3
Joined: Mon Feb 25, 2019 10:12 am
Location: Spain, Palma de Mallorca
Contact:

[SOLVED] NagiosXI does not show graphic

Post by sincorchetes »

Hello all,

I made a script to graphic that I get an int value like 200.

I have this in conditional into script to notify a Nagios state:

Code: Select all

ok=0
critical=1
warning=2

if [ "${resultado}" > "$5" ]; then
  echo "CRITICAL: Score is ${result} | 'score'=${result};100;110;;;"
  exit ${critical}
elif [ "${resultado}" == "$4" ]; then
  echo "WARNING: Score is too low ${result} | 'score'=${result}50;100;;;"
  exit ${warning}
elif [ -z "${resultado}" ]; then
  result=0
  echo "CRITICAL: Score is ${result} | 'score'=${result};100;110;;;"
  exit ${critical}
else
  echo "OK: Score is ${result} | 'score'=${result};120;5000;;;"
  exit ${ok}
fi
I get correctly status, message... in NagiosXI and Nagios Core but I don't give graphics.

In NagiosXI, I have perform_data enabled, but rrd never is generated. Why It does not work?

Cheers.

EDIT: I removed ";;;" from echo lines and It's solved.
---
Álvaro Castillo
System Administrator
Blog: https://echemosunbitstazo.es
Twitter: https://twitter.com/sincorchetes
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: [SOLVED] NagiosXI does not show graphic

Post by scottwilkerson »

Great!

Locking thread
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked