Hello I am new to open source monitoring tools - NagiosXI
I want to monitor the different services and their state and different processes running on a windows server. And for each of these processes I want to
monitor the following attributes:
1. CPU usage = The percentage of time that a process used the CPU
2. Memory Usage = Amount of memory in the private working of the process
3. Threads = how many threads each process is running (or owned)
4. Handles = how many files, sockets etc are currently opened by each process.
5. I/O Reads and Writes = input and output to other devices (disk, cpu etc) on the system.
Could you please help me with the query.
Thanks,
Abhilash
402-999-3929
Monitor the CPU Usage, memory used, number of threads used,
-
abhilash.patlolla
- Posts: 8
- Joined: Sat Aug 01, 2015 5:03 pm
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: Monitor the CPU Usage, memory used, number of threads us
Processes are transient, they come and go. Sometimes you have more than one of a single name, sometimes you have none.
Here's what I can tell you - you will have to write a powershell script to extract the information you want, and you will have to call that up through NSCP.
Here's what I can't tell you...
If you can give an example of what you'd expect the output to look like, and also what you'd expect the plugin return codes 0,1,2 to represent - we may be able to give more useful advice.
Here's what I can tell you - you will have to write a powershell script to extract the information you want, and you will have to call that up through NSCP.
Here's what I can't tell you...
How you'll have the Nagios server handle processes/services that come and go. Unless you have a fixed list or services and/or processes that you wish to monitor, and they're well behaved (e.g. they don't spin up 3 or 4 different child procs, or don't respawn themselves randomly) it will be complicated.abhilash.patlolla wrote:monitor the different services and their state and different processes running on a windows server.
If you can give an example of what you'd expect the output to look like, and also what you'd expect the plugin return codes 0,1,2 to represent - we may be able to give more useful advice.
-
abhilash.patlolla
- Posts: 8
- Joined: Sat Aug 01, 2015 5:03 pm
Re: Monitor the CPU Usage, memory used, number of threads us
Thank you for the immediate response.
I would like to monitor a list of specific services and processes. And for these processes I would like to get the CPU usage. memory. threads, handles, I/O reads and writes in the remote machines.
Below attached pictures give the example of what I want to get the information from remote machines.
Picture 1: I want to get the process name, CPU, Memory, handles, threads, I/O reads and I/O writes for the specific list of processes running on the remote machine
Picture 2: I also want to get the specific list of services running in the remote machine and the status of the service.
Could you provide me the information about the plugin codes and what can I expect from these codes as I am new to this domain.
I would like to monitor a list of specific services and processes. And for these processes I would like to get the CPU usage. memory. threads, handles, I/O reads and writes in the remote machines.
Below attached pictures give the example of what I want to get the information from remote machines.
Picture 1: I want to get the process name, CPU, Memory, handles, threads, I/O reads and I/O writes for the specific list of processes running on the remote machine
Picture 2: I also want to get the specific list of services running in the remote machine and the status of the service.
Could you provide me the information about the plugin codes and what can I expect from these codes as I am new to this domain.
You do not have the required permissions to view the files attached to this post.
-
jdalrymple
- Skynet Drone
- Posts: 2620
- Joined: Wed Feb 11, 2015 1:56 pm
Re: Monitor the CPU Usage, memory used, number of threads us
These are simple perfcounter queries IF AND ONLY IF your processes are fixed and have a predictable namespace:
For a complete list of performance counters that you can query run perfmon on the target box.
If your processes have any unpredictability or if you wish to query transient processes this will become very complicated very quick.
Code: Select all
[jdalrymple@localhost libexec]$ ./check_nrpe -H 192.168.5.233 -c checkcounter -a "Counter=\\Process(firefox)\Thread Count"
OK: \Process(firefox)\Thread Count = 110|'\Process(firefox)\Thread Countnone'=110;0;0
[jdalrymple@localhost libexec]$ ./check_nrpe -H 192.168.5.233 -c checkcounter -a "Counter=\\Process(firefox)\% Processor Time"
OK: \Process(firefox)\% Processor Time = 99|'\Process(firefox)\% Processor Timenone'=99;0;0
[jdalrymple@localhost libexec]$ ./check_nrpe -H 192.168.5.233 -c checkcounter -a "Counter=\\Process(firefox)\IO Data Operations/sec"
OK: \Process(firefox)\IO Data Operations/sec = 576|'\Process(firefox)\IO Data Operations/secnone'=576;0;0If your processes have any unpredictability or if you wish to query transient processes this will become very complicated very quick.