- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to group processes with their name in PowerShell?
You can group the processes based on their properties. Here, we will group the processes based on their name, it would display how many instances of the process is running. Group-Object command is useful for it.
Command
The below command will group the object and sort the object based on their thread counts.
Get-Process |Group-Object Name | Select Name, Count |Sort-Object count - Descending
Output
Name Count ---- ----- svchost 91 chrome 34 RuntimeBroker 11 conhost 6 Code 6 WmiPrvSE 6 dllhost 4 RAVBg64 4 powershell 3 csrss 2 fontdrvhost 2 AcroRd32 2 taskhostw 2 SkypeBridge 1 smartscreen 1 smss 1 sihost 1 SkypeApp 1 SkypeBackgroundHost 1 sppsvc 1 StartMenuExperienceHost 1
- Related Articles
- How to sort the Processes based on their property name using PowerShell?
- How to get the running processes with the WMI object using PowerShell?
- How to get the running processes with the CIM instance using PowerShell?
- How to stop service with their dependent services in PowerShell?
- How to start windows service with display name in PowerShell?
- How to use Group-Object cmdlet in PowerShell?
- How to stop service with their dependent services using PowerShell?
- How to get all the processes on remote computers using PowerShell?
- How to get the port number of the processes using PowerShell?
- How to get all the processes on the local computer with Get-Process command using PowerShell?
- How to stop the service with the display name in PowerShell?\n
- How to create a new local group using PowerShell?
- How to delete the Azure Resource Group using PowerShell?
- How to get the local Administrators group members using PowerShell?
- How to retrieve the Azure VM resource group using PowerShell?

Advertisements