Xymon Mailing List Archive search

Solaris 10 service monitoring

13 messages in this thread

list Bob Gordon · Thu, 31 Aug 2006 16:47:28 -0700 ·
Hello -

I'm running into an issue where I need to monitor the individual services (
svcs -a ) instead of the processes (ps -ef) on multiple Solaris 10 clients.
I didn't see anything in the man pages about it (although I may have missed
it) so I was wondering if anyone has been able to set Hobbit up to do so?

Sample output from svcs -a

$ svcs -a |head -20
STATE          STIME    FMRI
legacy_run     Jul_28   lrc:/etc/rcS_d/S00umask_sh
legacy_run     Jul_28   lrc:/etc/rcS_d/S29wrsmcfg
legacy_run     Jul_28   lrc:/etc/rcS_d/S51installupdates
disabled       Jul_28   svc:/system/sysidtool:net
disabled       Jul_28   svc:/system/sysidtool:system
disabled       Jul_28   svc:/network/rpc/keyserv:default
disabled       Jul_28   svc:/network/rpc/nisplus:default
disabled       Jul_28   svc:/network/nis/server:default
online         Jul_28   svc:/milestone/multi-user-server:default
online         Jul_28   svc:/system/zones:default
online         Aug_15   svc:/application/hobbit:default

I need to be able to alarm if zones goes offline or if nisplus goes online
(for example)...

Thanks!

-- 
--==[ Bob Gordon ]==--
list T.J. Yang · Thu, 31 Aug 2006 19:34:36 -0500 ·
I am using hobbitping and I am getting 43 seconds for 833 hosts pings.

PING test completed (833 hosts)          1157070413.072972         42.444355

Is there a way to improve number if  parallel pings by hobbitping  ?
my test hobbit server looks very low on load avgerage.

thanks for your pointer.

T.J. Yang
list T.J. Yang · Thu, 31 Aug 2006 19:53:47 -0500 ·
quoted from T.J. Yang
From: "T.J. Yang" <user-8e841282cda5@xymon.invalid>
Reply-To: user-ae9b8668bcde@xymon.invalid
To: user-ae9b8668bcde@xymon.invalid
Subject: [hobbit] How to shorten the ping time ?
Date: Thu, 31 Aug 2006 19:34:36 -0500

I am using hobbitping and I am getting 43 seconds for 833 hosts pings.

PING test completed (833 hosts)          1157070413.072972         
42.444355

Is there a way to improve number if  parallel pings by hobbitping  ?
Hmm, Execuse the bad sentence, I was attempting to type following,

Is there a way to increase numbers of parallel pings by hobbitping ?

tj
quoted from T.J. Yang
my test hobbit server looks very low on load avgerage.

thanks for your pointer.

T.J. Yang

list T.J. Yang · Thu, 31 Aug 2006 20:51:30 -0500 ·
Looks like a ext module need to be writting for hobbit, and I propose using smf instead svcs(windows used it already).


tj
quoted from Bob Gordon
  ----- Original Message ----- 
  From: Bob Gordon 
  To: user-ae9b8668bcde@xymon.invalid 
  Sent: Thursday, August 31, 2006 6:47 PM
  Subject: [hobbit] Solaris 10 service monitoring


  Hello -

  I'm running into an issue where I need to monitor the individual services ( svcs -a ) instead of the processes (ps -ef) on multiple Solaris 10 clients.  I didn't see anything in the man pages about it (although I may have missed it) so I was wondering if anyone has been able to set Hobbit up to do so? 

  Sample output from svcs -a

  $ svcs -a |head -20
  STATE          STIME    FMRI
  legacy_run     Jul_28   lrc:/etc/rcS_d/S00umask_sh
  legacy_run     Jul_28   lrc:/etc/rcS_d/S29wrsmcfg
  legacy_run     Jul_28   lrc:/etc/rcS_d/S51installupdates 
  disabled       Jul_28   svc:/system/sysidtool:net
  disabled       Jul_28   svc:/system/sysidtool:system
  disabled       Jul_28   svc:/network/rpc/keyserv:default
  disabled       Jul_28   svc:/network/rpc/nisplus:default 
  disabled       Jul_28   svc:/network/nis/server:default
  online         Jul_28   svc:/milestone/multi-user-server:default
  online         Jul_28   svc:/system/zones:default
  online         Aug_15   svc:/application/hobbit:default 

  I need to be able to alarm if zones goes offline or if nisplus goes online (for example)...

  Thanks!

  -- 
  --==[ Bob Gordon ]==--
