Find the Best Cosmetic Hospitals

Explore trusted cosmetic hospitals and make a confident choice for your transformation.

โ€œInvest in yourself โ€” your confidence is always worth it.โ€

Explore Cosmetic Hospitals

Start your journey today โ€” compare options in one place.

PERFMON (Performance Monitor): The Complete One-Stop Tutorial

It covers EVERYTHING you need:

โœ” What PerfMon is
โœ” Why PerfMon is used
โœ” When to use PerfMon
โœ” PerfMon Architecture
โœ” Key Terminologies
โœ” How PerfMon works
โœ” How to use PerfMon step-by-step
โœ” All important counters
โœ” Real performance engineering use cases
โœ” Advantages, Limitations, Best Practices
โœ” Troubleshooting with PerfMon
โœ” PerfMon vs other tools


๐Ÿ“˜ PERFMON (Performance Monitor): The Complete One-Stop Tutorial


1. Introduction to PerfMon

What is PerfMon?

PerfMon (Performance Monitor) is a built-in Windows performance monitoring tool used to collect, visualize, and analyze system and application performance metrics called performance counters.

It allows you to monitor:

  • CPU usage
  • Memory usage
  • Disk I/O
  • Network traffic
  • Process-level metrics
  • Thread, handle, and heap usage
  • .NET CLR health (GC, exceptions, JIT, threads)
  • IIS / ASP.NET metrics
  • SQL Server counters
  • Custom application counters

PerfMon is one of the most powerful and most underutilized diagnostic tools in Windows.


2. Why PerfMon Exists (Purpose)

PerfMon helps you:

โœ” Detect performance bottlenecks

CPU spikes, memory leaks, disk contention, network congestion

โœ” Troubleshoot production issues

  • High CPU
  • Low memory
  • Disk thrashing
  • Network bottleneck
  • Slow API response time
  • GC pauses
  • SQL performance issues

โœ” Perform load testing diagnostics

It allows you to correlate load tests with system metrics.

โœ” Monitor .NET applications

GC behavior, exceptions/sec, thread pool usage

โœ” Monitor IIS / Kestrel

Requests/sec, connection queue, request pipeline health

โœ” Monitor SQL Server

Batch requests/sec, compilations, cache hits

PerfMon is essential for Performance Engineering, SRE, DevOps, and Developers.


3. When to Use PerfMon (Scenarios)

Use PerfMon when:

1๏ธโƒฃ You run a load test

You must capture perf counters to see:

  • CPU
  • Memory
  • Disk
  • Network
  • .NET GC
  • SQL Server

2๏ธโƒฃ Production troubleshooting

When a server is slow, PerfMon reveals patterns.

3๏ธโƒฃ Memory leaks

Watch Private Bytes + GC counters.

4๏ธโƒฃ CPU spikes

Check Processor Time + Context Switches + thread count.

5๏ธโƒฃ Slow disk or file reads

Disk Queue Length is key.

6๏ธโƒฃ Slow API throughput

Monitor Requests/sec + ASP.NET pipeline limits.

7๏ธโƒฃ High GC pauses

% Time in GC tells the story.

8๏ธโƒฃ SQL Server performance issues

Batch Requests/sec + Compilations/sec.

PerfMon is used by senior engineers, SREs, DevOps, DBAs, and Performance Test Engineers.


4. PerfMon Architecture

PerfMon works on a simple architecture:

 Windows Kernel + Applications
         |
   Performance Counters (APIs)
         |
     PerfMon.exe
         |
   - Live Graphs
   - Reports
   - Data Collector Sets

Key points:

  • Windows exposes more than 5,000 counters.
  • PerfMon reads these counters and shows them.
  • Counters can come from OS, .NET CLR, SQL Server, IIS, third-party apps.

5. Key Terminology

โžค Performance Counter

A real-time metric exposed by Windows or applications.

Examples:

  • % Processor Time
  • Available Memory
  • Disk Queue Length
  • Bytes Received/sec
  • .NET CLR Memory: % Time in GC
  • SQL Compilations/sec

โžค Object

A category of counters, e.g.,

  • Processor
  • Memory
  • PhysicalDisk
  • Network Interface
  • Process
  • .NET CLR Memory

