![](https://img-blog.csdnimg.cn/20201014180756757.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
linux
csdnindex
互联网打工人
展开
-
centos服务器磁盘空间满了,无法进行文件操作
问题: 在linux环境下,用vi打开某文件时,提示Write error in swap file 原因:磁盘空间已满 解决:用df -h命令查看磁盘使用情况,删除该区块中无用的文件 常用命令: df -h:查看系统空间大小 du -h --max-depth=1:查看该目录空间占用 du -sh *:查看该目录下所有文件及目录的大小 ...原创 2019-02-26 11:40:26 · 3583 阅读 · 0 评论 -
初写shell脚本 ,实现centos系统检测tomcat启动状态
shell脚本命令解释(待扩展): #!/bin/sh //制定shell 脚本运行环境; ps -ef | grep $TomcatName | grep -v 'grep' | awk '{print $2}' 首先用ps -ef | grep tomcat 获得了tomcat进程信息,这样出来的结果中会包含grep本身, 因此通过 | grep -v grep 来排除grep...原创 2019-07-05 14:00:22 · 868 阅读 · 0 评论