当前位置:网站首页>How to troubleshoot the problem of too many inodes
How to troubleshoot the problem of too many inodes
2022-07-25 06:14:00 【Brother Xing plays with the clouds】
When it comes to The server Inodes Call the police , The troubleshooting process is as follows
Operating system environment :CentOS6.8
One 、 Use df -i Check which partition uses the most • In this way, the problem partition is located first
Two 、 Enter this partition , Use the file count script
# File count script
#!/bin/bash
for i in `ls`; do file_num=`find ./$i/ -type f -print | wc -l` echo "$i,$file_num" done
• This script will count the number of files in each directory under the current directory , In this way, you can find the directory with the most files , Then check layer by layer , You can locate the problem directory .
3、 ... and 、 Delete in small batches
ls | grep '^' | xargs -n 100 rm -f # Delete the listed files , With 100 One for a group
# This instruction is used to avoid "argument list too long " • Finally, don't forget to check the cause of the problem
Finally, share the problems encountered by the writer • I used the method of appeal to find out /var/spool/postfix/maildrop/ There are a lot of documents
The reason is that the system is executing cron When the task , Will cron Execute the output information in the script (output) And alarm information (warning) Send by email to cron owner , And my The server It's closed postfix , Cause mail sending failure , Small files are piled up maildrop Under the table of contents . If sendmail or postfix The normal operation , Will be in /var/mail A large number of mail files are piled under the directory . • resolvent : modify crond The configuration file
vim /etc/crontab take MAILTO=root Replace with MAILTO="", Need to restart crond Service is OK
边栏推荐
猜你喜欢

Android interview question: why do activities rebuild ViewModel and still exist—— Jetpack series (3)

NFT: how to improve rentable NFT (erc-4907)

VO, dto, do, Po distinction and use
![[node] the service port is occupied error: listen eaddinuse: address already in use::: 9000- how to close the port started by node](/img/06/b90fa310158669696f94f79ef4cc5a.png)
[node] the service port is occupied error: listen eaddinuse: address already in use::: 9000- how to close the port started by node

剑指 Offer 54. 二叉搜索树的第k大节点
This is how the permission system is designed, yyds

Bug notes

4、 MFC toolbar, runtime class information mechanism, runtime creation mechanism

【每日一练】day(14)
![(16) [system call] track system call (3 rings)](/img/b0/011351361135fd9f8e2d0d31749f73.png)
(16) [system call] track system call (3 rings)
随机推荐
How to play a data mining game entry Edition
剑指 Offer 45. 把数组排成最小的数
嵌入式c语言开发之宏定义求两个数的最大值的使用技巧
Big talk · book sharing | Haas Internet of things device cloud integrated development framework
[node] the service port is occupied error: listen eaddinuse: address already in use::: 9000- how to close the port started by node
leetcode/整数除法
Some interview questions collected
Bug notes
node.express中req.body总是undefind解决
【datawhale202207】强化学习:策略梯度和近端策略优化
(Niuke multi School II) G-LINK with monotonic subsequence (construction question)
剑指 Offer 36. 二叉搜索树与双向链表
Sword finger offer 36. binary search tree and bidirectional linked list
[QT] solve the problem of Chinese garbled code output from QT console
(14) [driver development] configuration environment vs2019 + wdk10 write XP driver
Evolution of coupon architecture under C2B mode
What determines the "personality" of AI robots?
Singing "Seven Mile fragrance" askew -- pay tribute to Jay
Brief tutorial of vbs script syntax (1)
Sword finger offer 54. the k-th node of the binary search tree