โžค Instance

A specific process or core.

Examples:

  • Processor โ†’ _Total, 0, 1, 2
  • Process โ†’ dotnet, chrome, myapp.exe
  • SQL Server โ†’ MSSQLSERVER

โžค Data Collector Set (DCS)

A group of counters scheduled to log into a file.

Used for:

  • Load tests
  • Production monitoring
  • Historical analysis

โžค BLG / CSV Logs

PerfMon logs stored for later analysis.

BLG is the binary format (smaller, efficient).


6. PerfMon Components

PerfMon has three major sections:


6.1 Performance Monitor (Live Graph)

Shows real-time counters as a line graph.

Great for:

  • Spikes
  • Bottleneck identification
  • Correlation during load tests

6.2 Data Collector Sets

You can create a DCS that:

  • Runs for hours/days
  • Captures hundreds of counters
  • Saves in BLG or CSV

Used in:

  • Load testing
  • Production issues
  • Long-running performance tests

6.3 Reports

After a DCS completes, PerfMon auto-generates reports summarizing:

  • Peak CPU
  • Memory trend
  • Disk latency
  • Network usage

7. How to Use PerfMon (Step-by-Step Tutorial)


Step 1: Launch PerfMon

Press:

Win + R โ†’ perfmon

OR
Search: Performance Monitor


Step 2: Open โ€œPerformance Monitorโ€

Left panel โ†’ Monitoring Tools โ†’ Performance Monitor

You will see:

  • A default red CPU line
  • Live graph

Step 3: Add Counters

Click:

Green + icon โ†’ Add Counters

You will see categories like:

  • Processor
  • Memory
  • Disk
  • Network
  • Process
  • .NET CLR Memory
  • SQLServer:*

Step 4: Select Important Counters

Choose your object โ†’ select instance โ†’ click Add.

Examples:

For CPU

Processor โ†’ % Processor Time โ†’ _Total
Process โ†’ % Processor Time โ†’ dotnet

For Memory

Memory โ†’ Available MBytes
Memory โ†’ % Committed Bytes
Process โ†’ Private Bytes โ†’ myapp.exe
Code language: CSS (css)

For Disk

PhysicalDisk โ†’ Avg. Disk Queue Length โ†’ _Total

For Network

Network Interface โ†’ Bytes Total/sec
Code language: PHP (php)

For .NET

.NET CLR Memory โ†’ % Time in GC โ†’ myapp.exe
.NET CLR Exceptions โ†’ # Exceptions/sec โ†’ myapp.exe
Code language: PHP (php)

Step 5: Analyze Graphs

Watch the graphs for:

  • Spikes
  • Trends
  • Degradation
  • Correlation with load

PerfMon lets you:

  • Change line colors
  • Change scale
  • Pause
  • Zoom in
  • Pin counters

Step 6: Create Data Collector Set (DCS)

Why?

For long-term monitoring (load test, 1 hour+).

Steps:

  1. Right-click โ†’ Data Collector Sets โ†’ User Defined
  2. New โ†’ Data Collector Set
  3. Add performance counters
  4. Set sample interval (1 sec or 5 sec)
  5. Choose log path
  6. Click Finish
  7. Start the DCS

You now have automatic background logging.


Step 7: View Reports

After DCS completes:

Reports โ†’ User Defined โ†’ Your DCS

You will see:

  • CPU peaks
  • Memory trend
  • Disk I/O charts
  • Network summary

8. Most Important PerfMon Counters

Here are the mission-critical counters for troubleshooting.


CPU

CounterWhy
Processor โ†’ % Processor TimeCPU bottleneck (>80%)
Process โ†’ % Processor TimePer-process CPU
System โ†’ Context Switches/secThread contention
Processor โ†’ % Privileged TimeKernel overhead

Memory

CounterWhy
Memory โ†’ Available MBytesMemory pressure
% Committed Bytes In UseIf >80% โ†’ close to paging
Process โ†’ Private BytesMemory leak indicator
Paging File โ†’ % UsageDisk paging

Disk

