碰到一台机器,不管是哪个分区,tail -f 文件就会提示如下,less不会有问题,tail -10 也没问题
tail: cannot watch `/www/log/a.com.log': No space left on device
tail: cannot watch ` /var/log/messagess': No space left on device
df -Th df -i 都不是磁盘满的原因
根据关键词百度
cat /proc/sys/fs/inotify/max_user_watches
写入 /etc/sysctl.conf
fs.inotify.max_user_watches = 65536
fs.inotify.max_user_watches 表示同一用户同时可以添加的watch数目(watch一般是针对目录,决定了同时同一用户可以监控的目录数量,默认8192)