-
1. Re: How to set the service discovery and measurement scan in
mazz May 15, 2009 8:29 AM (in response to jim.ma)There are two types of scans - "server scans" and "service scans".
A "server scan" detects top-level servers that run on your platform - things like JBossAS servers, Postgres databases and the like. These scans run by default every 15 minutes. The setting that controls this is "rhq.agent.plugins.server-discovery.period-secs".
A "service scan" detects lower-level and more fine-grained services that are running in already detected and imported top-level servers. Things like EJBs running in JBossAS, tables in a Postgres database or VHosts in Apache. These scans run by default every 24 hours (i.e. 1 day). You must have already imported the servers in inventory before services can be discovered! These types of scans are normally very "expensive" to perform since they do probing inside the managed resource, so we don't do it often (which is why its defaulted to 24 hours). The setting that controls this is "rhq.agent.plugins.service-discovery.period-secs".
To control how often you collect metrics, you change each individual metric's "collection interval". Go to the resource whose metrics you want to change collection intervals for - specifically go to the Measurement tab. You then go to the subtab "Schedules". This is where you change the collection intervals. If you want to change the intervals for many resources, create a compatible group of the resources whose metrics you want to change and go to the group's Measurement>Schedules tab and change the interval there. -
2. Re: How to set the service discovery and measurement scan in
jayshaughnessy May 15, 2009 2:25 PM (in response to jim.ma)And the minimum interval for metric collection is 30 seconds. Note that the more often you collect metrics the heavier the processing demand and back-end storage requirements. So, be judicious in your settings.
-
3. Re: How to set the service discovery and measurement scan in
jim.ma May 18, 2009 6:37 AM (in response to jim.ma)Thanks for your quick and detailed answer. Now it works like a charm.
-
4. Re: How to set the service discovery and measurement scan in
mmusgrov Apr 4, 2011 12:06 PM (in response to mazz)These are reasonable periods for automatic scanning but we should also provide an on demand scan of selected components. For example, in the embedded console if the user selects a node I would have expected a rescan of that node. Not doing so gives the wrong impression to the user.
-
5. Re: How to set the service discovery and measurement scan in
mazz Apr 4, 2011 12:20 PM (in response to mmusgrov)Michael Musgrove wrote:
These are reasonable periods for automatic scanning but we should also provide an on demand scan of selected components. For example, in the embedded console if the user selects a node I would have expected a rescan of that node. Not doing so gives the wrong impression to the user.
Last year, I added the ability to manually ask for a discovery to be performed under a specific resource. See comment #1 in issue 631895. But this is manual - you'd have to go to the agent prompt (if its running in foreground) or you go through the GUI (the agent's Operation tab, using Execute Prompt Command operation).
I recently fixed a bug in the plugin container where it failed to detect services that were deep in the resource hierarchy automatically, under a resource that was newly added... see issue 534186.
Lastly, the platform itself has an operation "Manual Discovery" that let's you kick off a server/service scan on the entire box (i.e. it forces the agent to run the scans even if their scan intervals aren't up and the agent is not due to run them ). But again, this requires a manual effort (you have to go to the GUI and kick it off).
As for the embedded console use-case, I'm not familiar with the embedded console GUI code. But it is possible that that fix for issue 534186 may address your concern, but I don't know, just a guess.