- [root@rui ~]# uname -r
- 2.6.18-194.el5
- You have new mail in /var/spool/mail/root
- [root@rui ~]# ll /proc/sys/fs/inotify/
- total 0
- -rw-r--r-- 1 root root 0 Oct 24 12:44 max_queued_events
- -rw-r--r-- 1 root root 0 Oct 24 12:44 max_user_instances
- -rw-r--r-- 1 root root 0 Oct 24 12:44 max_user_watches
- [root@rui ~]#
- 1、下载
- wget --no-check-certificate http://github.com/downloads/rvoicilas/inotify-tools/inotify-tools-3.14.tar.gz
- 2、编译
- tar zxf inotify-tools-3.14.tar.gz
- cd inotify-tools-3.14
- ./configure
- make
- make install
- 3、一些小处理
- 如果是32位系统
- ln -s /usr/local/lib/libinotifytools.so.0 /usr/lib/libinotifytools.so.0
- 如果是64位系统
- ln -s /usr/local/lib/libinotifytools.so.0 /usr/lib64/libinotifytools.so.0
- 5、无论32或者64位系统都执行
- [root@rui ~]#echo 104857600 > /proc/sys/fs/inotify/max_user_watches
- [root@rui ~]#echo 'echo 104857600 > /proc/sys/fs/inotify/max_user_watches' >> /etc/rc.local
- [root@rui ~]#echo '/usr/local/bin/inotifywait -mrq -o/var/log/change.log --timefmt '%F %T' --format ' %T %w%f %e' -e close_write -e create -e delete -e move -e attrib /www/web/ttc.com/public_html
- >> /etc/rc.local