Home >Operation and Maintenance >Windows Operation and Maintenance >What is the cmd command to close a port?

What is the cmd command to close a port?

王林
王林Original
2020-05-31 10:43:0240150browse

The cmd command to close the port is "taskkill", which is used to end one or more tasks or processes. Methods to close the port: 1. Use the "taskkill /pid port number -t -f" command to force it to close; 2. Use the "taskkill /f /t /im process name" command to close it.

What is the cmd command to close a port?

The operating environment of this tutorial: Windows 7 system, Dell G3 computer.

The cmd command to close the port is "taskkill". This command is used to end one or more tasks or processes

The method of closing the port is as follows:

1. Directly force kill the specified port

taskkill /pid 4136 -t -f

What is the cmd command to close a port?

2. Close the port according to the program name

View the process corresponding to the PID

tasklist|findstr "127704"

What is the cmd command to close a port?

Close the process

 taskkill /f /t /im java.exe

What is the cmd command to close a port?

Recommended tutorial: windows tutorial

The above is the detailed content of What is the cmd command to close a port?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn