Debian系統可通過以下工具監控文件系統:
inotifywait -m -r /path
fswatch -r /path
watch -n 2 ls -l /path
watchdog
根據需求選擇工具,inotify-tools和fswatch適合大多數場景。
inotify-tools
fswatch