0

I have a 128 SSD with 8GB of RAM and 8GB of SWAP. I wanted to enable hibernation and instead of repartitioning my disk (which is also a bit old) I though of trying to create a new swap file on a USB drive. Would that work? If I have, say, 7gb of RAM used and hibernate, restoring might take 2/3 minutes, which is very annoying but also fine if I have the necessity of saving my work from the previous day (my battery is not great and my device only supports s2idle, which is not good at all)

3
  • If you have already 8GB Swap why add more? While I assume USB as hibernate drive would work you might have a better experience with a swap file which you could add to your main disk without re-partitioning. Hibernate with swap file instead of partition is a bit more complicated but possible. Jul 26, 2023 at 13:46
  • 1
    If you have an 8GB swap partition, or an 8GB contiguous swap file (read man filefrag mkswap swapon fallocate) hibernation should use it. Check for swap fragmentation, then attempt hibernation. If the system simply stays awake, sudo journalctl --since="-5 minutes", but if the system crashes sudo journalctl -b -1 -e will give you more information. Please edit your question to add whatever information you get. Do not use Add Comment.
    – waltinator
    Jul 26, 2023 at 19:45
  • Sometimes swap gets used because I have many apps open, so it won't hibernate because there is not enough your space Jul 26, 2023 at 22:14

0

You must log in to answer this question.

Browse other questions tagged .