How to Use Netstat Commands
Netstat is a utility that you can use to display your computer's connections to the Internet. It's a useful tool for monitoring connections and diagnosing problems. You can tweak netstat commands by adding arguments at the end of the command. Since netstat is run from a command prompt, it doesn't require you to install special software.
Close all open programs on your computer. Click the start button. Click "Run." Type the word "cmd" in the run box. This will display a command prompt.
Type in "netstat" at the command prompt, followed by the argument that you want to use. For a list of all netstat arguments, type "netstat /?."
Use "netstat -a" to get a list of all open network and Internet connections. To see IP addresses rather than names, use the "-an" argument.
Specify which type of protocols are in use. Type "netstat -p TCP" to show only TCP connections. Type "netstat -p UDP" to show UDP traffic.
Enter "netstat interval 10" to have netstat information displayed every 10 seconds. Replace the 10 with any number you want to use. To stop, press "ctrl" and "c" at the same time.
Create a file by typing ">" followed by the file location and name of the text file after your netstat command. For example, "netstat -a >c:\log.txt" will create a file called log.txt on the C drive. The file will contain the netstat results. Open the file with Windows notepad.
Check out active routes by typing "netstat -r." This displays your routing tables, including destination address, net mask and gateway.