I have a 16GiB swapfile that is located into my root folder so the path is /swapfile.
Thing is I have 32GB of ram and so I wanted to make a 32GB swapfile but this would fill my lv_root entirely and create errors when all over (as it would with a full root logical volume)
**I was wondering if there was a need for swapfiles to be in the root logical volume? **
Because if not I would've just created the swapfile into my home folder
#Swapfile filling up root logical volume
27 messages · Page 1 of 1 (latest)
There isn't a requirement, but iirc systemd-logind or some other systemd service has some option that protects the home directory by default which means you won't be able to hibernate without editing the service file to disable that protection
SO THAT'S WHY MY PC WOULDN'T WAKE UP FROM HIBERNATION OMFGGGG
perhaps
because last time I had a hibernate option in my powermenu my swapfile was in my home folder
but usually it wouldn't let you hibernate in the first place
ah some maybe something else
if it was protected
but maybe I'm just remembering wrong
It's worth seeing if changing that option fixes it
alright
did you make sure you set the right resume options in the kernel command line
when you added your swapfile to your home dir
I have no idea how hibernation works
all I did was try the systemctl hibernate, see that it didn't work, and didn't try further lol
but aside from the hibernate thing
You need to set up your initramfs and kernel command line
To tell it to resume from hibernate and tell it where the swapfile is to actually resume from
what options do I have for the swapfile now? since it will definitely be bigger than my root logical volume?
thanks ill look into that
Put in /home
and just configure logind to disable the ProtectHome option or whatever it's called
alright Ill try that later thanks for the help :)
oh right I found it @sacred gale
You do sudo systemctl edit systemd-logind.service then add```ini
[Service]
ProtectHome=no
To the bottom
Then save and quit the editor
amazing I was looking that up thankks x)
Then after that you can proceed with these steps so that it will be able to actually wake from hibernation