Mac OS viewing ports and killing processes

Time:2020-2-23

See
Sudo lsof – I: Port

sudo lsof -i:9501

 

COMMAND PID USER   FD   TYPE  DEVICESIZE/OFF NODE NAME
php   7748 Dang   58u  IPv6 0x613f359336d889a3 0t0  TCP *:8095 (LISTEN)

Kill process

sudo kill -9 7748