[linux-lvm] lvmcache performance

Nikolaus Rath Nikolaus at rath.org
Sun Feb 7 18:43:30 UTC 2016


Hello,

My system boots rather slowly, so when I noticed a lot of free space on
one of my SSDs, I wanted to try to speed-up the boot by caching my root
volume.

For benchmarking purposes, I first moved the entire LV holding the root
file system to the SSD. This reduced the boot time from about 90 seconds
to 20 - nice!

I then moved the root fs LV back to the spinning disk and created a
cache-pool on the SSD. My root fs is 40 GB, with 19 GB used. The cache
pool had a 15 GB data and 15 MB metadata volumes and used writeback
cache. Finally, I converted my root fs LV to a cache LV.

To getting data into the initrd quickly, I also set up my initrd to call

    dmsetup message ${name} 0 sequential_threshold 0
    dmsetup message ${name} 0 read_promote_adjustment 0
    dmsetup message ${name} 0 write_promote_adjustment 0


However, even after a few reboots I do not notice any difference at all
in boot times. It is as if the cache was not used at all.


With the above settings (and the cache pool as big as the used space on
the origin LV), I would have expected to get almost the same performance
as when moving the entire PV to the SSD.

Is that the wrong expectation? But even then, shouldn't I at least see
some improvement?

Thanks,
-Nikolaus

-- 
GPG encrypted emails preferred. Key id: 0xD113FCAC3C4E599F
Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F

             »Time flies like an arrow, fruit flies like a Banana.«




More information about the linux-lvm mailing list