Skip Navigation

(TIP) Linux comes with lvmcache, which allows you to easily setup SSD caching.

I'm not sure how widely known this is, I'm hoping at the least some other beginners will benefit :)

SSD caching is when an SSD stores the most frequently used contents of a slow (but usually larger) hard disk. When attempting to access something from your hard disk, it will be fetched from your SSD if available, otherwise getting it from your HDD. All the while you will be shielded from this complexity and pretend to work off of the HDD (transparent caching).

Linux comes with lvmcache, which lets you do this with surprisngly few incantations in your terminal.

I had fun installing a distro making use of this (as expected performance has benefited quite a bit). If you are, too:

  • Guides on lvmcache assume you already know the basics of Linux's logical volume manager (lvm). There don't seem to be any that bring it all together.

  • On setting lvmcache up, the lvmcache manpage was nice and clear. RedHat's guide was good too. Other sources meanwhile were lacking in one way or another.

  • A volume with lvmcache set up, I learn that Ubuntu's nice-looking new installer doesnt support installing on lvm logical volumes. Frustratingly, everything online was on using the old installer, leaving me wondering where I had messed up so that my lvm volume wasn't showing up on my installer. Heads up.

Thanks for reading!

0
0 comments