ps aux | grep -i correlation is a Unix/Linux command that lists running processes and keeps only lines containing correlation, ignoring letter case; it is not valid native PowerShell syntax as written.
On Linux, macOS, or WSL
-
ps auxlists running processes with details such as user, process ID, resource use, and command line. -
|passes that textual output to the next command. -
grep -i correlationdisplays lines containingcorrelation, with-imaking the search case-insensitive.
It only reads process information; it does not stop or modify anything. The results might also contain the grep -i correlation process itself.
In Windows PowerShell
The same text has a different meaning:
-
psis a Windows PowerShell alias forGet-Process.Get-Processreturns process objects, rather than the textual output produced by Unixps.^1^ -
auxis therefore interpreted as a process name supplied toGet-Process, not as Unixpsoptions. PowerShell will generally report that it cannot find a process namedaux. -
grepis not a standard PowerShell cmdlet. It works only if a separate executable, function, or alias namedgrepis installed.
The native PowerShell equivalent for searching the displayed process list is:
Get-Process |
Out-String -Stream |
Select-String -Pattern 'correlation' -SimpleMatch
Select-String is PowerShell’s text-search equivalent to grep; matching is case-insensitive unless -CaseSensitive is specified.^2^
If correlation is part of the process name, use object filtering instead:
Get-Process -Name '*correlation*'
This second form is preferable when searching process names, but it does not search complete command-line arguments.
References