Skip to content

linux snclient nrpe external command arguments not parsed #238

@Wolverine65

Description

@Wolverine65

I'm trying to use the check_logfiles check from omd nagios host with NRPE module enabled on the scnlient agent machines

omd thruk host:

$ /omd/sites/vpe/lib/monitoring-plugins/check_nrpe -H $IP_ADDRESS -t 20 -c check_logfiles rundeck_logfile_scm_failed

snclient agent:

snclient.ini # SNClient v0.33 (Build: 7357817, go1.23.8)

[/settings/NRPE/server]
allow nasty characters = true
allow arguments = true

[/settings/external scripts/scripts]

allow arguments = yes
check_logfiles=scripts/check_logfiles --config $ARGS$

tried all of these ( with and without quotes )

$ARGS$ contains all macros space separated without quotes.
$ARGS"$ contains all macros space separated with quotes.
$ARGSn$ contains the value of the argument at position n.

[check_wrap:74] command before macros expanded: check_logfiles --config '$ARG1$'
[2025-05-23 10:40:18.546][Debug][pid:1275678][check_wrap:76] command after macros expanded: check_logfile --config '' "

resulting outcome should be

check_logfiles --config rundeck_logfile_scm_failed

OS information

PRETTY_NAME="Ubuntu 22.04.5 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.5 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions