Page 1 of 1

WMI monitoring with compex password

Posted: Tue Jan 14, 2014 4:18 am
by tenwheel230
Hi,

How to use complex password with check_xi_service_wmiplus service.

With a password contain specials characters as $, check_xi_service_wmiplus service is not running.

check_xi_service_wmiplus!'user'!'complex$password'!checkmem!-s physical -w '80' -c '90'
UNKNOWN - The WMI query had problems. You might have your username/password wrong or the user's access level is too low. Wmic error text on the next line.
[librpc/rpc/dcerpc_util.c:1290:dcerpc_pipe_auth_recv()] Failed to bind to uuid 4d9f4ab8-7d1c-11cf-861e-0020af6e7c57 - NT_STATUS_NET_WRITE_FAULT
[librpc/rpc/dcerpc_connect.c:790:dcerpc_pipe_connect_b_recv()] failed NT status (c0000022) in dcerpc_pipe_connect_b_recv
[wmi/wmic.c:196:main()] ERROR: Login to remote object.
NTSTATUS: NT_STATUS_ACCESS_DENIED - Access denied
In line command, ./check_wmi_plus.pl -H 10.65.1.74 -u 'user' -p 'complex$password' -m checkmem -s physical -w '80' -c '90' is running.

Thx.

Re: WMI monitoring with compex password

Posted: Tue Jan 14, 2014 12:08 pm
by abrist
Use the nagios resource.cfg file to add the password as a user macro as that file is provided for the cases that invlove strings with illegal macro characters in them. Simply open:

Code: Select all

/usr/local/nagios/etc/resource.cfg
And add a new $USERn$ macro, then call that directly in the service definition by replacing the password with the user macro specified in the resource.cfg file.