Netstat filtering query
Running Windows 2008 Server I have run: netstat -ano | findstr <PID> To find the IP's, state, and port of all connections relating to a certain PID. What I want to do now is just filter off those relating to port 25 and in ESTABLISHED state Does anyone know how I can do this?
April 14th, 2011 3:22pm

Or you can do it with regular expressions to avoid running it through the findstr process twice. This also allows you to match a single line based on multiple elements with logical AND and OR etc. netstat -ano | findstr :25.*EST netstat -ano | findstr "80.*EST | 443.*EST"
Free Windows Admin Tool Kit Click here and download it now
September 19th, 2011 8:53pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics