[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Memory swapping instrumentation



Good day,

I am working on an academic project which involves obtaining statistics on
the kernel's VM swapping behaviour. May I know what is the best way to do
so (for either 2.2.15 or 2.4.17)?

Specifically, I need to measure statistics such as the average number of
times a page is swapped into memory, a measure of the average time period
for which a page waits on disk between reads, etc.

I tried doing this by writing to the kernel log (via "printk()") for each
swap-in/swap-out, but I found that the log buffer was constantly being
overflowed (thus losing information), even when I had enlarged the buffer.

Also, what are the precautions I need to take when hacking on the VM code
of either the 2.2 or 2.4 series kernels?

Thanks for any help,
-- 
GPG: f75949318a026c5707ff188b438cca87faf73a82
GCS/MU/>AT d- s: a-- C(++) UL>++++ P++(+++) L++(+++) E- W++>+++ N+ o?>++ K?
w--- O? M? V? PS PE Y+ PGP++>++++ t? 5? X? R- tv-() b+>+++ DI(+) D+ G>++++
e>+++++ h-->--- r-->+++ y

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
IRC Channel:   irc.openprojects.net / #kernelnewbies
Web Page:      http://www.kernelnewbies.org/