LVM, LUKS and SWAP - swap volume size too small

i am wondering why the swap volume is by default just 980M.
Since I like to let my laptop hibernate when I am not using it, the standard swap volume size is too small.
I fixed it by resizing the root and swap volumes and adding the UUID from the swap volume to the grub CMDLINE.

nvme0n1 259:0 0 477G 0 disk
├─nvme0n1p1 259:1 0 512M 0 part /boot/efi
├─nvme0n1p2 259:2 0 732M 0 part /boot
└─nvme0n1p3 259:3 0 475,7G 0 part
└─nvme0n1p3_crypt 253:0 0 475,7G 0 crypt
├─vgzorin-root 253:1 0 460G 0 lvm /
└─vgzorin-swap_1 253:2 0 10G 0 lvm [SWAP]

My question is: Why don't you offer to have a RAM sized swap volume during the installation process?

Swap is a handy fallback and it is very easy to adjust.

However, it is unwise, generally, to have swap file be significantly larger than the RAM you have available. Personally, I prefer to go by half.
Given that there are Minimum System Requirements; default swap would be small compared to those operating at much higher than the Minimum RAM requirements.

Most distros out there, which use calamares, offer to create a swap lvm volume same size like the RAM, when setting up an encrypted installation.

I always use lvm swap partition to hibernate and resume. And I know how to resize encrypted volumes.

If Zorin OS claims to be user friendly, I would would offer that option during installation. Just my two cents.

1 Like

Moved to "Feedback" forum.

I'm also using LUKS and looking to expand my swap at the moment, just letting the team know I'm another user looking for a larger swap.

I'm a heavy power-user and can have a lot open, so occasionally I'm filling my 32GB of RAM and after a few painful OOM's and having to hard reset my system I see that my default swap is setup to be 1GB.

I think I may be assigning a 32GB or more swap file in a few minutes and manually adjusting the swapiness value to favour using RAM even more strongly than it does at present. The swap for me will just be fail-safe to avoid locking up or crashing, I don't care if the performance goes slow as long as it is stable.

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.