list Andy France · Fri, 1 Sep 2006 14:02:30 +1200 ·

"T.J. Yang" wrote on 01/09/2006 01:51:30 p.m.:
quoted from T.J. Yang
Looks like a ext module need to be writting for hobbit,
and I propose using smf instead svcs(windows used it already).
Regarding point one, an external script seems like the best idea rather
than Henrik maintaining Solaris specific functions in the hobbit client
(unless his to do list is looking a bit thin ;-) )

However I disagree with your second point - if the "svcs" column indicates
service status on Windows, why can't it indicate services on Solaris too?
You're hardly likely to run both Sun and Windows services on the same
(virtual) host, and it keeps the column numbers down on pages that might
show both types of server.

Andy.
quoted from T.J. Yang
tj
----- Original Message -----
From: Bob Gordon
To: user-ae9b8668bcde@xymon.invalid
Sent: Thursday, August 31, 2006 6:47 PM
Subject: [hobbit] Solaris 10 service monitoring

Hello -

I'm running into an issue where I need to monitor the individual
services ( svcs -a ) instead of the processes (ps -ef) on multiple
Solaris 10 clients.  I didn't see anything in the man pages about it
(although I may have missed it) so I was wondering if anyone has
been able to set Hobbit up to do so?

Sample output from svcs -a

$ svcs -a |head -20
STATE          STIME    FMRI
legacy_run     Jul_28   lrc:/etc/rcS_d/S00umask_sh
legacy_run     Jul_28   lrc:/etc/rcS_d/S29wrsmcfg
legacy_run     Jul_28   lrc:/etc/rcS_d/S51installupdates
disabled       Jul_28   svc:/system/sysidtool:net
disabled       Jul_28   svc:/system/sysidtool:system
disabled       Jul_28   svc:/network/rpc/keyserv:default
disabled       Jul_28   svc:/network/rpc/nisplus:default
disabled       Jul_28   svc:/network/nis/server:default
online         Jul_28   svc:/milestone/multi-user-server:default
online         Jul_28   svc:/system/zones:default
online         Aug_15   svc:/application/hobbit:default

I need to be able to alarm if zones goes offline or if nisplus goes
online (for example)...

Thanks!

--
--==[ Bob Gordon ]==--

#####################################################################################

This email is intended for the person to whom it is addressed
only. If you are not the intended recipient, do not read, copy
or use the contents in any way. The opinions expressed may not
necessarily reflect those of ZESPRI Group of Companies ('ZESPRI').

While every effort has been made to verify the information
contained herein, ZESPRI does not make any representations 
as to the accuracy of the information or to the performance
of any data, information or the products mentioned herein.
ZESPRI will not accept liability for any losses, damage or
consequence, however, resulting directly or indirectly from
the use of this e-mail/attachments.
#####################################################################################
list T.J. Yang · Thu, 31 Aug 2006 21:15:39 -0500 ·
quoted from Andy France
"T.J. Yang" wrote on 01/09/2006 01:51:30 p.m.:
Looks like a ext module need to be writting for hobbit,
and I propose using smf instead svcs(windows used it already).
Regarding point one, an external script seems like the best idea rather
than Henrik maintaining Solaris specific functions in the hobbit client
(unless his to do list is looking a bit thin ;-) )

However I disagree with your second point - if the "svcs" column indicates
service status on Windows, why can't it indicate services on Solaris too?
You're hardly likely to run both Sun and Windows services on the same
(virtual) host, and it keeps the column numbers down on pages that might
show both types of server.
So if you click on svcs column title link on a hobbit page to find out the
definition of svcs, which url it should link to  :)

I think it is best to have unique column name. it Solaris 10's case it has 
smf
to fall back on, giving up svcs to windows camp looks ok me.

tj
quoted from Andy France
Andy.
tj
----- Original Message -----
From: Bob Gordon
To: user-ae9b8668bcde@xymon.invalid
Sent: Thursday, August 31, 2006 6:47 PM
Subject: [hobbit] Solaris 10 service monitoring

Hello -

I'm running into an issue where I need to monitor the individual
services ( svcs -a ) instead of the processes (ps -ef) on multiple
Solaris 10 clients.  I didn't see anything in the man pages about it
(although I may have missed it) so I was wondering if anyone has
been able to set Hobbit up to do so?

Sample output from svcs -a

