Metrics on Windows XP

Guillaume Liegard guillaume.liegard at gmail.com
Fri Jul 13 09:06:10 EDT 2007


Hello John,

Thank you for your fast answer.

I work on finding a good method to get windows metric.
Because we need to get global CPU usage, memory usage, and network usage, on
Windows XP and Windows Vista.

Then, we want to add metric in the Metric Service implementation.
So, if you open the source, we will propose to adapt the framework to allows
developers to add new metrics easily (if it isn't already done).

-- 
Guillaume Liégard

2007/7/11, John Zinky <jzinky at bbn.com>:
>
> Guillaume,
>
> The Host metrics come from a metric service via the SysStat "Data
> Feed", which periodically polls the host OS for system metrics.
> For linux this is easy using the /proc file interface.
> For Solaris and MacOS we can get the load average by executing the
> program "uptime"
> For Windows nothing is easy, (at least for us). We attempted using
> JNI to make Windows system calls, but abandoned that code as unreliable.
>
> If you know of a way to get at Windows OS parameters from java,
> without JNI calls please tell us we can add these calls.  I.E. is
> there a program that we can exec, that is always installed in
> Windows? If you have working JNI code we might look at, but no
> promises. DLL's are a configuration nightmare.
>
> Specifically, we would like to fill in the metrics servlet table
> "$<NODE1>/metrics/resources"
> or the Metrics Host Keys
>    http://cougaar.cougaar.org/software/latest/doc/OnlineManual/
> MetricsService/keys.html
>
> The missing metrics are:
> LoadAverage (this is the key metric, but Windows does not seem to use
> Load Average (Average number of jobs ready to run).
> Cache
> TcpInUse
> UdpInUse
> TotalMemory
> FreeMemory
>
> Windows metrics that cougaar currently measures.
> Count is obtained via Java System calls
> JIPS (Java Instructions per second) is obtained via a micro benchmark
> when the node first starts up.
>
> BTW: You could not find these metrics in the Cougaar code because,
> the Metric Service implementation really is the QuO Resource Status
> Service ( quo.bbn.com), so the source code is not available via
> cougaar.org. We are debating on whether to add the QuO RSS source
> code to cougaar. Adding Windows support may be a good excuse to do
> this branch.
>
> On Jul 11, 2007, at 11:43 AM, Guillaume Liegard wrote:
>
> > Hello,
> >
> > I'm a new Cougaar developper.
> >
> > I want to know if the metric service can bring me informations
> > about the computer in general.
> >   For example, I need the CPU usage of the computer in general (not
> > only the CPU usage of an agent or a node, or the jvm).
> >
> > Then, the feature must run on Windows XP.
> >   And I get "WARN [DirectSysStatSupplier] - No handler for CPU on
> > platform Windows XP", which makes me think it won't work on Windows.
> >
> > That's why I want to add new metrics, based on native calls.
> > So I read the documentation at "http://cougaar.cougaar.org/software/
> > 12.2/OnlineManual/MetricsService/ ", in particular the section "Add
> > New Metric".
> > I look at an exemple of sensor plugin :
> > "org.cougaar.core.thread.AgentLoadSensorPlugin".
> > But this sensor get it's values suscribing to the metric service,
> > and there is no metric which can answer my need : Get the global
> > CPU usage on Windows plateform.
> >
> > Finaly, I look at the "Use Cases and Examples", in particular the
> > "Example Metrics Writer", in order to be able to add my own key.
> > When I add a new key, like the "Example Metrics Writer" do with the
> > "Current_Time_Millis" key ; I can't get the value after, because I
> > don't know the path.
> > For example, I manage to modify an existing key, like "Host_[Host
> > IP]_CPU_Jips", and get my funny value after because I know the path
> > is "Host([Host IP]):Jips".
> > So where can I do the mapping between key and path ? Because the
> > example shows how can I put a key, but not how can I put the path.
> >
> > --
> > Guillaume Liégard
> >
> > _______________________________________________
> > Cougaar-developers mailing list
> > Cougaar-developers at cougaar.org
> > http://cougaar.org/mailman/listinfo/cougaar-developers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://cougaar.org/pipermail/cougaar-developers/attachments/20070713/78280e7f/attachment.html


More information about the Cougaar-developers mailing list