How to ping a port

Dr. McKay

Well-known member
Registered
Joined
Nov 26, 2016
Messages
565
Points
28
Just a quick question here!

Can I ping a specific port of my VPS, and it will tell me if it was closed or opening. If so, can you provide an example?

I'm looking for something like ping port status.
 

vpsrus

Well-known member
Hosting Provider
Registered
Joined
Jan 17, 2017
Messages
92
Points
0
Do you want to ping or do you want to scan the ports????

If is only ping you can not use ping command it is an ICPM and don't have a port concept you can otherwise use nmap or paping.exe you can google them and install on your windows desktop.

If it is scan you can do online at http://mxtoolbox.com/PortScan.aspx insert your IP address and it gives you the open and closed ports
 

Dr. McKay

Well-known member
Registered
Joined
Nov 26, 2016
Messages
565
Points
28
Do you want to ping or do you want to scan the ports????
I am not sure what is the difference between a ping and scanning a port but I want to know all the details about a port is opening or closed on my hosting.

If is only ping you can not use ping command it is an ICPM and don't have a port concept you can otherwise use nmap or paping.exe you can google them and install on your windows desktop.

If it is scan you can do online at http://mxtoolbox.com/PortScan.aspx insert your IP address and it gives you the open and closed ports
Can I check port from my SSH? I don't want to use tools because I rarely remember all the tools on the internet.
 

vpsrus

Well-known member
Hosting Provider
Registered
Joined
Jan 17, 2017
Messages
92
Points
0
If your OS is Centos or RedHat you can ssh and issue a command:

nmap -sT -O localhost

if it is not installed run yum install nmap -y
 

hostens

Well-known member
Hosting Provider
Registered
Joined
Jan 18, 2017
Messages
215
Points
28
Sometimes you can find telnet command useful for checking specific port. For example if you want to know is SSH running on other server just:

Code:
telnet server_ip port_number
Result:

Code:
$ telnet xx.xx.xx.xx 22
Trying xx.xx.xx.xx...
Connected to server.hostname.
Escape character is '^]'.
SSH-2.0-OpenSSH_5.3
 

hfav

Active member
Registered
Hosting Provider
Joined
Jan 18, 2017
Messages
83
Points
8
If you are using windows computer, you can use PsPing Command. You will be able to ping any ports.

https://technet.microsoft.com/en-us/sysinternals/psping.aspx

C:\PSTools>psping cpanel.hostfav.com 2087

PsPing v2.01 - PsPing - ping, latency, bandwidth measurement utility
Copyright (C) 2012-2014 Mark Russinovich
Sysinternals - www.sysinternals.com

Pinging 72.52.114.71 with 32 bytes of data:
5 iterations (warmup 1) ping test:
Reply from 72.52.114.71: 78.71ms
Reply from 72.52.114.71: 78.49ms
Reply from 72.52.114.71: 79.60ms
Reply from 72.52.114.71: 77.41ms
Reply from 72.52.114.71: 79.15ms

Ping statistics for 72.52.114.71:
Sent = 4, Received = 4, Lost = 0 (0% loss),
Minimum = 77.41ms, Maximum = 79.60ms, Average = 78.66ms
 

Collabora

Well-known member
Registered
Joined
Jan 24, 2017
Messages
123
Points
18
Telnet is a good way. You can try netstat also (local)

netstat -atn # For tcp
netstat -aun # For udp
netstat -atun # For both
 

vpsrus

Well-known member
Hosting Provider
Registered
Joined
Jan 17, 2017
Messages
92
Points
0
SSH to your host issue CLI

nmap -sT -O localhost

this is the output

Starting Nmap 5.51 ( http://nmap.org ) at 2017-01-26 04:15 CET
Nmap scan report for localhost (127.0.0.1)
Host is up (0.000075s latency).
Other addresses for localhost (not scanned): 127.0.0.1
Not shown: 985 closed ports
PORT STATE SERVICE
21/tcp open ftp
22/tcp open ssh
25/tcp open smtp
53/tcp open domain
110/tcp open pop3
143/tcp open imap
465/tcp open smtps
587/tcp open submission
783/tcp open spamassassin
993/tcp open imaps
995/tcp open pop3s
2525/tcp open ms-v-worlds
3306/tcp open mysql
8081/tcp open blackice-icecap
8084/tcp open unknown
 

vpsnet

Member
Registered
Hosting Provider
Joined
Jan 26, 2017
Messages
52
Points
8
Using nmap for scaning ports:

Better to use -PN option:
-PN: Treat all hosts as online -- skip host discovery
-O option not required if you are scaning only for open ports:
-O: Enable OS detection
Also good idea is to use port range
-p <port ranges>: Only scan specified ports

nmap -PN -p 1-65535 IP_ADDRESS/OR_RANGE
 
Newer Threads
Replies
8
Views
6,465
Replies
6
Views
8,974
Latest Threads

Latest Hosting OffersNew Reviews

Sponsors

Tag Cloud

You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an alternative browser.

Top