$ svcs -a |head -20
STATE          STIME    FMRI
legacy_run     Jul_28   lrc:/etc/rcS_d/S00umask_sh
legacy_run     Jul_28   lrc:/etc/rcS_d/S29wrsmcfg
legacy_run     Jul_28   lrc:/etc/rcS_d/S51installupdates
disabled       Jul_28   svc:/system/sysidtool:net
disabled       Jul_28   svc:/system/sysidtool:system
disabled       Jul_28   svc:/network/rpc/keyserv:default
disabled       Jul_28   svc:/network/rpc/nisplus:default
disabled       Jul_28   svc:/network/nis/server:default
online         Jul_28   svc:/milestone/multi-user-server:default
online         Jul_28   svc:/system/zones:default
online         Aug_15   svc:/application/hobbit:default

I need to be able to alarm if zones goes offline or if nisplus goes
online (for example)...

Thanks!

--
--==[ Bob Gordon ]==--

#####################################################################################

This email is intended for the person to whom it is addressed
only. If you are not the intended recipient, do not read, copy
or use the contents in any way. The opinions expressed may not
necessarily reflect those of ZESPRI Group of Companies ('ZESPRI').

While every effort has been made to verify the information
contained herein, ZESPRI does not make any representations
as to the accuracy of the information or to the performance
of any data, information or the products mentioned herein.
ZESPRI will not accept liability for any losses, damage or
consequence, however, resulting directly or indirectly from
the use of this e-mail/attachments.
#####################################################################################

list Andy France · Fri, 1 Sep 2006 14:31:43 +1200 ·

"T.J. Yang" wrote on 01/09/2006 02:15:39 p.m.:
quoted from T.J. Yang
"T.J. Yang" wrote on 01/09/2006 01:51:30 p.m.:
Looks like a ext module need to be writting for hobbit,
and I propose using smf instead svcs(windows used it already).
Regarding point one, an external script seems like the best idea rather
than Henrik maintaining Solaris specific functions in the hobbit client
(unless his to do list is looking a bit thin ;-) )

However I disagree with your second point - if the "svcs" column
indicates
service status on Windows, why can't it indicate services on Solaris
too?
You're hardly likely to run both Sun and Windows services on the same
(virtual) host, and it keeps the column numbers down on pages that
might
show both types of server.
So if you click on svcs column title link on a hobbit page to find out
the
definition of svcs, which url it should link to  :)
"The svcs column shows the status of select system services that are
expected to run on the system"

Sounds generic enough for me!  Of course, I'm not planning on submitting
the ext script myself any time soon, so I'll leave it up to "someone else"
to decide.

And BTW... reading the documentation?  What were you thinking!
quoted from T.J. Yang
I think it is best to have unique column name. it Solaris 10's case it
has
smf
to fall back on, giving up svcs to windows camp looks ok me.

tj
Andy.
tj
----- Original Message -----
From: Bob Gordon
Sent: Thursday, August 31, 2006 6:47 PM
Subject: [hobbit] Solaris 10 service monitoring

Hello -

I'm running into an issue where I need to monitor the individual
services ( svcs -a ) instead of the processes (ps -ef) on multiple
Solaris 10 clients.  I didn't see anything in the man pages about it
(although I may have missed it) so I was wondering if anyone has
been able to set Hobbit up to do so?

Sample output from svcs -a

$ svcs -a |head -20
STATE          STIME    FMRI
legacy_run     Jul_28   lrc:/etc/rcS_d/S00umask_sh
legacy_run     Jul_28   lrc:/etc/rcS_d/S29wrsmcfg
legacy_run     Jul_28   lrc:/etc/rcS_d/S51installupdates
disabled       Jul_28   svc:/system/sysidtool:net
disabled       Jul_28   svc:/system/sysidtool:system
disabled       Jul_28   svc:/network/rpc/keyserv:default
disabled       Jul_28   svc:/network/rpc/nisplus:default
disabled       Jul_28   svc:/network/nis/server:default
online         Jul_28   svc:/milestone/multi-user-server:default
online         Jul_28   svc:/system/zones:default
online         Aug_15   svc:/application/hobbit:default

I need to be able to alarm if zones goes offline or if nisplus goes
online (for example)...

Thanks!

--
--==[ Bob Gordon ]==--

#####################################################################################

This email is intended for the person to whom it is addressed
only. If you are not the intended recipient, do not read, copy
or use the contents in any way. The opinions expressed may not
necessarily reflect those of ZESPRI Group of Companies ('ZESPRI').

While every effort has been made to verify the information
contained herein, ZESPRI does not make any representations 
as to the accuracy of the information or to the performance
of any data, information or the products mentioned herein.
ZESPRI will not accept liability for any losses, damage or
consequence, however, resulting directly or indirectly from
the use of this e-mail/attachments.
#####################################################################################
list T.J. Yang · Thu, 31 Aug 2006 21:41:50 -0500 ·

