• cizra@lemm.ee
    link
    fedilink
    arrow-up
    1
    ·
    1 year ago

    Not saying my practice is the best one, but here’s what I do:

    • EFI system partition is mounted on /boot
      • kernel is held here. In case of distros like NixOS etc that keep around old kernels, a small ESP might run out of space. I make mine at least 1GB.
    • the rest of the disk is one luks2 volume
    • inside the encrypted volume, there’s a BTRFS volume
    • there’s a subvolume for /home
    • and a subvolume for every distro I have (which is usually 1, but sometimes I tinker or switch)
    • Kernel command line parameters specify the btrfs subvol with the right distro to boot.
    • for NixOS, you need a bootloader (to choose the right kernel). Systemd-boot works well, and its configuration is easily readable. I never figured out how to work with GRUB2, its configuration is just too confusing.
    • or if you like Arch, dispense with bootloaders and just use EFISTUB. You can put kernel cmdline params into EFI bootloader options with efibootmgr.

    Simple yet complete. Efficient, and extensible - for example, now that everything is a subvolume, I can easily snapshot it, then create backups with rsync off the snapshot, to avoid inconsistent state between backed-up files.

  • Andrius Štikonas@lemmy.kde.social
    link
    fedilink
    arrow-up
    1
    ·
    1 year ago

    It really depends on your requirements…

    But a few useful points:

    1. Use GPT partition table and not MBR. Everything will be simpler, no need for extended/logical partitions.
    2. If you need to be able to do online (mounted) partition resizing, pick btrfs. Ext4 can only grow them online but not shrink.
    3. Make sure your partition boundaries are 1 MiB aligned.
    4. If you need more advanced setups, consider using LVM.
  • neo (he/him)@lemmy.comfysnug.space
    link
    fedilink
    English
    arrow-up
    0
    ·
    1 year ago
    • 500mb-600mb fat32 /boot partition
    • 40gb - 100gb ext4 or btrfs / partition (if you know you’re gonna install a lot of software, go bigger)
    • 1x - 2x ram as swap
    • rest of disk as ext4 /home partition
  • Chewy@discuss.tchncs.de
    link
    fedilink
    arrow-up
    0
    ·
    1 year ago

    Use zram instead of a SWAP partititon. Zram compresses and keeps in RAM. It’s default on Fedora and a few others iirc.