端口占用

来源:互联网 发布:简明python教程在哪买 编辑:程序博客网 时间:2024/04/29 17:39

假如我们需要确定谁占用了我们的9506端口

1、Windows平台
在windows命令行窗口下执行:

C:/>netstat -aon|findstr "9506"TCP    127.0.0.1:9506         0.0.0.0:0              LISTENING       2016

看到了吗,端口被进程号为2016的进程占用,继续执行下面命令:

C:/>tasklist|findstr "2016"tor.exe                     2016 Console                 0     16,064 K
很清楚吧,tor占用了你的端口。