Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I want to see if traffic gets through on a specific port on another machine. Is there a simple way to test for this?

share|improve this question
add comment

5 Answers

up vote 22 down vote accepted

I found a hiddem gem the other day from Microsoft that is designed for testing ports:

Portqry.exe

"Portqry.exe is a command-line utility that you can use to help troubleshoot TCP/IP connectivity issues. Portqry.exe runs on Windows 2000-based computers, on Windows XP-based computers, and on Windows Server 2003-based computers. The utility reports the port status of TCP and UDP ports on a computer that you select. "

share|improve this answer
add comment

Use the telnet command to connect to the server on the specified port, and see if a connection can be established.

Success:

$ telnet my_server 25
220 my_server ESMTP Postfix

Fail:

$ telnet my_server 23632
Connecting To my_server...Could not open connection to the host, on port 23632:
Connect failed
share|improve this answer
2  
doesn't work for UDP. –  Adriano Varoli Piazza Jul 2 '09 at 20:23
    
UDP is connectionless.. –  Amalgovinus Jun 23 at 18:46
add comment

Telnet will work for TCP.

Netcat is a better tool for these sorts of things, including UDP, watch out though, some AV softwares consider it an 'evil hacker tool'

share|improve this answer
add comment

the following command will list all ports in use on the machine...

netstat -a

The output contains the protocol, local address, foreign address and current state

Netstat documentation on microsoft.com

share|improve this answer
2  
Question asks about open ports on a remote machine, not local. –  Chris S Jun 26 '13 at 13:04
add comment

'netstat' is you friend.

share|improve this answer
1  
Local machine yes, remote machine no. –  Joe Jul 2 '09 at 18:04
    
This answer was posted before the edit that specified that it's about a port on remote machine. –  quosoo Jul 2 '09 at 18:11
add comment

protected by Chris S Jun 26 '13 at 13:07

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.