linux学习笔记—常用命令

141 阅读1分钟

查看软件信息

显示隐藏文件夹

ls -a

查看node运行进程及端口号

ps -ef|grep node

查看ip和mac地址

查看dns

nslookup

查看进程id

ps ax | grep PM2

lsof命令

根据进程pid查端口号

lsof -i | grep pid

根据端口port查进程

lsof -i:port

根据用户查进程和端口

lsof -i|grep user

netstat命令

根据进程pid查端口

netstat -nap | grep pid

根据端口查进程

netstat -nap | grep port