Re: [Nagios-users] Check Website Help

2012-08-03 Thread Assaf Flatto

On 03/08/12 14:49, Andrew Thompson wrote:


Hi all,

I have websites that I monitor.

Some require just a yes is it up or no its down by hitting the site 
and searching for text on it.


Others require the site to be logged into and trawled to test SQL 
backend so I need to provide it with a username/password.


I also want performance data as I have just started using PNP4Nagios.

I am using a custom written bash script at the moment, and this works 
fine, however it doesn't output any performance data.


I have looked at Webinject but this uses its own graphing tool 
(gnuplot) and to reduce confusuion I don't really want to run 2 
graphing tools.


So 2 questions:

1.Is there a plugin available that does all I need above?



look here http://exchange.nagios.org/


Or

2.Anybody point me in the right direction in how to add performance 
data to my already working bash script? (im not a programmer, however 
my collegue is!)




http://nagios.sourceforge.net/docs/nagioscore/3/en/pluginapi.html


Thanks in advance.


--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/


___
Nagios-users mailing list
Nagios-users@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


--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Nagios-users mailing list
Nagios-users@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

[Nagios-users] Check Website Help

2012-08-03 Thread Andrew Thompson
Hi all,

I have websites that I monitor.

Some require just a yes is it up or no its down by hitting the site and 
searching for text on it.

Others require the site to be logged into and trawled to test SQL backend so I 
need to provide it with a username/password.

I also want performance data as I have just started using PNP4Nagios.

I am using a custom written bash script at the moment, and this works fine, 
however it doesn't output any performance data.

I have looked at Webinject but this uses its own graphing tool (gnuplot) and to 
reduce confusuion I don't really want to run 2 graphing tools.

So 2 questions:


1.   Is there a plugin available that does all I need above?

Or


2.   Anybody point me in the right direction in how to add performance data 
to my already working bash script? (im not a programmer, however my collegue 
is!)



Thanks in advance.
--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Nagios-users mailing list
Nagios-users@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

[Nagios-users] SOLVED - Notification Issue - Only Executing One Method

2012-08-03 Thread Net Warrior
Sorry for the noise
The problem was that I have to include comma separated the notificatiob
method like this:

service_notification_commands   send-sms,notify-service-by-email

Thanks you very much

-- Forwarded message --
From: Net Warrior 
Date: 2012/8/3
Subject: Notification Issue - Only Executing One Method
To: nagios-users@lists.sourceforge.net


Hi there list.
I'm having an issue with the notifiactions, I 'm using
nagios-3.4.1-2.el6.x86_64, this is my configuration:



define contact{
contact_namenagiosadmin ; Short name of user
use generic-contact ; Inherit
default values from generic-contact template (defined above)
alias   Administrador Nagios; Full name
of user
host_notifications_enabled  1
service_notifications_enabled   1
service_notification_period 24x7
host_notification_period24x7
service_notification_optionsw,u,c,r
host_notification_options   d,u,r
service_notification_commands   send-sms
service_notification_commands   notify-service-by-email
host_notification_commands  notify-host-by-email
email   u...@domain.com
can_submit_commands 1
}

My aim with this configuration is to receive an SMS along with the email
notification, but only one of them is executed, with the configuration
above on the the sms is received
if I comment the send-sms method I receive the mail, but both enabled do
not work, I enabled some debug and there is no errors such as , cannot
execute one or another, in
the logs I only see that only one is executed but not both.

Any ideas what am I doing wrong? If you need more information just let me
know.

Thanks for your time and support
Best regards
--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Nagios-users mailing list
Nagios-users@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

[Nagios-users] Notification Issue - Only Executing One Method

2012-08-03 Thread Net Warrior
Hi there list.
I'm having an issue with the notifiactions, I 'm using
nagios-3.4.1-2.el6.x86_64, this is my configuration:



define contact{
contact_namenagiosadmin ; Short name of user
use generic-contact ; Inherit
default values from generic-contact template (defined above)
alias   Administrador Nagios; Full name
of user
host_notifications_enabled  1
service_notifications_enabled   1
service_notification_period 24x7
host_notification_period24x7
service_notification_optionsw,u,c,r
host_notification_options   d,u,r
service_notification_commands   send-sms
service_notification_commands   notify-service-by-email
host_notification_commands  notify-host-by-email
email   u...@domain.com
can_submit_commands 1
}

