PDC plugin {Disarmed} {Fraud?}

Marc Powell marc at ena.com
Fri Jan 19 16:16:35 CET 2007



> -----Original Message-----
> From: nagios-users-bounces at lists.sourceforge.net [mailto:nagios-users-
> bounces at lists.sourceforge.net] On Behalf Of Hari Sekhon
> Sent: Friday, January 19, 2007 6:38 AM
> To: Nagios Users mailinglist
> Subject: Re: [Nagios-users] PDC plugin {Disarmed} {Fraud?}
> 
> Thanks for the suggestion Marc, that is a good idea! I only used
dcdiag
> when setting up the domain to check things and then forgot all about
it.
> 
> The only problem is that is creates a lot of output, I'd have to
create
> quite a plugin to test everything and then try and get something
> meaningful in 1 line...

It's not that significant. In your case, running dcdiag as I suggested
tests everything in one go and returns a result that looks like --

      Starting test: Replications
         ......................... MISDC02 passed test Replications
      Starting test: NCSecDesc
         ......................... MISDC02 passed test NCSecDesc
      Starting test: NetLogons
         ......................... MISDC02 passed test NetLogons
      Starting test: Advertising
         ......................... MISDC02 passed test Advertising

While I have never seen a failure, I would expect that they might look
something like --

      Starting test: Replications
         ......................... MISDC02 failed test Replications
      Starting test: NCSecDesc
         ......................... MISDC02 passed test NCSecDesc
      Starting test: NetLogons
         ......................... MISDC02 failed test NetLogons
      Starting test: Advertising
         ......................... MISDC02 passed test Advertising

With perl it'd be an easy task to pick off the lines that 'failed', grab
the last word, concatenate it to an output variable then exit with
something like --
	
	CRITICAL: failed Replications, NetLogons

--
Marc

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list