nagios-plugins icon indicating copy to clipboard operation
nagios-plugins copied to clipboard

Fix exit status of systemctl by relocating the grep pipe.

Open hromojaro opened this issue 6 years ago • 1 comments

The grep pipe was making the exit status of "systemctl status ..." always 0, returning OK to nagios when the service was not running.

hromojaro avatar Aug 14 '18 18:08 hromojaro

The real problem is that grep -i Active also matches "inactive", I think.

kjetilho avatar Nov 29 '22 14:11 kjetilho