windows查看端口占用

windows 有时候 netstat 可能无法正确显示占用端口的进程

netstat -ano| findstr '30020'

Caused by: java.net.BindException: Address already in use: bind 

netstat -ano| findstr '30020' 并没有相关进程;

可以在powershell中使用

Get-Process -Id (Get-NetTCPConnection -LocalPort 30020).OwningProcess

powershell

posted @ 2025-04-03 17:30  BigOrang  阅读(463)  评论(0)    收藏  举报