Strange think

Tom Nail tom.nail at amd.com
Fri Jan 11 18:41:37 CET 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


Fabiano Martins wrote:
| Hi all!!
|
| I have a strange issue here with my nagios. Let me try to explain...
|
| I have some web services to check and when I run the command from
| console to test two diferent status of these services (UP or DOWN) I
| receive the correct answer from remote application. Let me put the
| command here:
|
| ./usr/local/nagios/libexec/check_http -H www.somehost.com.br
| <http://www.somehost.com.br/> -u /heartbeat.asmx/Web -s '<boolean
| xmlns=" http://www.somehost.com.br/">true</boolean>'
| <http://www.somehost.com.br/%22%3Etrue%3C/boolean%3E'>
|
| As the check_http says, I have to use check_http -H <vhost> -u URL path
| that I wan to check on specified host and -s <string> that I expect to
| be returned to me.
|
| Ok!
|
| I run this command from console and everything goes fine. To test, I've
| changed the expected string from true to false, and the answer received
| after running the command from console changes to "DOWN String not found".
|
| The problem is, when I put it into service.cfg for nagios run the
| command, I've realized that nagios is not threating the return. If the
| service is down, nagios keeps showing me that the service is OK.
|
| In command.cfg file, I've changed the line check_http command to add one
| more argument that I need.
|
| The default is check_http -H $HOSTADDRESS$ $ARG1$.
|
| I've changed it to check_http -H $HOSTADDRESS$ $ARG1$ $ARG2$

I would probably change this to "check_http -H $HOSTADDRESS$ -u $ARG1$
- -s $ARG2$"

and change the services.cfg to:

check_http!www.somehost.com.br!/heartbeat.asmx/Web!'<boolean
xmlns="http://www.somehost.com.br/">true</boolean>'
|
| In services.cfg file I put check_http!www.somehost.com.br -u
| /heartbeat.asmx/Web!'<boolean
| xmlns="http://www.somehost.com.br/">true</boolean>'
| <http://www.somehost.com.br/%22%3Etrue%3C/boolean%3E'>
|
| I think that nagios is doesn't recognizing the sintax.
|
| My queustino is...
|
| In the lines that I put above, Is there anything I am missing?
|
| Regards,
|
| Fabiano Martins

I'm thinking that the parser might be getting confused with the "-u"
option and/or the whitespace and is ignoring the string check. I would
also suggest posting in simple text to mailing lists, especially when
you paste configurations, since  HTML output can confuse the actual
command you are trying to show.

Hope this Helps,

- -=Tom Nail
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHh6pR1zsLRjt/NQ0RAubdAJ9uZVpTVgFgaSjFpGl8rTHCMhXk6wCfcc1m
VvYva2NqkByhsYwV2rF+5aU=
=TUvJ
-----END PGP SIGNATURE-----



-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace
_______________________________________________
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