Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

window command to clear a network port in use

Posted on 2009-07-07
4
Medium Priority
?
6,405 Views
Last Modified: 2013-12-04
Is there any windows script/command used to clear a network port in use?
For example,  how to clear a port "1099"  if it is in listening state on windows xp system?
0
Comment
Question by:JOEANEMAV
  • 3
4 Comments
 
LVL 47

Accepted Solution

by:
Donald Stewart earned 1200 total points
ID: 24797518
From here
http://wiki.answers.com/Q/What_is_the_Dos_command_to_close_an_open_port
 
1)Type

netstat -a -o -n

in command prompt.

2) find the PID number for that port number
3) goto task manager and end process the corresponding PID number.  
0
 
LVL 9

Assisted Solution

by:PC_Rob
PC_Rob earned 300 total points
ID: 24797553
You can use netstat -b at the command line to show the executable that is using the port in question.

Once you know what is using it, you can stop that program top clear the port.

Regards,

Rob
0
 
LVL 47

Assisted Solution

by:Donald Stewart
Donald Stewart earned 1200 total points
ID: 24797608
I also like to use this great utility to both view and close open ports
 
 
Currports
http://nirsoft.net/utils/cports.html 
0
 
LVL 47

Expert Comment

by:Donald Stewart
ID: 24806896
"B" ????
what possible more info is needed?? It was a clear and concise answer.
0

Featured Post

2017 Webroot Threat Report

MSPs: Get the facts you need to protect your clients.
The 2017 Webroot Threat Report provides a uniquely insightful global view into the analysis and discoveries made by the Webroot® Threat Intelligence Platform to provide insights on key trends and risks as seen by our users.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

So, you're experiencing issues on your network and you've decided that you need to perform some tests to determine whether your cabling is good.  You're likely thinking that you may need to spend money which you probably don't have on hiring/purchas…
Whether you've completed a degree in computer sciences or you're a self-taught programmer, writing your first lines of code in the real world is always a challenge. Here are some of the most common pitfalls for new programmers.
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…

886 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question