Just a quick sanity check here.
Can you ping a specific port of a machine, and if so, can you provide an example?
I'm looking for something like ping ip address portNum.
|
Just a quick sanity check here. Can you ping a specific port of a machine, and if so, can you provide an example? I'm looking for something like |
||||
|
|
|
You can't ping ports, as Ping is using ICMP which doesn't have the concept of ports. Ports belong to the transport layer protocols like TCP and UDP. However, you could use nmap to see whether ports are open or not
Edit: As flokra mentioned, nmap is more than just a ping-for-ports-thingy. It's the security auditers and hackers best friend and comes with tons of cool options. Check the doc for all possible flags. |
|||||||||||||
|
|
Open a telnet session to the specific port, for example:
To close your session, hit ctrl-]. |
|||||||||
|
|
You can use PaPing: http://code.google.com/p/paping
|
|||||||||||||
|
|
No, you can't, because ping uses the ICMP protocol, which doesn't even have a conecpt of ports. |
|||||||
|
|
Ping is very specific but if you want to check whether a port is open or not, and are running a Windows box then PortQry is your friend. I've only used it for testing Domain Controllers for connectivity issues, but it worked a treat for that, so should work for you. |
|||||||||
|
|
No. There's no guarantee that the service running on the port understands ping. It also opens up the question of what "flavor" of port you want to ping, TCP or UDP? Since the ping "protocol" uses neither (ping is implemented using ICMP), it doesn't make a lot of sense. |
|||
|
|
|
I'm quite sure that Nagios check_tcp probe does what you want. They can be found here and although designed to be used in a Nagios context, they're all standalone programs.
|
|||
|
|
|
This is the only solution that works for VPNs on Windows Vista or Windows 7, as other listed answers simply do not function. This answer was previously deleted and should not have been, as this is the only solution for a real-world common case. Since there is no appeal allowed for the delete, I am reposting it to save others the frustration I had with trying to use the other answers. The example below finds which IPs on the VPN that have VNC/port 5900 open on Windows 7. A short Python (v2.6.6) script to scan a given list of IPs and Ports:
Results looked like:
The four variables at the top would need to be changed to be appropriate to whatever timeout, network, hosts, and ports that are needed. ` seconds on my VPN seemed to be enough to work properly consistently, less didn't (always) give accurate results. On my local network, 0.5 was more than enough. |
|||
|
|
|
i'm feeling lucky on google for “ping a specific port”: http://philwilks.blogspot.com/2008/01/ping-specific-port.html, so NO, you cannot ping a specific port you can use nmap though: |
|||
|
|
|
If you are running a *nix operating system try installing and using "zenmap", it is a GUI for nmap and has several useful scan profiles which are a great help to the new user. |
|||
|
|
|
Here's a quick and dirty .NET console app:
|
|||
|
|
|
Or instead of paping you could use cryping which has been around much longer and supports pinging of some services as well as ports. |
|||
|
|
|
Try port knocking software. Personally I use KnockKnock ( http://sourceforge.net/projects/knockknock/ ). It remembers the combination of ports and the IP. |
|||
|
This question is protected to prevent "thanks!", "me too!", or spam answers by new users. To answer it, you must have earned at least 10 reputation on this site.