From: Aurelien Jarno Date: Sun, 1 Sep 2019 12:47:39 +0000 (+0200) Subject: Add some tips about LV caching X-Git-Url: https://git.adam-barratt.org.uk/?a=commitdiff_plain;ds=sidebyside;h=e65ba8b85b4598adb9aba5d21468a0f4e52fae1e;hp=0005b5d0b23ab73cb26f508733fbc3c6d54de56b;p=mirror%2Fdsa-wiki.git Add some tips about LV caching --- diff --git a/input/howto/lvm.creole b/input/howto/lvm.creole new file mode 100644 index 0000000..ef201e6 --- /dev/null +++ b/input/howto/lvm.creole @@ -0,0 +1,21 @@ +== Random LVM stuff == + +=== LV caching === + +We use LV caching at least on godard.d.o and smit.d.o. Here are the setup instructions: + +* Make sure that both the HDD and SSD are in the same volume group. + +* Make sure module loading is enabled + +* Run the following command to enable LV caching for the srv LV in the vg0 VG, assuming the SSD is /dev/sda3: + +{{{ + lvcreate --type cache --cachemode writethrough -L 120G -n srv_cachepool vg0/srv /dev/sda3 +}}} + +* It is currently not possible to resize a LV with a LVM cache. The workaround is to disable LV caching, resize the LV and reenable it. LV caching can be disabled with the following command: + +{{{ + lvconvert --uncache vg0/srv +}}} diff --git a/input/index.mdwn b/input/index.mdwn index c5f2624..7397cae 100644 --- a/input/index.mdwn +++ b/input/index.mdwn @@ -65,6 +65,7 @@ ticket. * [[howto/new-dpl]]: What to do when we have a new DPL * [[howto/new-dsa]]: What to do when we have a new DSA member * [[howto/static-mirroring]]: Static mirroring fu +* [[howto/lvm]]: LVM related tips ## ports