CounterWhy
Avg. Disk Queue LengthDisk bottleneck if >2 per spindle
Avg. sec/ReadDisk read latency
Avg. sec/WriteDisk write latency

Network

CounterWhy
Bytes Total/secThroughput
Output Queue LengthNIC congestion
TCP Retransmissions/secNetwork issues

.NET CLR

CounterWhy
% Time in GCGC pauses
# Gen 2 CollectionsFull GCs are expensive
# Exceptions/secException storms
LOH SizeLOH fragmentation
Thread CountThread pool starvation

ASP.NET / IIS

CounterWhy
Requests/secThroughput
Request Execution TimeAPI delay
Current ConnectionsServer load
Pipeline Instance CountBottlenecks

SQL Server

CounterWhy
Batch Requests/secQuery throughput
Compilations/secPoor plan caching
Buffer Cache Hit RatioMemory pressure
Page Life ExpectancySQL memory issues

9. PerfMon Use Cases


โœ” Use Case 1: High CPU

Counters:

  • Processor โ†’ % Processor Time
  • Process โ†’ % Processor Time
  • Context Switches/sec
  • Thread Count

You identify:

  • Hot processes
  • Bad loops
  • Thread contention

โœ” Use Case 2: Memory Leak

Monitor:

  • Private Bytes
  • Working Set
  • % Committed Bytes
  • GC counters

โœ” Use Case 3: Disk Bottleneck

Monitor:

  • Disk Queue Length
  • Disk latency (Avg sec/Read)
  • Page File usage

โœ” Use Case 4: Slow API Response

Monitor:

  • ASP.NET Request Time
  • Requests/sec
  • % Time in GC
  • SQL Batch Requests/sec

10. Advantages of PerfMon

โœ” Free โ€“ built into Windows

โœ” Extremely lightweight

โœ” Logs run for days

โœ” Can monitor local + remote servers

โœ” Thousands of counters

โœ” Full historical reporting

โœ” Used in enterprise load testing

โœ” Works with Power BI, Excel, Grafana, Splunk


11. Limitations of PerfMon

โŒ Not beginner-friendly

โŒ No anomaly detection

โŒ Only Windows

โŒ Requires manual setup

โŒ BLG analysis requires external tools


12. Best Practices

โœ” Always create a DCS for load tests
โœ” Use 1-sec sampling for short tests
โœ” Use 5-sec sampling for long tests
โœ” Always include CPU, Memory, Disk, Network
โœ” For .NET apps โ†’ add CLR counters
โœ” For SQL tests โ†’ add SQL counters
โœ” Log to BLG (not CSV)
โœ” Use naming like “Test1_CPU_Memory_Disk”


13. PerfMon vs Other Tools

ToolPurpose
PerfMonDeep OS + .NET diagnostics
Resource MonitorReal-time troubleshooting
Task ManagerBasic monitoring
Process ExplorerProcess-level details
dotnet-counters.NET runtime live metrics
dotnet-traceTrace collection
SQL ProfilerSQL tracing

14. Conclusion

PerfMon is one of the most essential performance tools for:

  • Developers
  • SRE
  • DevOps
  • Performance Test Engineers
  • System Admins

It gives complete visibility into:

  • System health
  • .NET runtime
  • SQL Server
  • Disk I/O
  • Network
  • Application behavior

No Windows performance investigation is complete without PerfMon.


Just tell me.

Find Trusted Cardiac Hospitals

Compare heart hospitals by city and services โ€” all in one place.