I like to display hobbit configuration file also, where can I find this 
script ?

http://www.hswn.dk/hobbit-cgi/viewconf.sh


Regards

tj
list T.J. Yang · Thu, 31 Aug 2006 21:54:21 -0500 ·
quoted from Andy France
From: Andy France <user-ee2a9e4eaf57@xymon.invalid>
Reply-To: user-ae9b8668bcde@xymon.invalid
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] Solaris 10 service monitoring
Date: Fri, 1 Sep 2006 14:31:43 +1200


"T.J. Yang" wrote on 01/09/2006 02:15:39 p.m.:
"T.J. Yang" wrote on 01/09/2006 01:51:30 p.m.:
Looks like a ext module need to be writting for hobbit,
and I propose using smf instead svcs(windows used it already).
Regarding point one, an external script seems like the best idea 
rather
than Henrik maintaining Solaris specific functions in the hobbit 
client
(unless his to do list is looking a bit thin ;-) )

However I disagree with your second point - if the "svcs" column
indicates
service status on Windows, why can't it indicate services on Solaris
too?
You're hardly likely to run both Sun and Windows services on the same
(virtual) host, and it keeps the column numbers down on pages that
might
show both types of server.
So if you click on svcs column title link on a hobbit page to find out
the
definition of svcs, which url it should link to  :)
"The svcs column shows the status of select system services that are
expected to run on the system"
I doubled checked at
http://www.hswn.dk/hobbit-cgi/hobbitcolumn.sh?svcs
quoted from Andy France
Sounds generic enough for me!  Of course, I'm not planning on submitting
the ext script myself any time soon, so I'll leave it up to "someone else"
to decide.
Agree, the person spent the effort have the privilage to decide.
And BTW... reading the documentation?  What were you thinking!
ok, thanks for waking my up. I was thinking of svc definition from bb 
server.

svcs
The svcs column denotes the svcs check performed periodically (on 
NT/W2K/W2003). This test verifies that the defined services in bbntcfg.exe 
are running/stopped.
signature

I think it is best to have unique column name. it Solaris 10's case it
has
smf
to fall back on, giving up svcs to windows camp looks ok me.

tj
Andy.
tj
----- Original Message -----

quoted from Bob Gordon
From: Bob Gordon
Sent: Thursday, August 31, 2006 6:47 PM
Subject: [hobbit] Solaris 10 service monitoring

Hello -

I'm running into an issue where I need to monitor the individual
services ( svcs -a ) instead of the processes (ps -ef) on multiple
Solaris 10 clients.  I didn't see anything in the man pages about it
(although I may have missed it) so I was wondering if anyone has
been able to set Hobbit up to do so?

Sample output from svcs -a

$ svcs -a |head -20
STATE          STIME    FMRI
legacy_run     Jul_28   lrc:/etc/rcS_d/S00umask_sh
legacy_run     Jul_28   lrc:/etc/rcS_d/S29wrsmcfg
legacy_run     Jul_28   lrc:/etc/rcS_d/S51installupdates
disabled       Jul_28   svc:/system/sysidtool:net
disabled       Jul_28   svc:/system/sysidtool:system
disabled       Jul_28   svc:/network/rpc/keyserv:default
disabled       Jul_28   svc:/network/rpc/nisplus:default
disabled       Jul_28   svc:/network/nis/server:default
online         Jul_28   svc:/milestone/multi-user-server:default
online         Jul_28   svc:/system/zones:default
online         Aug_15   svc:/application/hobbit:default

I need to be able to alarm if zones goes offline or if nisplus goes
online (for example)...

Thanks!

--
--==[ Bob Gordon ]==--

#####################################################################################

This email is intended for the person to whom it is addressed
only. If you are not the intended recipient, do not read, copy
or use the contents in any way. The opinions expressed may not
necessarily reflect those of ZESPRI Group of Companies ('ZESPRI').

While every effort has been made to verify the information
contained herein, ZESPRI does not make any representations
as to the accuracy of the information or to the performance
of any data, information or the products mentioned herein.
ZESPRI will not accept liability for any losses, damage or
consequence, however, resulting directly or indirectly from
the use of this e-mail/attachments.
#####################################################################################

list Henrik Størner · Fri, 1 Sep 2006 07:36:08 +0200 ·
quoted from T.J. Yang
On Thu, Aug 31, 2006 at 07:34:36PM -0500, T.J. Yang wrote:
I am using hobbitping and I am getting 43 seconds for 833 hosts pings.

