Linux 部署Java工程常用命令(持续更新)

# 定位到那个目录

cd abc

# 查看该目录下文件

ll 

# 查看磁盘使用情况

df -l

# 遍历查看该目录下各个文件大小

du -ha

# 查看大于500M的文件

find . -type f -size +500M

# 限制指定用户在指定主机上运行某些命令

sudo su -

# 查看tomcat端口

ps -aux|grep tomcat

# 查看端口占用情况

netstat -tunlp|grep 18191

# 结束进程

kill -9 tomcat

# 查看日志

tail -f catalina.out

# 查看当前目录下的 warn.log 文件

find ./ -name warn.log

猜你喜欢

转载自bugyun.iteye.com/blog/2373183