您现在的位置是: 首页 > 运维 Linux no space left on device 出现设备上没有空间问题
Linux no space left on device 出现设备上没有空间问题
2020-06-09 【运维】 1837人已围观 3521次浏览
简介Linux no space left on device 出现设备上没有空间问题
今早发现 Redis 服务不可用,提示设备上没有空间,想到服务器上磁盘是完全够用的,不应该出现此类问题才对,ssh 连上服务器,df -h 发现磁盘已经 100% 了,怀疑是某日志文件过大导致
首先是在系统根目录执行下面命令,查看具体是那个文件夹导致磁盘消耗
cd /
du -sh *
发现 /root 文件夹消耗了 60 多G的空间,这是完全不合理的,之后进入 /root 文件夹,查看所有的文件(包含隐藏文件)
cd /root
ls -la
输出的信息中,发现了三个常见的,会比较大的文件夹
.npm
.nvm
.pm2
首先第一个就怀疑的是 .pm2 文件夹,因为会输出大量的日志文件,执行下面的命令查看具体的磁盘消耗
du -h --max-depth=1 /root/.pm2
输出的信息中,/root/.pm2/logs 文件夹,就占用了 59G 的磁盘空间
之后进入 logs 文件查看,发现都是一些很久以前的没用的日志信息
果断删除,磁盘空间恢复,问题解决,Redis 也正常了
很赞哦! (0)
相关文章
- CentOS 安装 Docker
- Windows CMD 常用命令
- CentOS 安装Node.js
- Linux 查看磁盘、磁盘分区、挂载磁盘、卸载磁盘操作
- CentOS 安装Python3
- Redis 提示 MISCONF Redis is configured to save RDB snapshots, but it is currently not able to persist on disk 解决方案
- mybatis中大于等于小于等于的写法
- Debian apt 使用国内镜像
- nginx 出现 the "ssl" directive is deprecated, use the "listen ... ssl" directive instead in 错误解决方案
- Docker 批量操作命令
点击排行
- Error in execution; nested exception is io.lettuce.core.RedisCommandExecutionException: ERR DISABLE You can't write or read against a disable instance
- RocketMQ 出现 sendDefaultImpl call timeout 问题
- Debian apt 使用国内镜像
- 类 BASE64Decoder 程序包 sun.misc 找不到符号
- SpringBoot @NotBlank 不生效问题
- 记一次 Mybatis-Plus 自动填充无效问题解决
- nuxt 项目完整部署方案
- SpringBoot 2.x 文件上传出现 The field file exceeds its maximum permitted size of 1048576 bytes
站长推荐
猜你喜欢
- Oracle ORA-12541:TNS:no listener错误解决方法
- 记一次 Mybatis-Plus 自动填充无效问题解决
- python scrapy 出现 DEBUG: Filtered offsite request to 错误
- 解决Lost connection to MySQL server at 'reading initial communication packet' 的方法
- PHP 在执行 composer install 时出现提示 PHP Fatal error: Allowed memory size of XXXXXX bytes exhausted <...>
- mysql 索引过长1071-max key length is 767 byte
- Win10 安装适用于Linux的Windows子系统
- Python自动生成和安装requirements.txt文件中的依赖
- Error in execution; nested exception is io.lettuce.core.RedisCommandExecutionException: ERR DISABLE You can't write or read against a disable instance
- Linux no space left on device 出现设备上没有空间问题