My aim with this configuration is to receive an SMS along with the email
notification, but only one of them is executed, with the configuration
above on the the sms is received
if I comment the send-sms method I receive the mail, but both enabled do
not work, I enabled some debug and there is no errors such as , cannot
execute one or another, in
the logs I only see that only one is executed but not both.

Any ideas what am I doing wrong? If you need more information just let me
know.

Thanks for your time and support
Best regards
--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Nagios-users mailing list
Nagios-users@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

[Nagios-users] R: R: R: R: check_memory does not work properly

2012-08-03 Thread Marco Borsani
Here it is.

 

./check_memory

 

NAME

  check_memory - custom script to check free memory (RAM) on SmartOS and
Linux machines

SYNOPSIS

  check_memory -w  -c  []

 

   -c, --critical 

  Output this help text

   -w, --warning  

  Output this help text

   -d, --debug

  Output useful development debug info

   -h, --help

  Output this help text

 

 

 

Da: Deborah Martin [mailto:deborah.mar...@kognitio.com] 
Inviato: giovedì 2 agosto 2012 17:02
A: Nagios Users List
Oggetto: Re: [Nagios-users] R: R: R: check_memory does not work properly

 

Can you run check_memory  plugin on the command line to get the full menu of
options available to the plugin and post it here. 

 

Regards,

Deborah 

 

 

From: Marco Borsani [mailto:m.bors...@it.net] 
Sent: 02 August 2012 15:28
To: 'Nagios Users List'
Subject: [Nagios-users] R: R: R: check_memory does not work properly

 

1)  Nagios user

2)  Yes

3)  Which details ? the point is that the plugin work correctly on
command line, but not on web gui…

Command line out à OK +  + exit status 0

Web gui output à WARNING + (null message) + exit status 1

Log file à SERVICE ALERT: ; ;WARNING;HARD;3;(null)

 

Regards

 

Da: James Osbourn [mailto:james.osbo...@citrix.com] 
Inviato: giovedì 2 agosto 2012 15:58
A: Nagios Users List
Oggetto: Re: [Nagios-users] R: R: check_memory does not work properly

 

What user is your Nagios server running as?  Is it the same as the user that
you are using on the command line?  Could you post more details about the
exact check_memory command that you are using, there are several of them out
there.  The output you are getting from Nagios, is this on the web gui, or
in one of the log files.

 

It could be many things related to the check scripts itself, who you are
running as where you are running the command.  The command line is not
always the same as when the server executes.

 

James

 

From: Marco Borsani [mailto:m.bors...@it.net] 
Sent: 02 August 2012 14:48
To: 'Nagios Users List'
Subject: [Nagios-users] R: R: check_memory does not work properly

 

No idea?

 

Regards

 

Da: Marco Borsani [mailto:m.bors...@it.net] 
Inviato: mercoledì 1 agosto 2012 09:19
A: 'Nagios Users List'
Oggetto: [Nagios-users] R: check_memory does not work properly

 

Commands.cfg

 

# 'check_local_memory' command definition

define command{

command_namecheck_local_memory

command_line$USER1$/check_memory -w $ARG1$ -c $ARG2$

}

 

Services.cfg

 

define service{

use   active-service


host_name   

service_description   check_local_memory

check_command   check_local_memory!10%!5%

max_check_attempts   3

normal_check_interval 5

retry_check_interval 1

check_period   24x7

notification_interval  120

notification_period24x7

notification_options  w,u,c,r

notifications_enabled  1

contact_groups   CG_admin

}

 

 

>From line command:

$> ./check_memory -w 10% -c 5%

OK - free memory is 27% which is within expected threshold|
mem=27;10;5;0;100

 

Regards

 

 

Da: Morris, Patrick [mailto:patrick.mor...@hp.com] 
Inviato: martedì 31 luglio 2012 23:24
A: nagios-users@lists.sourceforge.net
Oggetto: Re: [Nagios-users] check_memory does not work properly

 

Posting your check configuration is really helpful in cases like this.  It’s
almost impossible to give a good answer without knowing how you’ve set the
check up.

 

From: Marco Borsani [mailto:m.bors...@it.net] 
Sent: Tuesday, July 31, 2012 6:52 AM
To: NAGIOS
Subject: [Nagios-users] check_memory does not work properly

 

