One of the challenging tasks while working in the project team is to perform the necessary connectivity test though services don’t exist.
This is often you have to do when you are working in a DMZ environment for migration or new projects. Let’s take a real-time example – you are working on migration, and you have to ensure connectivity exists between application “A” to “B” on a particular port.
Well. It’s straightforward you can perform telnet but how about when “B” doesn’t have any service running? That’s where you need the port listener to help in this situation.
If you have a similar situation or feel this would be beneficial for you at work, then here are few ways to achieve this in Windows or UNIX platform.
To create post listener in Windows OS
To have a port listener on a specific port in Windows, you can use the “Port Listener” utility.
This utility is available for free for Windows 95 to Windows 10.
Download Post Listener as zip or exe format from here
In this guide, I will download the exe format
Double click on downloaded postlistener.exe file
It will prompt to select the location to extract the files, click on unzip
Go to path where you have extracted the files, in this example; I have at c:listener
Double click on listener to start the utility
Enter the port number which you want to test and click on start
In the above example, I have started listening port on 5500, and it’s time to validate if it’s running.
Open a command prompt and run netstat to validate if port 5500 is listening
So yes, now I have created a port listener successfully in Windows.
To create post listener in Linux OS
The procedure is slightly different in Linux; here we will use netcat (nc) command to start the listener.
To install nc, you can use yum command
yum install nc
Once installed, use the following command to start the port listener as 5500 in the background.