Hello everyone,
I'm working with a system where the "typical" hard disk drive has been replaced with a small flash-based drive.
To avoid premature aging of the flash drive, files that are updated often are written to a RAM-based filesystem.
# cat /etc/fstab /dev/hda1 / ext2 defaults 0 1 proc /proc proc defaults 0 0 sysfs /sys sysfs defaults 0 0 tmpfs /dev tmpfs rw,size=10M,mode=755 0 0 tmpfs /var tmpfs rw,size=50M,mode=755 0 0
# cat /proc/mounts rootfs / rootfs rw 0 0 /dev/root / ext2 rw,nogrpid 0 0 none /proc proc rw,nodiratime 0 0 sysfs /sys sysfs rw 0 0 tmpfs /dev tmpfs rw 0 0 tmpfs /var tmpfs rw 0 0 /dev/hda2 /mnt/app ext2 rw,nogrpid 0 0
(Files written to /var and /tmp are stored in RAM.)
Suppose I read or write /var/log/messages, where is the metadata about that file (such as last accessed, last modified, etc) stored? Is it possible that some metadata is written to /dev/hda?
(I've been wondering whether I should set noatime for /var)
You'll also note that there is no swap on this system. Other than reading and writing files on /dev/hda, what could cause drive activity?
(For evidence of disk activity, I monitor the number of IRQs sent by the flash drive.)
# cat /proc/interrupts ; sleep 5 ; echo "+++" ; cat /proc/interrupts CPU0 0: 75 XT-PIC-XT timer 1: 2 XT-PIC-XT i8042 2: 0 XT-PIC-XT cascade 7: 0 XT-PIC-XT acpi 10: 4 XT-PIC-XT eth1 11: 4 XT-PIC-XT eth2 12: 388 XT-PIC-XT eth0 14: 12812 XT-PIC-XT ide0 NMI: 0 LOC: 39302 ERR: 0
+++ CPU0 0: 75 XT-PIC-XT timer 1: 2 XT-PIC-XT i8042 2: 0 XT-PIC-XT cascade 7: 0 XT-PIC-XT acpi 10: 4 XT-PIC-XT eth1 11: 4 XT-PIC-XT eth2 12: 391 XT-PIC-XT eth0 14: 12812 XT-PIC-XT ide0 NMI: 0 LOC: 39805 ERR: 0No disk activity between these two samples.