how to monitor databases on windows through nagios`
Jon Angliss
jon at netdork.net
Sat Sep 27 22:35:21 CEST 2008
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Thu, 18 Sep 2008 18:55:03 +0530, asam30 at gmail.com wrote:
>Hi All,
>
>I've installed nagios 3.0 server on red hat linux and monitoring windows
>boxes by installng nsclient++ add on. I was able to install and configure
>fine on win box, now all c drive and memory paramters are showing on nagios
>interface for windows. my question is how do we monitor oracle database and
>it's services on windows box through nsclient?
How good are you at writing scripts? I'd imagine it probably wouldn't
be too difficult to cobble together a small batch script that calls
the oracle client to do some tests. Or, even writing something in VBS
to build a client connection using ODBC.
I don't have Oracle, and my VBS is rusty... but something like this
would probably be a basis:
<%
On Error Goto ErrHandler
ConStr = "DRIVER={Microsoft ODBC for Oracle};SERVER=oracle_server;User
Id=user;Password=password;"
set Conn = CreateObject("ADODB.Connection")
Conn.Open ConStr
ErrHandler:
Print "Something Bad Happened"
exit 1
%>
Then you call that script from nsclient++..
A more complex example can be found here [1]. But googling around
you'll probably find some easy to understand examples to get you
going. If you read over the check_oracle client, you should be able
to see what it's doing, and duplicate the behavior in the script.
That is assuming the code cannot be "ported" to windows.
[1]:
http://www.idevelopment.info/data/Oracle/DBA_scripts/WINDOWS_Shell_Scr
ipts/oracle_ADO_example.vbs
- --
Jon Angliss
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32) - GPGshell v3.64
iEYEARECAAYFAkjemP4ACgkQK4PoFPj9H3NQnACggWkyNjuQEG98b9SbUgtp81zz
5hcAoNDj4O9d/R1ORoD5TetsDbnajUNe
=iHS4
-----END PGP SIGNATURE-----
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
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