Project Description
This small utility helps to monitor performance counters without using the full blown perfmon tool from Windows. It supports a number of command line parameters and can be launched from batch files, shortcuts or (from version 1.4) preset qpmset files.
Image may be NSFW.
Clik here to view.
Introduction
This small utility was developed to help monitor sets of performance counters quickly and (only) as needed.
The original graph control was based on
C2DPushGraph graph control but was customized and enhanced quite a bit for this application's needs. The main aim for the utility is to be really 'simple' without too many fancies - but it is evolving and more things might get added over time.
Update history
- 1.4.4 - The tool now has the functionality to log the performance counter values to a csv file.
- 1.4.5 - Enhanced logging options. Check for available disk space, create new file every X MB and change sample rate i.e. only log data for every N times the graph is updated. Additionally the tool will now upgrade/remember previous version settings.
- 1.4.6 - Small bug fix to graph control to avoid negative/large perf counter values crashing the app.
- 1.4.8 - Added 'snapping' to desktop plus 'cloning' of performance counters to ease adding a bunch of counters together.
- 1.4.9 - Added displaying latest and earliest times and more line formatting options.
- 1.4.10/11 More line formatting options plus fix bug to not allow duplicate counters.
- 1.4.13 Fixed reported issue with decimal scaled values when using other 'cultures'/formatting.
- 1.5.0 New graph control implemented. Colors and font can now be customized.
- 1.6.0 Improved the initial loading speed of application (user experience)
- 1.7.0 Converted to use .Net 4.0 framework. Line color customizations are now stored in qpmset files. As a result the structure of qpmset files has changed and not compatible with earlier versions. Now includes a proper MSI installer.
- 1.8.0 Now you can add multiple counters/instances at once! Selecting a category you can multi-select the counters and instances you want to add from lists.
- 1.8.1 - Added the ability to set the main Window as 'Always On Top'.
- 1.8.2 - Add the ability for qpmset files to also store the Window location/size so predefined 'sets' can be forced to always open on the same place of the screen.
- 1.9.1 - Drag and drop now possible inside the app so you can re-order items. Also added the ability to copy & paste counter definitions so it can be edited outside the app (notepad or something) and then added as a new counter or set of counters.
Usage
The tool can be executed with parameters. At the moment there is no restriction on the number of performance counters that can be specified although it would be impractical to specify too many. Each performance counter specified must looks like this:
[Machine name]\[Category]\[Counter name]\[Instance name]\[scale]\[plot style]
- The machine name is the name of the computer where the performance counter is published.
- The category of the performance counter
- The name of the performance counter
- The instance name if it exists
- The scale of the performance counter (default = 1)
- The plotting style of data points. could be 0 - None, 1 - Dots, 2 - Cross or 3 - Ex
An example:
".\Processor\% Processor Time\_Total\1\1"
note: if the instance name contains special characters like a backslash '\' you must 'escape' the whole value with double quotes.
e.g.
biztalkserver\BizTalk:Message Box:General Counters\Spool Size\"biztalkmsgboxdb:sqlserver\sqlinstance"\0.1\2
Additional parameters
The following additional parameters can be specified:
- -max: Set the initial Y axis maximum value (default = 100)
- -lt: Set the default line thickness (default = 1)
- -title: Set a customized title for the window (helps if you have several windows open)
Customize
You can customize the following while running:
- Updating frequency/Pause
- Color of each line/counter
- Scale of each line/counter
- Plot style of each line/counter. e.g. like +, o, x etc.
Run-time
As of version 1.4 the application allows you to add and remove performance counters at run-time.
qpmset Files
As of version 1.4 you can load and save performance counter sets to a file for reuse. The files are actually only an XML file with a different extension so it can be edited with any text editor if needed.
From version 1.7 the internal structure of the qpmset files have changed. The performance counter definition is now stored as an Xml string.
Logging data to csv files
The tool supports logging data to a csv file. The following logging options are available:
Image may be NSFW.
Clik here to view.
Example
Running the utility with the following parameters:
QPerfMon.exe ".\Processor\% Processor Time\_Total" ".\Memory\% Committed Bytes In Use\\" ".\Memory\Pages/sec\\0.1" ".\PhysicalDisk\Avg. Disk Queue Length\_Total\100" -title:Test
Note: remember to escape the '%' character in a batch file.
Would look like this:
Image may be NSFW.
Clik here to view.
Graph format customization
Image may be NSFW.
Clik here to view.
Line formatting
Additionally the formatting of a line can be changed afterwords:
Image may be NSFW.
Clik here to view.
Dependencies and platform support
The utility was developed using C# with .Net 2.0 (using VS2008) - up to version 1.6. The reason for not using newer versions of the .Net framework was simply so it can still be used on older Win XP/2003 servers etc. It has been tested on Windows XP, 2003, Vista and Windows 7 (32 and 64-bit). From version 1.7 it uses the .Net 4.0 Client profile framework.