tcping | Just ping a TCP port | TCP library

 by   akamensky Go Version: Current License: MIT

kandi X-RAY | tcping Summary

kandi X-RAY | tcping Summary

tcping is a Go library typically used in Networking, TCP applications. tcping has no bugs, it has no vulnerabilities, it has a Permissive License and it has low support. You can download it from GitHub.

tcping is a tool that allows to verify reachability of TCP port. The purpose of this tool is to allow for a monitoring of reachability of specific service on remote (or local) host. Unlike standard ping, fping or hping, this tool uses simple TCP connection to verify if port is listening and is agnostic of application protocols etc. Each check will simply open a connection and if successful it will immediately close it. While some applications may not like this, most will handle this will and will not cause any significant resource consumption. Currently: to start using this you will need Go language compiler, which you can get from golang.org.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              tcping has a low active ecosystem.
              It has 5 star(s) with 2 fork(s). There are 1 watchers for this library.
              OutlinedDot
              It had no major release in the last 6 months.
              There are 6 open issues and 0 have been closed. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of tcping is current.

            kandi-Quality Quality

              tcping has no bugs reported.

            kandi-Security Security

              tcping has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.

            kandi-License License

              tcping is licensed under the MIT License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              tcping releases are not available. You will need to build from source code and install.
              Installation instructions are not available. Examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi has reviewed tcping and discovered the below as its top functions. This is intended to give you an instant insight into tcping implemented functionality, and help decide if they suit your requirements.
            • main is the main entry point for testing
            • Try to connect to a port
            Get all kandi verified functions for this library.

            tcping Key Features

            No Key Features are available at this moment for tcping.

            tcping Examples and Code Snippets

            No Code Snippets are available at this moment for tcping.

            Community Discussions

            QUESTION

            Why is there a discrepancy between python sockets and tcp ping for the same IP:port destination?
            Asked 2021-Apr-02 at 13:36

            My setup:

            1. I am using an IP and port provided by portmap.io to allow me to perform port forwarding.
            2. I have OpenVPN installed (as required by portmap.io), and I run a ready-made config file when I want to operate my project.
            3. My main effort involves sending messages between a client and a server using sockets in Python.
            4. I have installed a software called tcping, which basically allows me to ping an IP:port over a tcp connection.

            This figure basically sums it up:

            Results I'm getting:

            1. When I try to "ping" said IP, the average RTT ends up being around 30ms consistently.
            2. I try to use the same IP to program sockets in Python, where I have a server script on my machine running, and a client script on any other machine but binding to this IP. I try sending a small message like "Hello" over the socket, and I am finding that the message is taking a significantly greater amount of time to travel across, and an inconsistent one for that matter. Sometimes it ends up taking 1 second, sometimes 400ms...

            What is the reason for this discrepancy?

            ...

            ANSWER

            Answered 2021-Apr-02 at 13:36

            What is the reason for this discrepancy?

            tcpping just measures the time needed to establish the TCP connection. The connection establishment is usually completely done in the OS kernel, so there is not even a switch to user space involved.

            Even some small data exchange at the application is significantly more expensive. First, the initial TCP handshake must be done. Usually only once the TCP handshake is done the client starts sending the payload, which then needs to be delivered to the other side, put into the sockets read buffer, schedule the user space application to run, read the data from the buffer in the application and process, create and deliver the response to the peers OS kernel, let the kernel deliver the response to the local system and lots of stuff here too until the local app finally gets the response and ends the timing of how long this takes.

            Given that the time for the last one is that much off from the pure RTT I would assume though that the server system has either low performance or high load or that the application is written badly.

            Source https://stackoverflow.com/questions/66917417

            QUESTION

            Azure VM Port Closed while TCPing
            Asked 2018-Sep-08 at 12:47

            I have an Azure VM running Ubuntu 14.04. It is running a basic NGINX configuration listening on port 8443 and proxying to localhost 8080 which is being listened to by a service running a script which I am working on.

            In my inbound port rules I have opened port 8443 with source IP as my office IP, and destination IP as the VM's private IP, over TCP.

            After research I have discovered that you can not ping an Azure VM, though with tools such as psping you can check access to specific ports.

            Due to being on OSX I have been trying to use TCPing, trying both DNS and public IP along with port number. I get the response 'port 8443 closed'.

            I have checked ports on my VM with netstat and can confirm that nginx is listening on port 8443 and python (my service running a script) is listening on port 8080.

            Here is my sites-enabled nginx configuration:

            ...

            ANSWER

            Answered 2018-Sep-08 at 12:47

            You should check all the following :

            • Network Security Groups
            • Load Balancer configuration (if exists)
            • Configure the Linux Firewall

            You can also try to ping the VM port using PsPing (If your OS is Windows)

            Source https://stackoverflow.com/questions/52229029

            QUESTION

            Can docker host ping its containers?
            Asked 2017-Mar-21 at 12:06

            I'm running docker on mac, my docker is running centos and ifconfig shows eth0 address is "172.17.0.2".

            I tried to ping this 172.17.0.2 in my terminal but failed. So except using "docker run" command, is there a way to access to container by it's services like sshd?

            I searched internet and found port mapping, so I added "-P" option to run it:

            ...

            ANSWER

            Answered 2017-Mar-21 at 12:06

            Can docker host ping its containers?

            no.

            not on Mac, at least.

            and on linux, it only works incidentally and is not something you should do anyways.

            Docker isn't a virtual machine and shouldn't be treated like it is. You should be thinking of it as a virtual application, instead.

            if you need to get into the service via tcp/ip port, you need to map the port number from the container.

            docker run -p 1234:1234 my-image

            where 1234 is the tcp/ip port.

            this creates a service listening at localhost:1234 on your host machine.

            Source https://stackoverflow.com/questions/42926388

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install tcping

            You can download it from GitHub.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/akamensky/tcping.git

          • CLI

            gh repo clone akamensky/tcping

          • sshUrl

            git@github.com:akamensky/tcping.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular TCP Libraries

            masscan

            by robertdavidgraham

            wait-for-it

            by vishnubob

            gnet

            by panjf2000

            Quasar

            by quasar

            mumble

            by mumble-voip

            Try Top Libraries by akamensky

            argparse

            by akamenskyGo

            nodev

            by akamenskyJavaScript

            base58

            by akamenskyGo

            envparse

            by akamenskyGo

            XpressJ

            by akamenskyJava