2013-10-10 16:31:55

by Karl Kiniger

[permalink] [raw]
Subject: per block device cache use adjustable?

Using a 4.7 GB 4x DVD+RW I did:
(Fedora 19, x86_64, 4GB RAM)

mkudffs /dev/sr0
mount /dev/sr0 /dvd0
dd if=some-4gb-file of=/dvd0/bigfile.bin

After a few seconds ls -l /dvd0/bigfile.bin displayed 600 MB which
means that more than 30 seconds are kept in RAM.

Is it possible to limit the write cache to a sane value
for this specific device? (perhaps a few seconds at 2..3 MB/sec
write speed)

Thanks in advance for anything helpful,

Karl

PS: dd oflag=direct helps of course but I would like to have
a tuning knob to play with to get optimal performance in my
situation.