Search Exchange
Search All Sites
Nagios Live Webinars
Let our experts show you how Nagios can help your organization.Login
Directory Tree
check_db2
1.0
2013-06-25
- Nagios 3.x
GPL
41814
File | Description |
---|---|
check_db2 | Script for doing the monitoring work |
db2.check.c | C file for executing the script with suid |
Meet The New Nagios Core Services Platform
Built on over 25 years of monitoring experience, the Nagios Core Services Platform provides insightful monitoring dashboards, time-saving monitoring wizards, and unmatched ease of use. Use it for free indefinitely.
Monitoring Made Magically Better
- Nagios Core on Overdrive
- Powerful Monitoring Dashboards
- Time-Saving Configuration Wizards
- Open Source Powered Monitoring On Steroids
- And So Much More!
Requires root permissions, so I added db2.check.c that is a wrapper.
I'm no db2 expert, but I'm an IBM WebSphere Portal administrator for a large environment (well mid 50-100 hosts) and I had a lot of PMRs solved by looking into db2.
This script is helping me track db2 instances and dbs, further functionality will come with further problems, so I hope that further functionality comes from other community members ;-)
This script is intended to be used with some nice graphing software (like nagiosgraph) and be executed by nrpe.
File 1 (check_db2) is the script that runs all the functionality, it will require:
* root permission
* some space on /tmp
* some spaces on /var
As i know is MAD to execute nrpe with root permissions, I attached File 2 (db2.check.c). This file must be owned by root, must be readable and executable by the nrpe/nagios/whatever user and have the suid flat (+s) this will overcome the need of the shell to be executed by the root user.
You can change the path of the script (on db2.check.c) but check_db2 is intended to be on /usr/local/nagios.
Compiling db2.check.c is as easy as:
gcc db2.check.c -o db2.check
This script is helping me track db2 instances and dbs, further functionality will come with further problems, so I hope that further functionality comes from other community members ;-)
This script is intended to be used with some nice graphing software (like nagiosgraph) and be executed by nrpe.
File 1 (check_db2) is the script that runs all the functionality, it will require:
* root permission
* some space on /tmp
* some spaces on /var
As i know is MAD to execute nrpe with root permissions, I attached File 2 (db2.check.c). This file must be owned by root, must be readable and executable by the nrpe/nagios/whatever user and have the suid flat (+s) this will overcome the need of the shell to be executed by the root user.
You can change the path of the script (on db2.check.c) but check_db2 is intended to be on /usr/local/nagios.
Compiling db2.check.c is as easy as:
gcc db2.check.c -o db2.check
Reviews (1)
byangoca, July 3, 2013
I have seen the code, and it is very interesting, because it captures information from many different DB2 aspects at the same time.
However, it uses root in order to be executed, and it is not always possible. DB2 relies in OS security, and there can be other ways to get the information. No need to do 'su - instUser'
Very interesting queries, however, you need at least DB2 9.7 FP 6
However, it uses root in order to be executed, and it is not always possible. DB2 relies in OS security, and there can be other ways to get the information. No need to do 'su - instUser'
Very interesting queries, however, you need at least DB2 9.7 FP 6