杀掉window占用端口

C:Userspeihp>netstat -aon|findstr "8080"
TCP 0.0.0.0:8080 0.0.0.0:0 LISTENING 5600
TCP [::]:8080 [::]:0 LISTENING 5600

C:Userspeihp>tasklist|findstr "5600"
javaw.exe 5600 Console 3 490,224 K

C:Userspeihp>taskkill /f /t /im javaw.exe
成功: 已终止 PID 5600 (属于 PID 5848 子进程)的进程。

原文地址:https://www.cnblogs.com/dapeng520/p/4788268.html