[Multiple Problems]

Shoaibi iknewitalready at gmail.com
Sun Jun 22 06:57:44 CEST 2008


@ Jay R. Ashworth:
First, thanks for replying, second, sorry i was unable to explain my
problem, third, i hope this post will clearly show what is the
problem.

+++++++++++++++
Details of My Script
+++++++++++++++

Its a Java Servlet (web application) that will show a list of
checkboxed publicly available services that are installed on a system
to the visitor. like:

<-------------------------------------------------------------------------------------------
Please select a service to be monitored on this machine:

[ ] SSHD
[ ] HTTPD

[[ Submit ]]
------------------------------------------------------------------------------------------>


(Please note that there are other publicly avialable services as well,
but in our case they are not installed. So this means; only listing
the services that are installed and publicly available for nagios to
monitor)

After this list has been generated, user will check the services in
which he is interested in e.g. to be monitored using nagios. So:

<------------------------------------------------------------------------------------------
Please select a service to be monitored on the machine:

[x] SSHD
[ ] HTTPD


[[ Submit ]]
------------------------------------------------------------------------------------------>


Now what my script would do is that it will create the "correct
syntaxed statements" for the marked services and insert them in the
respective files. Suppose SSHD is marked, my script will do this after
the user pushes the submit button:

<------------------------------------------------------------------------------------------
define service{
	use		generic-service
	host_name		localhosthost ; this host will be already defined in the hosts file
	service_description	SSH
	check_command	check_ssh
	}
------------------------------------------------------------------------------------------>

And add it to commands.cfg file.

So you see that i am trying to provide a GUI version with checkboxed
list for the services which:
1. are installed
2. are publicly available

and letting user choose which he want to monitor and based on that
adding the details to commands.cfg file.

+++++++
Problem
+++++++

That were my needs. My problem is how can i list the installed and
publicly available services on a nix? Can nagios tell me that on my
system which services are publicly available for monitoring? If not,
then is there any other method?

++++++++++++++++++++++
Methods already known to me
++++++++++++++++++++++

1. Check distribution by:

lsbrelease -a

2. Categorized distribution as debian or red hat based.
3. based upon the categorization run

dpkg -l

or

rpm -qa

and

grep 'SERVICE_NAME_HERE'

where for apache, on debian SERVICE_NAME_HERE=apache, and for redhat
based one its httpd

Thanks for reading the post.
Bye

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
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