mac 查看目前哪些进程占用哪些端口

 lsof -nP  | grep TCP | grep LISTEN

lsof -i :TCP

原文地址:https://www.cnblogs.com/diegodu/p/6855840.html