Duration for one round of server side module
I implemented a server side perl script using this http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for the bb command.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the above url, like the following.
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME /ext/pca.pl
And it is taking tons of resources since it receives all the patch/pkg info from 300 servers through client channel and generate a patch report using the tool pca ( http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP 8687 hobbit 2248M 581M run 39 0 0:02:31 1.1% hobbitd_channel/1 8648 hobbit 58M 56M run 39 0 0:07:42 2.5% hobbitd/1 10223 hobbit 21M 20M run 20 0 0:00:03 15% perl5.8.5/1 7115 devmon 11M 11M sleep 59 0 0:00:44 1.5% devmon/1 8689 hobbit 8816K 6968K sleep 59 0 0:07:52 2.7% pca.pl/1
If I can find out how long it takes to run I can then add an INTERVAL accordingly. I do not need to process the client data more than once a day
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
Maybe I'm missing something, but... Why not just grab the system date/time at the start, again at the end, then subtract one from the other?? If you just print it out, the numbers should go into the log. Or generate your own log file by appending the start & end values, then process later. Ralph Mitchell
On Thu, May 14, 2009 at 1:41 PM, Asif Iqbal <vadud3 at gmail.com> wrote:
I implemented a server side perl script using this http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for the bb command.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the above url, like the following.
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME /ext/pca.pl
And it is taking tons of resources since it receives all the patch/pkg info from 300 servers through client channel and generate a patch report using the tool pca ( http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP 8687 hobbit 2248M 581M run 39 0 0:02:31 1.1% hobbitd_channel/1 8648 hobbit 58M 56M run 39 0 0:07:42 2.5% hobbitd/1 10223 hobbit 21M 20M run 20 0 0:00:03 15% perl5.8.5/1 7115 devmon 11M 11M sleep 59 0 0:00:44 1.5% devmon/1 8689 hobbit 8816K 6968K sleep 59 0 0:07:52 2.7% pca.pl/1
If I can find out how long it takes to run I can then add an INTERVAL accordingly. I do not need to process the client data more than once a day
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
Or use the "time" command in front of the command? This assumes that you know where Xymon is writing your log...
GLH
From: Ralph Mitchell [mailto:ralphmitchell at gmail.com]
Sent: Thursday, May 14, 2009 2:09 PM
To: hobbit at hswn.dk
Subject: Re: [hobbit] Duration for one round of server side
module
Maybe I'm missing something, but... Why not just grab the
system date/time at the start, again at the end, then subtract one from the other?? If you just print it out, the numbers should go into the log. Or generate your own log file by appending the start & end values, then process later.
Ralph Mitchell
On Thu, May 14, 2009 at 1:41 PM, Asif Iqbal <vadud3 at gmail.com>
wrote:
I implemented a server side perl script using this
http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for
the bb command.
But I need help to find out how long it takes for the
script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the
above url, like the following.
[pca]
ENVFILE
/export/home/hobbit/server/etc/hobbitserver.cfg
NEEDS hobbitd
CMD hobbitd_channel --channel=client
--log=$BBSERVERLOGS/pca.log $BBHOME
/ext/pca.pl
And it is taking tons of resources since it receives all
the patch/pkg info from 300 servers through client channel
and generate a patch report using the tool pca
(http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us
to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI NICE TIME
CPU PROCESS/NLWP
8687 hobbit 2248M 581M run 39 0 0:02:31
1.1% hobbitd_channel/1
8648 hobbit 58M 56M run 39 0 0:07:42
2.5% hobbitd/1
10223 hobbit 21M 20M run 20 0 0:00:03
15% perl5.8.5/1
7115 devmon 11M 11M sleep 59 0 0:00:44
1.5% devmon/1
8689 hobbit 8816K 6968K sleep 59 0 0:07:52
2.7% pca.pl/1
If I can find out how long it takes to run I can then
add an INTERVAL accordingly. I do not need to
process the client data more than once a day
--
Asif Iqbal
PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu
A: Because it messes up the order in which people
normally read text.
Q: Why is top-posting such a bad thing?
On Thu, May 14, 2009 at 3:28 PM, Hubbard, Greg L <greg.hubbard at eds.com>wrote:
Or use the "time" command in front of the command? This assumes that you know where Xymon is writing your log...
It is getting called like this
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME
The log is going to /var/log/hobbit/pca.log
Where do I put the time here and how do I know when the first round of hobbit client data have been received in hobbitd_channel and close the time so I don't count same host twice?
GLH
*From:* Ralph Mitchell [mailto:ralphmitchell at gmail.com] *Sent:* Thursday, May 14, 2009 2:09 PM *To:* hobbit at hswn.dk *Subject:* Re: [hobbit] Duration for one round of server side module
Maybe I'm missing something, but... Why not just grab the system date/time at the start, again at the end, then subtract one from the other?? If you just print it out, the numbers should go into the log. Or generate your own log file by appending the start & end values, then process later. Ralph Mitchell
On Thu, May 14, 2009 at 1:41 PM, Asif Iqbal <vadud3 at gmail.com> wrote:
I implemented a server side perl script using this http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for the bb command.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the above url, like the following.
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME /ext/pca.pl
And it is taking tons of resources since it receives all the patch/pkg info from 300 servers through client channel and generate a patch report using the tool pca ( http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP 8687 hobbit 2248M 581M run 39 0 0:02:31 1.1% hobbitd_channel/1 8648 hobbit 58M 56M run 39 0 0:07:42 2.5% hobbitd/1 10223 hobbit 21M 20M run 20 0 0:00:03 15% perl5.8.5/1 7115 devmon 11M 11M sleep 59 0 0:00:44 1.5% devmon/1 8689 hobbit 8816K 6968K sleep 59 0 0:07:52 2.7% pca.pl/1
If I can find out how long it takes to run I can then add an INTERVAL accordingly. I do not need to process the client data more than once a day
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
On Thu, May 14, 2009 at 3:09 PM, Ralph Mitchell <ralphmitchell at gmail.com>wrote:
Maybe I'm missing something, but... Why not just grab the system date/time at the start, again at the end, then subtract one
How do I know the end? The clients are constantly feeding data to hobbitd_channel and they may not be coming in sequential order. I may receive data from one host twice who is right next to hobbit server before I receive client data for another host which is in different country
from the other?? If you just print it out, the numbers should go into the log. Or generate your own log file by appending the start & end values, then process later. Ralph Mitchell
On Thu, May 14, 2009 at 1:41 PM, Asif Iqbal <vadud3 at gmail.com> wrote:
I implemented a server side perl script using this http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for the bb command.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the above url, like the following.
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME /ext/pca.pl
And it is taking tons of resources since it receives all the patch/pkg info from 300 servers through client channel and generate a patch report using the tool pca ( http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP 8687 hobbit 2248M 581M run 39 0 0:02:31 1.1% hobbitd_channel/1 8648 hobbit 58M 56M run 39 0 0:07:42 2.5% hobbitd/1 10223 hobbit 21M 20M run 20 0 0:00:03 15% perl5.8.5/1 7115 devmon 11M 11M sleep 59 0 0:00:44 1.5% devmon/1 8689 hobbit 8816K 6968K sleep 59 0 0:07:52 2.7% pca.pl/1
If I can find out how long it takes to run I can then add an INTERVAL accordingly. I do not need to process the client data more than once a day
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
On Thu, May 14, 2009 at 2:39 PM, Asif Iqbal <vadud3 at gmail.com> wrote:
On Thu, May 14, 2009 at 3:09 PM, Ralph Mitchell <ralphmitchell at gmail.com>wrote:
Maybe I'm missing something, but... Why not just grab the system date/time at the start, again at the end, then subtract one
How do I know the end? The clients are constantly feeding data to hobbitd_channel and they may not be coming in sequential order. I may receive data from one host twice who is right next to hobbit server before I receive client data for another host which is in different country
Looking at the ssmodule sample program, I think I would pick up the start and end time in the 'processmessage' routine. The hostname gets passed through to that routine, so you could log a timestamp, the hostname and the duration for each host.
Ralph Mitchell
On Thu, May 14, 2009 at 6:29 PM, Ralph Mitchell <ralphmitchell at gmail.com>wrote:
On Thu, May 14, 2009 at 2:39 PM, Asif Iqbal <vadud3 at gmail.com> wrote:
On Thu, May 14, 2009 at 3:09 PM, Ralph Mitchell <ralphmitchell at gmail.com>wrote:
Maybe I'm missing something, but... Why not just grab the system date/time at the start, again at the end, then subtract one
How do I know the end? The clients are constantly feeding data to hobbitd_channel and they may not be coming in sequential order. I may receive data from one host twice who is right next to hobbit server before I receive client data for another host which is in different country
Looking at the ssmodule sample program, I think I would pick up the start and end time in the 'processmessage' routine. The hostname gets passed through to that routine, so you could log a timestamp, the hostname and the duration for each host.
But that won't still tell the completion of first round of all hosts or if any hosts' data been feed more than once while another host data has not arrived yet
I am guessing using clientlog to pull the data would be simpler. That will give me definite answer of how long it took to collect data of each host (in miliseconds) and how long it took to rotate through all the hosts.
I wish I could get those info from this server side perl script, but I doubt that is logically possible given this scenario.
Ralph Mitchell
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
Hi Asif
There are a few questions need to be addressed for non-home deployment.
- Do we want to have xymon clients to query Sun's patch database file ? The answer should be No for a site have big xymon client installations.
- the pca xymon client module should query internal solaris patch database server(on xymon server).
- the pca xymon server side EXT module should in sync with Sun's patch database server and download the zip files for internal installation.
- pca rely on wget and wget rely on other software also, be prepared to deal with pca xymon module for solaris 2.6 and above that doesn't come with wget.
I don't quite understand why you design pca work as server side module
For me, I did it as a client side module and create another column (pca) for each xymon client.
Here is an example of what it looks like so far
http://xymon.dlinkddns.com/hobbit-cgi/bb-hostsvc.sh?HOST=netinstall.test.net...
P.S. I interacted with pca author but failed to convince him we (xymon community) can have a "-M" option to send out xymon needed html format.
tj
From: Asif Iqbal Sent: Thursday, May 14, 2009 1:41 PM To: hobbit at hswn.dk Subject: [hobbit] Duration for one round of server side module
I implemented a server side perl script using this http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for the bb command.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the above url, like the following.
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME /ext/pca.pl
And it is taking tons of resources since it receives all the patch/pkg info from 300 servers through client channel and generate a patch report using the tool pca (http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP
8687 hobbit 2248M 581M run 39 0 0:02:31 1.1% hobbitd_channel/1
8648 hobbit 58M 56M run 39 0 0:07:42 2.5% hobbitd/1
10223 hobbit 21M 20M run 20 0 0:00:03 15% perl5.8.5/1
7115 devmon 11M 11M sleep 59 0 0:00:44 1.5% devmon/1
8689 hobbit 8816K 6968K sleep 59 0 0:07:52 2.7% pca.pl/1
If I can find out how long it takes to run I can then add an INTERVAL accordingly. I do not need to process the client data more than once a day
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
On Thu, May 14, 2009 at 8:46 PM, T.J. Yang <tj_yang at hotmail.com> wrote:
Hi Asif
There are a few questions need to be addressed for non-home deployment.
- Do we want to have xymon clients to query Sun's patch database file ? The answer should be No for a site have big xymon client installations.
- the pca xymon client module should query internal solaris patch database server(on xymon server).
- the pca xymon server side EXT module should in sync with Sun's patch database server and download the zip files for internal installation.
- pca rely on wget and wget rely on other software also, be prepared to deal with pca xymon module for solaris 2.6 and above that doesn't come with wget.
I discussed w/ pca community and server side module works better Here is the thread.
http://www.mail-archive.com/pca at lists.univie.ac.at/msg00939.html
Most of the servers are between sol 8 and sol 10 but that is not a problem since I am doing it on the server side and my hobbit server is sol 9
I updated the hobbitclient-sunos.sh file and pushed using clientupdate method to all the clients. only the following lines needed to add to the hobbitclient-sunos.sh. That was enough data to generate the pca report
echo "[showrev]" showrev -p echo "[pkginfo]" pkginfo -x
right below [ps] section
Also whenever new version pca comes I just need to update the pca on hobbit server to get my patch report
I don't quite understand why you design pca work as server side module
For me, I did it as a client side module and create another column (pca) for each xymon client.
Here is an example of what it looks like so far
http://xymon.dlinkddns.com/hobbit-cgi/bb-hostsvc.sh?HOST=netinstall.test.net...
P.S. I interacted with pca author but failed to convince him we (xymon community) can have a "-M" option to send out xymon needed html format.
You use the `-L ' switch to get html report.
tj
*From:* Asif Iqbal <vadud3 at gmail.com> *Sent:* Thursday, May 14, 2009 1:41 PM *To:* hobbit at hswn.dk *Subject:* [hobbit] Duration for one round of server side module
I implemented a server side perl script using this http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for the bb command.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the above url, like the following.
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME /ext/pca.pl
And it is taking tons of resources since it receives all the patch/pkg info from 300 servers through client channel and generate a patch report using the tool pca ( http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP 8687 hobbit 2248M 581M run 39 0 0:02:31 1.1% hobbitd_channel/1 8648 hobbit 58M 56M run 39 0 0:07:42 2.5% hobbitd/1 10223 hobbit 21M 20M run 20 0 0:00:03 15% perl5.8.5/1 7115 devmon 11M 11M sleep 59 0 0:00:44 1.5% devmon/1 8689 hobbit 8816K 6968K sleep 59 0 0:07:52 2.7% pca.pl/1
If I can find out how long it takes to run I can then add an INTERVAL accordingly. I do not need to process the client data more than once a day
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
Thanks for the info, I documented the differences of these two approaches.
http://en.wikibooks.org/wiki/System_Monitoring_with_Xymon/Other_Docs/HOWTO#H...
T.J. Yang
Date: Thu, 14 May 2009 21:22:11 -0400 From: vadud3 at gmail.com To: hobbit at hswn.dk Subject: Re: [hobbit] Duration for one round of server side module
On Thu, May 14, 2009 at 8:46 PM, T.J. Yang <tj_yang at hotmail.com> wrote:
Hi Asif
There are a few questions need to be addressed for non-home deployment.
- Do we want to have xymon clients to query Sun's patch database file ? The answer should be No for a site have big xymon client installations.
- the pca xymon client module should query internal solaris patch database server(on xymon server).
- the pca xymon server side EXT module should in sync with Sun's patch database server and download the zip files for internal installation.
- pca rely on wget and wget rely on other software also, be prepared to deal with pca xymon module for solaris 2.6 and above that doesn't come with wget.
I discussed w/ pca community and server side module works better Here is the thread.
http://www.mail-archive.com/pca at lists.univie.ac.at/msg00939.html
Most of the servers are between sol 8 and sol 10 but that is not a problem since I am doing it on the server side and my hobbit server is sol 9
I updated the hobbitclient-sunos.sh file and pushed using clientupdate method to all the clients.
only the following lines needed to add to the hobbitclient-sunos.sh. That was enough data to generate the pca report
echo "[showrev]" showrev -p echo "[pkginfo]" pkginfo -x
right below [ps] section
Also whenever new version pca comes I just need to update the pca on hobbit server to get my patch report
I don't quite understand why you design pca work as server side module
For me, I did it as a client side module and create another column (pca) for each xymon client.
Here is an example of what it looks like so far
http://xymon.dlinkddns.com/hobbit-cgi/bb-hostsvc.sh?HOST=netinstall.test.net...
P.S. I interacted with pca author but failed to convince him we (xymon community) can have a "-M" option to send out xymon needed html format.
You use the `-L ' switch to get html report.
tj
From: Asif Iqbal Sent: Thursday, May 14, 2009 1:41 PM To: hobbit at hswn.dk Subject: [hobbit] Duration for one round of server side module
I implemented a server side perl script using this http://xymonton.trantor.org/doku.php/tutorials:ssmodule as the template.
I like to run it only once daily, so I put status+1d for the bb command.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
Currently I have it setup just like the setup in the above url, like the following.
[pca] ENVFILE /export/home/hobbit/server/etc/hobbitserver.cfg NEEDS hobbitd CMD hobbitd_channel --channel=client --log=$BBSERVERLOGS/pca.log $BBHOME /ext/pca.pl
And it is taking tons of resources since it receives all the patch/pkg info from 300 servers through client channel and generate a patch report using the tool pca (http://www.par.univie.ac.at/solaris/pca/) for each host. It allows us to find out the patch status for all solaris boxes
Here is an snippet of the top processes sorted by RSS
PID USERNAME SIZE RSS STATE PRI
NICE TIME CPU
PROCESS/NLWP
8687
hobbit 2248M 581M run
39 0 0:02:31 1.1% hobbitd_channel/1
8648
hobbit 58M 56M run
39 0 0:07:42 2.5% hobbitd/1
10223
hobbit 21M 20M run
20 0 0:00:03 15% perl5.8.5/1
7115
devmon 11M 11M sleep
59 0 0:00:44 1.5% devmon/1
8689
hobbit 8816K 6968K sleep 59
0 0:07:52 2.7% pca.pl/1
If I can find out how long it takes to run I can then add an INTERVAL accordingly. I do not need to process the client data more than once a day
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
-- Asif Iqbal PGP Key: 0xE62693C5 KeyServer: pgp.mit.edu A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing?
Hotmail® goes with you. http://windowslive.com/Tutorial/Hotmail/Mobile?ocid=TXT_TAGLM_WL_HM_Tutorial...
On Thu, May 14, 2009 at 11:41, Asif Iqbal <vadud3 at gmail.com> wrote:
I like to run it only once daily, so I put status+1d for the bb command.
The default LIFETIME, at 5 minute intervals, forgives 5 misses. +1d combined with once daily would forgive 0 or fewer misses.
But I need help to find out how long it takes for the script to complete for my ~300 hosts.
participants (5)
-
goldfndr@gmail.com
-
greg.hubbard@eds.com
-
ralphmitchell@gmail.com
-
tj_yang@hotmail.com
-
vadud3@gmail.com