当前位置: 首页 > news >正文

linux 清理空间

1. 根目录下执行命令,查看每个目录下文件大小总和

root@vm10-88-88-3 /]# du -h --max-depth=1 
79M     ./tmp
123M    ./etc
4.0K    ./media
4.0K    ./srv
104M    ./boot
5.3G    ./var
0       ./sys
8.6M    ./dev
196G    ./usr
4.0K    ./mnt
285M    ./opt
87G     ./root
836K    ./run
7.8G    ./home

2.查询到root目录下有87G文件,搜索大于200M的文件

[root@vm10-88-88-3 /]# find /root  -size +200M -exec du -h {} \;
476M    /root/logs/ant/business.log.20240314
290M    /root/logs/ant/business.log.20240203
229M    /root/logs/ant/business.log.20240221
380M    /root/logs/ant/business.log.20240317
382M    /root/logs/ant/business.log.20240323
271M    /root/logs/ant/business.log.20240213
312M    /root/logs/ant/business.log.20240302
379M    /root/logs/ant/business.log.20240311
312M    /root/logs/ant/business.log.20240229
493M    /root/logs/ant/business.log.20240305
319M    /root/logs/ant/business.log.20240301
270M    /root/logs/ant/business.log.20240216
404M    /root/logs/ant/business.log.20240319

3.到对应目录下删除文件

http://www.lryc.cn/news/325520.html

相关文章:

  • C语言:给结构体取别名的4种方法
  • 今天聊聊Docker
  • 【C语言】结构体
  • Git基础(24):分支回退
  • 复试专业前沿问题问答合集1
  • C++标准库中提供的用于处理正则表达式的类std::regex
  • .NET Core 服务实现监控可观测性最佳实践
  • AI基础知识扫盲
  • 分布式系统面试全集通第一篇(dubbo+redis+zookeeper----分布式+CAP+BASE+分布式事务+分布式锁)
  • Prompt-RAG:在特定领域中应用的革新性无需向量嵌入的RAG技术
  • 线性代数 - 应该学啥 以及哪些可以交给计算机
  • 力扣面试150 Pow(x, n) 快速幂 负指数
  • 连接navicat报错2059 解决办法
  • Unity-UGUI系统
  • 配置AC和AP上报KPI指标信息实验
  • 深度学习Trick
  • c++顺序表(连续插入删除)
  • [综述笔记]A Survey on Deep Learning for Neuroimaging-Based Brain Disorder Analysis
  • 【C++练级之路】【Lv.16】红黑树(冰与火的碰撞,红与黑的史诗)
  • 政安晨:【Keras机器学习实践要点】(三)—— 编写组件与训练数据
  • 数据库系统概论(超详解!!!) 第四节 关系数据库标准语言SQL(Ⅲ)
  • 如何使用Python进行网络安全与密码学【第149篇—密码学】
  • 应急响应-Web2
  • 复试专业前沿问题问答合集8-1——CNN、Transformer、TensorFlow、GPT
  • 用Python做一个植物大战僵尸
  • Win11文件右键菜单栏完整显示教程
  • 【Python实用标准库】argparser使用教程
  • 伦敦金与纸黄金有什么区别?怎么选?
  • 化工企业能源在线监测管理系统,智能节能助力生产
  • C/C++ 一些使用网站收集...