I'm trying to monitor the CPU and Memory utilization of a process on a linux server. When I use the Process Monitor -SNMP template, I can browse the list of processes in a very generic fashion, but it doesn't give me the granularity I want. For instance, on one of my boxes I have 3 'java' processes running, but I"m only interested in the performance of one of them. I can use the template to add the 'java' process, but when I view the application details I have to know the PID of the individual processes to know which one is associated with the app of interest.
So, I thought I might look into writing a script that finds the PID of the java process I'm interested in and prints out the cpu and memory information. If I do that though, how does APM get that information and store it? Or is that even possible? When I looked over the section on linux script monitoring in the Administrators Guide, it appears to function very similar to Nagios, where your script is expected to return a small range of status codes, followed by a message, but performance data isn't stored. Is my understanding correct on that?
Thanks in advance,
--Brandon