On Mac how check the port the some process own
You can check the port that a process owns on a Mac by following these steps:
- 
Open the Terminal app on your Mac.
 - 
Type the command "lsof -i :port_number" (replace "port_number" with the actual port number you want to check) and hit Enter.
 - 
The command will display a list of processes that are using the specified port. Look for the process that you are interested in and note down its PID (process ID) number.
 - 
Type the command "ps -p PID" (replace "PID" with the actual PID number you noted down) and hit Enter.
 - 
The command will display information about the process, including its name and other details.
 - 
You can also use the "netstat" command to check the status of all open ports on your Mac. Type "netstat -an | grep LISTEN" and hit Enter to display a list of all open ports and the processes that are using them
 
原文地址: https://www.cveoy.top/t/topic/c8Ms 著作权归作者所有。请勿转载和采集!