NETSTAT Command Multiple Strings

itsmevic
itsmevic used Ask the Experts™
on
It is possible to search on multiple strings within a Netstat -aont 2 | findstr " "

i.e.

Netstat -aont 2 | findstr "xxx.xx.xxx.xxx","xxx.xxx.xx.xxx""etc","etc","etc"

Or can you only do it by one IP at a time?
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Most Valuable Expert 2018
Distinguished Expert 2018
Commented:
Yes; just use several "/c":
Netstat -aont 2 | findstr /c:"xxx.xx.xxx.xxx" /c:"yyy.yyy.yyy.yyy" /c:"zzz.zzz.zzz.zzz"

Author

Commented:
Awesome.  Thanks!

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial