Ping the specified port with the tcping command

Source: Internet
Author: User
Tags ack pings response code server port

Ping is a simple tool to test network connectivity, useful for the general user, but Ping has a disadvantage is that it can not specify the port, and if the source address ban Ping, the ping command on the same name. --Preface

tcping command is for TCP monitoring, you can also see the ping value, even if the source address ban Ping can be tcping to monitor the state of the server network, in addition to simple Ping, tcping one of the biggest feature is that you can specify the monitoring port.
The tcping command is simple to download tcping tools: http://www.elifulkerson.com/projects/tcping.php (Specific version: 32bit, 64bit) Place the downloaded Tcping.exe or Tcping64.exe file in the C:\Windows\System32 directory (the ping command is also in this directory) using the command: tcping64-d-t 127.0.0.1 6001

Note: If you download the Tcping.exe and did not change the filename, use in cmd to enter tcping-p IP xxx to use, If you download the 64bit Tcping64.exe and did not change the filename, you need to enter tcping64-p IP xxx for use in cmd

Official use of the tutorial

The NAME tcping-simulate "ping" over the TCP by establishing a connection to network hosts.  Measures the time for your system to [SYN], receive the target ' [Syn][ack] and send [ACK]. The "Travel time" for the ' last ACK ' is ' not ' included-only ' time it takes ' the ' to be ' on ' wire a ' sendin
G End. Synopsis tcping [-tdsvf46] [-I interval] [-N-Times] [-W interval] [b-N] [-R times][-j Depth] [--tee filename] [-f] de stination [Port] DESCRIPTION tcping measures the time it takes to perform a TCP 3-way handshake (SYN, Syn/ack, ACK) is
    Tween itself and a remote host.
    The travel time of the outgoing final ACK isn't included, only the (minimal) amount of time it has taken to drop it  The wire at the near end. This allows the "travel" (SYN, Syn/ack) to approximate the travel time of the ICMP (request, response) EQUIV
Alent. OPTIONS-4 prefer using ipv4-6 prefer using ipv6-t ping continuously until via stopped L-C-n count send _count_ pings and then stop.
    Default 4.  -I interval wait _interval_ seconds between pings.  Default 1.
    Decimals permitted.  -W interval wait _interval_ seconds for a response.  Default 2.
    Decimals permitted. -D include date and time on every output line-f Force sending at least one byte in addition to making the C
    Onnection.
    -G count give up after _count_ failed pings.
            -B type Enable audible beeps.  '-B 1 ' would beep ' on down '.
            If A host is up, but it is not, beep.  '-B 2 ' would beep ' on up '.
            If A host is down, the but now it up, beep.  '-B 3 ' would beep ' on change '.
            If A host is one way, but now is the other, beep.
    '-B 4 ' would beep ' always '.  -c only show output on a changed state-r count Every _count_ pings, we'll perform a new DNS lookup
    For the host in case it changed. -S Exit immediatEly upon a success.
    -V Print version and exit.  -S source_address use _source_address_ as the TCP client's source address.

    Must be a valid IP addresses on the client system.  -j Calculate jitter.
    Jitter is defined as the difference between the last response and the historical. -js depth Calculate jitter, as With-j but with a optional _depth_ argument.
    If _depth_ is specified tcping would use the prior _depth_ values to calculate a rolling average.  --tee _filename_ Duplicate output to the _filename_ specified. Windows can still not is depended upon to have a useful command line environment.   
    Don ' t tease me, *nix guys.  --file Treat the "destination" option as a filename.  That is file becomes a source of destinations, looped through on "a" by line basis.
    Some options Don ' t work in this mode and statistics won't be kept.
    Destination        A DNS name, an IP address, or (in "http" mode) a URL.  Don't specify the protocol ("http://") in "http" mode.
            Also do not specify server port via ":p ort" syntax. For instance: "Tcping http://www.elifulkerson.com:8080/index.html" would fail use the style: "Tcping www.el                       
    ifulkerson.com/index.html 8080 "instead.  Port A Numeric TCP port, 1-65535.
    If not specified, defaults to 80.  --header include a header with the command line arguments and timestamp.
    The Header is implied if using--tee.  --block use a "blocking" socket to connect. This is prevents-w from working, uses the default timeout of around, and seconds break other might b  Ehavior.   
However, it can detect an actively refused connection vs a timeout.  HTTP mode options-h use "http" mode. In HTTP mode we'll attempt to get the specified document and return additional values IncludiNg the document ' s size, HTTP response code, KBIT/S.
    -U in ' http ' mode, include the target URL on each output line.
    --post use Post instead of the get in HTTP mode.
    --head use head instead of the get in HTTP mode.
    --get shorthand to invoke the "HTTP" mode for consistency ' s sake. --proxy-server _proxyserver_ Connect to _proxyserver_ to request the URL rather than the server indicated in T
    He URL itself.  --proxy-port _port_ Specify the numeric TCP port of the proxy server.
    Defaults to 3128. --proxy-credentials Username:password Specify a Username:password pair which is sent as a ' proxy-authorization
