francois:hibernation
Différences
Ci-dessous, les différences entre deux révisions de la page.
| Prochaine révision | Révision précédente | ||
| francois:hibernation [2025/10/18 08:41] – créée francois | francois:hibernation [2025/10/18 09:19] (Version actuelle) – francois | ||
|---|---|---|---|
| Ligne 1: | Ligne 1: | ||
| ====== Comment activer l' | ====== Comment activer l' | ||
| + | |||
| + | ===== Procédure ===== | ||
| Ligne 9: | Ligne 11: | ||
| Steps to enable hibernation | Steps to enable hibernation | ||
| - | | + | Create a subvolume for your swapfile |
| sudo btrfs subvolume create /swap | sudo btrfs subvolume create /swap | ||
| - | | + | Calculate the size of your swapfile |
| - | | + | It’s your zram size + your RAM size. You can see the size of your zram with: |
| swapon --show | swapon --show | ||
| - | | + | Mine was 30GB and my RAM size is 30GB, so my swapfile needs to be 60GB. That’s a lot of space, but for me not a problem. |
| - | | + | Create the swapfile |
| sudo btrfs filesystem mkswapfile --size 60g --uuid clear / | sudo btrfs filesystem mkswapfile --size 60g --uuid clear / | ||
| - | | + | Find the UUID of the (virtual) device where the swapfile resides, copy it for later use |
| sudo findmnt -no UUID -T / | sudo findmnt -no UUID -T / | ||
| - | | + | You will get something like 58239ee3-aa2b-32ef-b7b2-2f591ee2251b |
| - | | + | Aquire swap file offset, copy it for later use |
| sudo btrfs inspect-internal map-swapfile -r / | sudo btrfs inspect-internal map-swapfile -r / | ||
| - | | + | You will something like 52635 |
| - | | + | Add kernel parameters you acquired is step 4 and 5 |
| - | | + | Edit the file / |
| LINUX_OPTIONS=" | LINUX_OPTIONS=" | ||
| - | | + | Regenerate all systemd-boot entries with the following command |
| sudo sdboot-manage gen | sudo sdboot-manage gen | ||
| - | | + | Configure initramfs - add resume hook |
| - | | + | Edit the file / |
| HOOKS=(base udev autodetect microcode kms modconf block keyboard keymap consolefont plymouth encrypt resume filesystems) | HOOKS=(base udev autodetect microcode kms modconf block keyboard keymap consolefont plymouth encrypt resume filesystems) | ||
| - | | + | Regenerate initramfs |
| sudo mkinitcpio -P | sudo mkinitcpio -P | ||
| - | | + | Add swapfile to fstab with low priority |
| - | | + | Edit the file /etc/fstab and add on the last line: |
| / | / | ||
| - | | + | Enable swap on running system |
| sudo swapon / | sudo swapon / | ||
| - | + | Check if swap is enabled | |
| - | | + | |
| swapon --show | swapon --show | ||
| - | | + | You should now see something like |
| NAME | NAME | ||
| Ligne 77: | Ligne 78: | ||
| / | / | ||
| - | | + | Reboot your system |
| After reboot, hibernation should be enabled in the settings of your Desktop Environment (if you use one). You can also test it on the command line with: | After reboot, hibernation should be enabled in the settings of your Desktop Environment (if you use one). You can also test it on the command line with: | ||
| Ligne 86: | Ligne 87: | ||
| If you’re a fan of suspend-then-hibernate, | If you’re a fan of suspend-then-hibernate, | ||
| + | < | ||
| / | / | ||
| Ligne 99: | Ligne 101: | ||
| # | # | ||
| # | # | ||
| + | </ | ||
| + | |||
| Sources used: | Sources used: | ||
| - | Boot Manager Configuration in CachyOS | + | * Boot Manager Configuration in CachyOS |
| - | + | | |
| - | Suspend and Hibernate at ArchWiki | + | |
| - | + | * Framework Community | |
| - | BTRFS at ArchWiki | + | * Disable/ |
| - | Framework Community | + | ===== Résolution des problèmes ===== |
| - | Disable/ | + | ==== Le système se réveille immédiatement après |
| - | zcfan for OpenRC | + | |
| - | Blog | + | |
| - | OPNsense dnsmasq + UniFi adoption (option 43) | ||
| - | OPNsense with KPN fiber and iTV | ||
| - | Disable/ | ||
| - | Enable hibernation in CachyOS alongside zram swap with full disk encryption on BTRFS | ||
| - | zcfan for OpenRC | ||
| - | Thinkfan for OpenRC | ||
| - | PiTemps | ||
| - | ZFS Health script | ||
| - | Logo Meganerd.nl | ||
| - | Privacy Policy | ||
| - | © 2025 Meganerd.nl | + | Il faut blacklister le module '' |
francois/hibernation.1760776895.txt.gz · Dernière modification : de francois