Hi all

 

 

I am using a simple plug-in to check the nagios server memory.

 

When I run it like user Nagios, it works perfectly. I see this output:

OK - free memory is 40% which is within expected threshold|
mem=40;10;5;0;100

 

When I run it with Nagios program I receive this notification:

 

…..

Command: check_local_memory

State:   WARNING

Message:(null)

….

 

 

Any idea ?




This e-mail and any files transmitted with it are confidential and intended
solely for the use of the individual or entity to whom they are addressed.
If you are not the intended recipient, please delete this e-mail
immediately. Any unauthorised distribution or copying is strictly
prohibited.

Whilst Kognitio endeavours to prevent the transmission of viruses via
e-mail, we cannot guarantee that any e-mail or attachment is free from
computer viruses and you are strongly advised to undertake your own
anti-virus precautions. Kognitio grants no warranties regarding performance,
use or quality of any e-mail or attachment and undertakes no liability for

[Nagios-users] R: R: R: check_memory does not work properly

2012-08-03 Thread Marco Borsani
?!?!?

 

Because not all the servers have same threshold

 

By the way ..nothing will change putting ARGS in commands.cfg

 

 

 

Da: Edwin Zoeller [mailto:edwin.zoel...@ama-assn.org] 
Inviato: giovedì 2 agosto 2012 17:06
A: Nagios Users List
Oggetto: Re: [Nagios-users] R: R: check_memory does not work properly

 

Why don’t you specify the ARGS in the commands.cfg file?

 

i.e.

 

Commands.cfg

 

# 'check_local_memory' command definition

define command{

command_namecheck_local_memory

command_line$USER1$/check_memory -w 10% -c 5%

}

 

Services.cfg

 

define service{

use   active-service


host_name   

service_description   check_local_memory

check_command   check_local_memory

max_check_attempts   3

normal_check_interval 5

retry_check_interval 1

check_period   24x7

notification_interval  120

notification_period24x7

notification_options  w,u,c,r

notifications_enabled  1

contact_groups   CG_admin

}

 

 

 

From: Marco Borsani [mailto:m.bors...@it.net] 
Sent: Thursday, August 02, 2012 8:48 AM
To: 'Nagios Users List'
Subject: [Nagios-users] R: R: check_memory does not work properly

 

No idea?

 

Regards

 

Da: Marco Borsani [mailto:m.bors...@it.net] 
Inviato: mercoledì 1 agosto 2012 09:19
A: 'Nagios Users List'
Oggetto: [Nagios-users] R: check_memory does not work properly

 

Commands.cfg

 

# 'check_local_memory' command definition

define command{

command_namecheck_local_memory

command_line$USER1$/check_memory -w $ARG1$ -c $ARG2$

}

 

Services.cfg

 

define service{

use   active-service


host_name   

service_description   check_local_memory

check_command   check_local_memory!10%!5%

max_check_attempts   3

normal_check_interval 5

retry_check_interval 1

check_period   24x7

notification_interval  120

notification_period24x7

notification_options  w,u,c,r

notifications_enabled  1

contact_groups   CG_admin

}

 

 

>From line command:

$> ./check_memory -w 10% -c 5%

OK - free memory is 27% which is within expected threshold|
mem=27;10;5;0;100

 

Regards

 

 

Da: Morris, Patrick [mailto:patrick.mor...@hp.com] 
Inviato: martedì 31 luglio 2012 23:24
A: nagios-users@lists.sourceforge.net
Oggetto: Re: [Nagios-users] check_memory does not work properly

 

Posting your check configuration is really helpful in cases like this.  It’s
almost impossible to give a good answer without knowing how you’ve set the
check up.

 

From: Marco Borsani [mailto:m.bors...@it.net] 
Sent: Tuesday, July 31, 2012 6:52 AM
To: NAGIOS
Subject: [Nagios-users] check_memory does not work properly

 

Hi all

 

 

I am using a simple plug-in to check the nagios server memory.

 

When I run it like user Nagios, it works perfectly. I see this output:

OK - free memory is 40% which is within expected threshold|
mem=40;10;5;0;100

 

When I run it with Nagios program I receive this notification:

 

…..

Command: check_local_memory

State:   WARNING

Message:(null)

….

 

 

Any idea ?

--
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/___
Nagios-users mailing list
Nagios-users@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