Explore Hospitals
Iโ€™m a DevOps/SRE/DevSecOps/Cloud Expert passionate about sharing knowledge and experiences. I have worked at <a href="https://www.cotocus.com/">Cotocus</a>. I share tech blog at <a href="https://www.devopsschool.com/">DevOps School</a>, travel stories at <a href="https://www.holidaylandmark.com/">Holiday Landmark</a>, stock market tips at <a href="https://www.stocksmantra.in/">Stocks Mantra</a>, health and fitness guidance at <a href="https://www.mymedicplus.com/">My Medic Plus</a>, product reviews at <a href="https://www.truereviewnow.com/">TrueReviewNow</a> , and SEO strategies at <a href="https://www.wizbrand.com/">Wizbrand.</a> Do you want to learn <a href="https://www.quantumuting.com/">Quantum Computing</a>? <strong>Please find my social handles as below;</strong> <a href="https://www.rajeshkumar.xyz/">Rajesh Kumar Personal Website</a> <a href="https://www.youtube.com/TheDevOpsSchool">Rajesh Kumar at YOUTUBE</a> <a href="https://www.instagram.com/rajeshkumarin">Rajesh Kumar at INSTAGRAM</a> <a href="https://x.com/RajeshKumarIn">Rajesh Kumar at X</a> <a href="https://www.facebook.com/RajeshKumarLog">Rajesh Kumar at FACEBOOK</a> <a href="https://www.linkedin.com/in/rajeshkumarin/">Rajesh Kumar at LINKEDIN</a> <a href="https://www.wizbrand.com/rajeshkumar">Rajesh Kumar at WIZBRAND</a> <a href="https://www.rajeshkumar.xyz/dailylogs">Rajesh Kumar DailyLogs</a>

Related Posts

How Self-Paced Learning Prepares Students for Technology Careers

The US Bureau of Labor Statistics projects that in 2034, there will be over 11,650 jobs in STEM, which is a slight increase from 2024. While AI…

Read More

SocialBoosting Review: Is It Safe for Influencers and Brands?

I’ve tested dozens of social media growth services over the past five years, and most of them fall into one of two camps: either they burn your…

Read More

Smart wallets came to Solana. The wallet category is being redefined

For most of crypto’s history, wallets have been a fairly thin category. A wallet held private keys, signed transactions, and displayed balances. Different wallets competed on user…

Read More

Top 10 AI Personalized Study Plan Tools: Features, Pros, Cons & Comparison

Introduction AI Personalized Study Plan Tools use machine learning, adaptive algorithms, and learning analytics to create tailored study schedules for students and lifelong learners. By analyzing prior…

Read More

Top 10 AI Lecture Transcription & Notes Tools: Features, Pros, Cons & Comparison

Introduction AI Lecture Transcription & Notes Tools use speech recognition, natural language processing, and AI summarization to convert spoken lectures, webinars, or meetings into text-based notes. These…

Read More

Top 10 AI Plagiarism & AI-Writing Detection Tools: Features, Pros, Cons & Comparison

Introduction AI Plagiarism & AI-Writing Detection Tools leverage natural language processing, machine learning, and forensic analysis to identify copied content, detect AI-generated text, and evaluate writing originality….

Read More
Subscribe
Notify of
guest
2 Comments
Newest
Oldest Most Voted
Skylar Bennett
Skylar Bennett
6 months ago

Excellent tutorial โ€” this is by far one of the clearest guides to Performance Monitor (PerfMon) available! The way the article walks through launching PerfMon (via perfmon.exe) and setting up counters for CPU, Memory, Disk, Network and applicationโ€‘specific metrics gives readers a solid starterโ€‘kit for realโ€‘world monitoring. I especially appreciate the coverage of counter selection, dataโ€‘collector sets, and export/logging functionality โ€” it shows how PerfMon is not just for quick live checks, but for longโ€‘term diagnostics and performance trending. For sysadmins, DevOps or SREโ€‘teams working on Windows-based systems, this tutorial reads like a readyโ€‘toโ€‘use playbook to proactively catch bottlenecks before they impact users. ๐Ÿ‘

Jason Mitchell
Jason Mitchell
6 months ago

This tutorial delivers an inโ€‘depth walkthrough of Windowsโ€™ builtโ€‘in Performance Monitor, clearly showing how to set up and leverage its full capabilitiesโ€”from realโ€‘time resource charts to longโ€‘term dataโ€‘collection sets. Itโ€™s particularly valuable in how it outlines which counters matter (CPU, memory, disk, network) and why they matter, transforming raw metrics into actionable insights. For DevOps engineers or intern training programs, the way the tutorial bridges โ€œwhat to captureโ€ and โ€œhow to interpret the dataโ€ is exactly what you need to build a performanceโ€‘monitoring mindset rather than just ticking boxes.

2
0
Would love your thoughts, please comment.x
()
x