Page 1 of 1

NagiosXI - Performance graphs not working

Posted: Tue Apr 06, 2021 7:03 am
by Bala.Mutyam
Hi there,

We're experiencing an issue with our performance graphs and it's NOT displaying for our custom scripts created for checks. I've attached a couple of example scripts. Please help us what are we doing wrong here please?

Not sure if it's relevant but Performance Grapher status showing up in red on System Component Status and attached it's screenshot.

Thanks
Bala

Re: NagiosXI - Performance graphs not working

Posted: Tue Apr 06, 2021 3:01 pm
by benjaminsmith
Hi Bala,

Thanks for posting that screenshot. If the process is not running, that will impact the performance graph, try running the following command from the CLI to restart it and let me know if the status turns green.

Code: Select all

systemctl restart npcd
I'm not seeing performance data output in the custom scripts, this should be after the| character in the output string (unless this is not required). In order for the system to process performance data, the plugin must output the data in a specific format. The format is explained on the page below.

Nagios Plugins Development Guidelines

Regards,
Benjamin

Reference
Nagios XI - Performance Graph Problems

Re: NagiosXI - Performance graphs not working

Posted: Mon Apr 12, 2021 5:18 am
by Bala.Mutyam
@Benjamin: Hi, thanks for the update.

I've restarted npcd and system status is all green now.

I've added | to script but still graphs not showing. I've attached modified script. Do i need add anything else?

Thanks
Bala

Re: NagiosXI - Performance graphs not working

Posted: Mon Apr 12, 2021 3:51 pm
by benjaminsmith
Hi Bala,

Getting closer. After the | character, you'll want to include the performance data in the proper format. For example, the minumu would looks something like (pseudo-code)

Code: Select all

Write-Host -NoNewline ""The plugin Output String | Used = ${UsedSpaceGB}%; "
exit $code;
This is just an example to clarify. Custom development is outside the scope of product support.

Let me know if you get it working. You'll find the format for the perf data on the following page.

See: Nagios Plugins Development Guidelines

Benjamin