linux server adm – decrease / monitor hd access
first install
apt-get install inotify-tools
maybe also screen to have inotify running with screen in the background
then monitor what is going on. directories after a @ are ignored.
inotifywait -m -r / @/dev @/media @/mnt @/opt @/proc @/root @/sbin @/sys @/tmp @/usr @/bin @/etc @/lib @/var/run/samba/ @/var/cache/samba/
case “$1” in
start)
log_daemon_msg “Starting Samba daemons”
mount -t tmpfs tmpfs /var/run/samba
mount -t tmpfs tmpfs /var/cache/samba
# Make sure we have our PIDDIR, even if it’s on a tmpfs
install -o root -g root -m 755 -d $PIDDIR
at stop)
..
..
fi
fi
umount /var/run/samba
umount /var/cache/samba
log_end_msg 0
;;
reload)
———-
for me it did not do all the trick. samba was still trying to access:
/var/lib/samba so:
mv /var/lib/samba/ /var/lib/samba_
cp -ar /var/lib/samba_ /tmp/samba_lib
ln -sf /tmp/samba_lib /var/lib/samba
(this is what I am currently testing… but should work.. so unconfirmed yet 🙂