Create a TCP port in WinXP

Fuma

Executive Member
Joined
Jul 9, 2007
Messages
5,397
Reaction score
397
Location
Pretoria
we have a test machine that we do some stuff and a requirement came that I have to do some TCP/IP stuff and there has to be an available port that is listening.
I tried tried adding it through My Network Places ->properties->Advanced->Settings->Add->....and entered the relevant stuff.

But when I Netstat -a, I can't seem to find the new port I just created. Even after restarting the machine.

NB: This has to be a specific port that I need to create.

Any suggestion?
 
Listening for what? You generally have to have some application running that would listen on a port.
 
Once you "open" a port through a firewall, you'll also need an application which "listens" to that specific port.

You will not see if the port is open with netstat -a though.

A portscanner will tell you whether the port is open or not.

But it doesn't help to just open a port, you'll also need an app to listen to that port, or else nothing will happen.
 
Listening for what? You generally have to have some application running that would listen on a port.
There is this application in a production environment (which I have no idea about) that runs and and listens to a specific port and does some stuff.
So we are going to put the same application on this test machine to do what it does on production. I still need to find out what this application do. So now I just need to replicate it on this test machine.

I hope I'm making sense.
 
There is this application in a production environment (which I have no idea about) that runs and and listens to a specific port and does some stuff.
So we are going to put the same application on this test machine to do what it does on production. I still need to find out what this application do. So now I just need to replicate it on this test machine.

I hope I'm making sense.

Then you're not creating a port. You simply need to open the relevant port in the firewall and things should be good to go. To test it, you'll need an app listening on that port, as said.
 
App --- Port xx ---- Firewall ----- Network ---- Client PCs

When you run the app on the server machine it opens Port xx and listens on that port for incoming connections from Client PCs. What you were doing was basically opening that port on the firewall, if it wasn't open the connection would be refused when the client PC's try connect.
So yes, basically only once you've opened that port on the firewall and actually running the app on the box will see you a listening port in netstat.
 
So yes, basically only once you've opened that port on the firewall and actually running the app on the box will see you a listening port in netstat.
Thanks. I thought you could have an "unused" or "inactive" port reserved for the app when it runs.
I suppose I need to first run that application.
 
Thanks. I thought you could have an "unused" or "inactive" port reserved for the app when it runs.
I suppose I need to first run that application.

No, services bind to the ports they require when they run.
If something is already using that port, though, then the bind will fail.
 
Top
Sign up to the MyBroadband newsletter
X