Created
November 2, 2021 15:38
-
-
Save besteban1989/653c0c9c3b8536427b37dcbb2128747b to your computer and use it in GitHub Desktop.
Connectivity Testing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# method 1: if icmp is enabled in the target server then | |
ping $DESTINATION_IP | |
# method 2: run telnet on a port where a service is listening. The target port must be binded (a service listening) so the test can be performed. | |
telnet $DESTINATION_IP $PORT | |
# method 3 in case there is no service listening you can ask the target server owner/operator to install netcat. | |
## A. In the destination server run netcat with -l <port>. Netcat will bind to the specified port in order to listen. This is handy when there is no services running but want to ensure connectivity exists. | |
netcat -l $PORTNUMBER | |
## B. In the source server you can run telnet or netcat in order to test the connectivity to the destination server: | |
telnet $DESTINATION_IP $PORT | |
# or | |
netcat -vz $DESTINATION_IP $PORT |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment