#!/bin/bash<br># nusers.sh<br><br>WARN_T=$1;<br>CRIT_T=$2;<br>UPTIME="/usr/bin/uptime";<br><br>NUSERS_NOW=`$UPTIME|awk '{print $4}'`;<br><br>[[ $NUSERS_NOW -lt $WARN_T ]] || ( echo "WARNING"; exit 1);<br>
[[ $NUSERS_NOW -gt $CRIT_T ]] && (echo "CRITICAL"; exit 2);<br><br>echo "UKNOWN"; exit 3;<br><br>#end nusers.sh<br><br><div class="gmail_quote">On Mon, May 26, 2008 at 12:39 PM, Andy Shellam <<a href="mailto:andy.shellam-lists@mailnetwork.co.uk">andy.shellam-lists@mailnetwork.co.uk</a>> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Install the Nagios sample configuration files and you will see how the<br>
configuration is laid out.<br>
The documentation (supplied with the installation) is really decent; at<br>
least have a look and then come back with specific questions.<br>
<font color="#888888"><br>
Andy<br>
</font><div><div></div><div class="Wj3C7c"><br>
Mangesh Dhamale wrote:<br>
> hi,<br>
><br>
> Can you give me any example.<br>
><br>
> Regards,<br>
><br>
> Mangesh Dhamale<br>
> -----------------------------------------------------------------<br>
> System Administrator<br>
> Suma Soft Pvt. Ltd.<br>
> Suma Center, IInd Floor, Opp. Himali Society,<br>
> Near Mangeshkar Hospital, Erandwane, Pune - 411004<br>
> Ph : +91-20-40130400 Extn : 327<br>
> Cell : +91-98508 87775<br>
> <a href="http://www.sumasoft.com" target="_blank">www.sumasoft.com</a><br>
> ------------------------------------------------------------------<br>
><br>
> ----- Original Message -----<br>
> From: "Andreas Ericsson" <<a href="mailto:ae@op5.se">ae@op5.se</a>><br>
> To: "Mangesh Dhamale" <<a href="mailto:mangesh.dhamale@sumasoft.net">mangesh.dhamale@sumasoft.net</a>><br>
> Cc: <<a href="mailto:nagios-users@lists.sourceforge.net">nagios-users@lists.sourceforge.net</a>><br>
> Sent: Monday, May 26, 2008 3:46 PM<br>
> Subject: Re: [Nagios-users] Can I configure my own shell scripts<br>
><br>
><br>
><br>
>> Mangesh Dhamale wrote:<br>
>><br>
>>> Hello Everyone,<br>
>>><br>
>>> I have one query, can I monitor my own shell scripts.<br>
>>><br>
>>><br>
>> Yes.<br>
>><br>
>> --<br>
>> Andreas Ericsson                   <a href="mailto:andreas.ericsson@op5.se">andreas.ericsson@op5.se</a><br>
>> OP5 AB                             <a href="http://www.op5.se" target="_blank">www.op5.se</a><br>
>> Tel: +46 8-230225                  Fax: +46 8-230231<br>
>><br>
>><br>
> ----------------------------------------------<br>
> Confidentiality Note: This e-mail message and any attachments to it are<br>
> intended only for the named recipients and may contain legally privileged<br>
> and/or confidential information. If you are not one of the intended<br>
> recipients, please forward this mail to <a href="mailto:abuse@sumasoft.net">abuse@sumasoft.net</a> and do not duplicate or forward this<br>
> e-mail message and immediately delete it from your computer.<br>
> ----------------------------------------------<br>
><br>
> -------------------------------------------------------------------------<br>
> This SF.net email is sponsored by: Microsoft<br>
> Defy all challenges. Microsoft(R) Visual Studio 2008.<br>
> <a href="http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/" target="_blank">http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/</a><br>
> _______________________________________________<br>
> Nagios-users mailing list<br>
> <a href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a><br>
> <a href="https://lists.sourceforge.net/lists/listinfo/nagios-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
> ::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<br>
> ::: Messages without supporting info will risk being sent to /dev/null<br>
><br>
<br>
-------------------------------------------------------------------------<br>
This SF.net email is sponsored by: Microsoft<br>
Defy all challenges. Microsoft(R) Visual Studio 2008.<br>
<a href="http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/" target="_blank">http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/</a><br>
_______________________________________________<br>
Nagios-users mailing list<br>
<a href="mailto:Nagios-users@lists.sourceforge.net">Nagios-users@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/nagios-users" target="_blank">https://lists.sourceforge.net/lists/listinfo/nagios-users</a><br>
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.<br>
::: Messages without supporting info will risk being sent to /dev/null<br>
</div></div></blockquote></div><br>