Life, half is memory, half is to continue.
玩转Mac终端:Mac 终端常用知识
By Vincent. @2020.9.29
玩转Mac终端:Mac 终端常用知识

查看被占用的端口

lsof -i:port

TQ-WXdeMacBook-Pro:~ anonyper$ lsof -i:8081

COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME

uwsgi 22117 anonyper 3u IPv4 0x90a5adf44866b61d 0t0 TCP *:sunproxyadmin (LISTEN)

杀掉被占用的端口

Kill PID

Kill -9 PID 强制杀掉

TQ-WXdeMacBook-Pro:~ anonyper$ kill 22117

mac 命令行常用命令:

查看IP地址

ifconfig //windows上是ipconfig

ping 给一个主机发请求(可测试对方服务器是否可用)

快捷键

finder 常用快捷键

扫码分享收藏
扫码分享收藏