: Basic ' header.
Return VALUE tcping returns 0 if all pings are successful, 1 if zero pings are and 2 for successful mixed. Bugs/requests BUGS and feature REQUESTS to the author via contacts information on Http://www.elifulkerson . com availability tcping is available at http://www.elifulkerson.com/projects/tcping.php 

Common commands:

-4/-6    (First use Ipv4/ipv6 address)-
D (       time to send the command)-
t (-       T is to keep the command running, knowing to exit with CTRL + C instructions)-
H       (using HTTP mode) -
u       (used with the-h command, output destination URL)-
n      (number of commands sent, default 4 times)-I        (time between sending commands, default 1s, can be decimal)-
W        ( Wait for response time interval, default 2s, can be decimal

Practical Application

c:\users\zhangyd>tcping64-d-h-u-N 10-i 0.1-w 0.1 xxx.xx.xxx.xx * * 6001 Pinging.  Press CONTROL-C to stop * * * Requesting from XXX.XX.XXX.XX: (for various reasons, kbit/s are an approximation) 2016:12:06 10:36:07 probing xxx.xx.xxx.xx:6001/tcp-http is open-time=204.694ms page:http://xxx.xx.xxx.xx rcv_time=203.528 status =200 bytes=583 kbit/s=~22.916 2016:12:06 10:36:07 probing xxx.xx.xxx.xx:6001/tcp-http is open-time=208.675ms page:http ://xxx.xx.xxx.xx rcv_time=208.560 status=200 bytes=583 kbit/s=~22.363 2016:12:06 10:36:08 Probing xxx.xx.xxx.xx:6001/ Tcp-http is open-time=246.553ms page:http://xxx.xx.xxx.xx rcv_time=1040.546 status=200 bytes=583 kbit/s=~4.482 2016:12 : 10:36:09 probing xxx.xx.xxx.xx:6001/tcp-http is open-time=181.520ms page:http://xxx.xx.xxx.xx rcv_time=183.293 STA tus=200 bytes=583 kbit/s=~25.446 2016:12:06 10:36:09 probing xxx.xx.xxx.xx:6001/tcp-http is open-time=195.658ms page:h ttp://xxx.xx.xxx.xx rcv_time=202.854 status=200bytes=583 kbit/s=~22.992 2016:12:06 10:36:10 probing xxx.xx.xxx.xx:6001/tcp-http is open-time=181.833ms page:http://xx x.xx.xxx.xx rcv_time=186.513 status=200 bytes=583 kbit/s=~25.006 2016:12:06 10:36:10 Probing- HTTP is open-time=227.706ms page:http://xxx.xx.xxx.xx rcv_time=226.750 status=200 bytes=583 kbit/s=~20.569 2016:12:06 1 0:36:11 probing xxx.xx.xxx.xx:6001/tcp-http is open-time=247.957ms page:http://xxx.xx.xxx.xx rcv_time=263.903 bytes=583 kbit/s=~17.673 2016:12:06 10:36:11 probing xxx.xx.xxx.xx:6001/tcp-http is open-time=235.967ms page:http: xxx.xx.xxx.xx rcv_time=187.247 status=200 bytes=583 kbit/s=~24.908 2016:12:06 10:36:11 probing xxx.xx.xxx.xx:6001/ Tcp-http is open-time=257.262ms page:http://xxx.xx.xxx.xx rcv_time=264.820 status=200 bytes=583 kbit/s=~17.612 Ping St
     Atistics for xxx.xx.xxx.xx:6001 probes sent.
Ten successful, 0 failed. Approximate trips times in milli-seconds:minimum = 181.520ms, Maximum= 257.262ms, Average = 218.782ms approximate download times in milli-seconds:minimum = 183.293ms, Maximum = 1040.546 MS, Average = 296.801ms

The meaning of the above order is interpreted as:
sends 10 packets (-N) to a server with IP xxx.xx.xxx.xx port 6001using http mode (-h) and displaying the target source URL address (-u) in the return data. and displays the date the packet was sent (-D)in the returned data row, specifying 0.1 seconds (-I 0.1)for each packet to be sent, and 0.1 seconds to wait for the packet (-W 0.1)

Note: When-T and-n exist at the same time, the-n is given precedence, which means that the tcping64-t-n xxx.xx.xxx.xx command sends only 10 packets, not the continuous sending of-t

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.