Home > Nagios, plugins > Check how many users in a group

Check how many users in a group

Nagios plugin to Check how many users in a group check_group.vbs
This script verifies if the number of users in a particular group changes.

The output in debug mode Example:

c:Program Files (x86)Nc_netscript>cscript.exe //nologo C:PROGRA~2NC_Netscr
iptcheck_group.vbs -g CN=Domain Admins,CN=Users -u 4
CN=Domain Admins,CN=Users
LDAP://CN=Domain Admins,CN=Users,DC=cado,DC=local
user : CN=Domain Admins : mntos
user : CN=Domain Admins : Mcia
user : CN=Domain Admins : bides
user : CN=Domain Admins : rLagito
user : CN=Domain Admins : Ffex
user : CN=Domain Admins : Administrator
CN=Domain Admins contains ; 6 ; users
Group CN=Domain Admins,OU=Groups has, Total of 6 users.
CRITICAL – The group CN=Domain Admins,CN=Users has changed from 4 users, to 6 

Without the debug mode it just shows the final line:
CRITICAL – The group CN=Domain Admins,CN=Users has changed from 4 users, to 6

Should be called using NC_Net or other windows nagios client.

The remote call should something like:
/check_nt -H riolb155-t 60 -v RUNSCRIPT -l cscript.exe //nologo C:PROGRA~1NC_Netscriptcheck_group.vbs -g CN=Domain Admins,CN=Users -u 4″

To use nc_net check my one of my old posts here

DOWNLOAD HERE

  1. No comments yet.
  1. No trackbacks yet.

VAMOVE *

*