windows查看端口占用以及关闭相应的进程

windows查看端口占用以及关闭相应的进程

1.查看所有的端口占用情况

1
2
netstat -ano
1

查看所有端口

2.查看指定端口的占用情况

1
2
netstat -aon|findstr "8080"
//端口被占用就显示出来,没被占用就不显示

image-20220824104910848

3.查看PID对应的进程

1
shtasklist|findstr "1672"

image-20220824104957247

4、结束该进程

1
taskkill /f /t /im WeChat.exe

windows查看端口占用以及关闭相应的进程
https://blog.readcode.top/posts/8c23685c.html
作者
YuBaiCai
发布于
2022年8月26日
许可协议