PING test completed (833 hosts)          1157070413.072972         42.444355

Is there a way to improve number if  parallel pings by hobbitping  ?
my test hobbit server looks very low on load avgerage.
Network tests rarely put much load on your box, they spend most of their
time waiting for the remote server to respond.

You can probably increase the max. packets/second from the default (50)
to e.g. 200 or 500. The risk in doing that is that you might overload
some of the network components along the way to the server, and ICMP
packets are among the first to be discarded if a router sees more
traffic than it can handle. So there's a higher risk of getting false
alerts the higher you go with the packet rate.


Regards,
Henrik
list Henrik Størner · Fri, 1 Sep 2006 07:45:06 +0200 ·
quoted from T.J. Yang
On Thu, Aug 31, 2006 at 09:41:50PM -0500, T.J. Yang wrote:
I like to display hobbit configuration file also, where can I find this 
script ?

http://www.hswn.dk/hobbit-cgi/viewconf.sh
It's my highly guarded secret intellectual property :-)

#!/bin/sh

echo "Content-type: text/plain"
echo ""

REQ="`/usr/local/bin/safequery`"

if [ "$REQ" = "alert" ]
then
   cat /etc/hobbit/hobbit-alerts.cfg
elif [ "$REQ" = "client" ]
then
   cat /etc/hobbit/hobbit-clients.cfg
elif [ "$REQ" = "clientlocal" ]
then
   cat /etc/hobbit/client-local.cfg
elif [ "$REQ" = "server" ]
then
   cat /etc/hobbit/hobbitserver.cfg
elif [ "$REQ" = "launch" ]
then
   cat /etc/hobbit/hobbitlaunch.cfg
elif [ "$REQ" = "graph" ]
then
   cat /etc/hobbit/hobbitgraph.cfg
else
   bbcmd bbhostshow
fi

exit 0


The "safequery" utility just scans the QUERY_STRING environment
and if it only contains characters that are "safe" in a shell script, it
prints out the QUERY_STRING value. This is something I wrote years ago
to make this kind of quick-and-dirty CGI scripts safer to use.

#include <stdio.h>
#include <string.h>
#include <stdlib.h>

char *safechars="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789.-_+?~=";

int main(int argc, char *argv[])
{
    unsigned char *querystring;
    unsigned char *p;

    querystring = getenv("QUERY_STRING");
    if (!querystring) {
       return 0;
    };


    for (p=querystring; (*p); p++) {
      if (!strchr(safechars, *p)) {
         return 1;
      }
    }

    printf("%s\n", querystring);
    return 0;
}


Regards,
Henrik
list T.J. Yang · Fri, 01 Sep 2006 05:30:54 -0500 ·
quoted from Henrik Størner
From: user-ce4a2c883f75@xymon.invalid (Henrik Stoerner)
Reply-To: user-ae9b8668bcde@xymon.invalid
To: user-ae9b8668bcde@xymon.invalid
Subject: Re: [hobbit] How to shorten the ping time ?
Date: Fri, 1 Sep 2006 07:36:08 +0200

On Thu, Aug 31, 2006 at 07:34:36PM -0500, T.J. Yang wrote:
I am using hobbitping and I am getting 43 seconds for 833 hosts pings.

PING test completed (833 hosts)          1157070413.072972         
42.444355
Is there a way to improve number if  parallel pings by hobbitping  ?
my test hobbit server looks very low on load avgerage.
Network tests rarely put much load on your box, they spend most of their
time waiting for the remote server to respond.

You can probably increase the max. packets/second from the default (50)
to e.g. 200 or 500. The risk in doing that is that you might overload
some of the network components along the way to the server, and ICMP
packets are among the first to be discarded if a router sees more
traffic than it can handle. So there's a higher risk of getting false
alerts the higher you go with the packet rate.
I haven't try max packet/second yet but I increase the the number concurreny 
of pings
from default 250 to 1000 and I am seeing 10 seconds improvement(not bad).

bash-3.00$ grep concurrency  hobbitlaunch.cfg
        CMD bbtest-net --report --ping --checkresponse 
--dnslog=$BBSERVERLOGS/dns.log --concurrency=1000
bash-3.00$

PING test completed (833 hosts)          1157106120.152276         32.152155

Thanks

tj
Regards,
Henrik

list Bob Gordon · Fri, 1 Sep 2006 07:18:49 -0700 ·
Thanks for the feedback..   Looks like I have a bit of scripting to do.....

-- 
--==[ Bob Gordon ]==--