swap partition problems
swap partition problems
Hello everybody! here's the problem:
In my EndeavourOS laptop I had a /swapfile
, but couldn't take snapshots with snapper because of it (if I understood correctly). So, I created a 16Gb swap partition using GParted from a live USB. Then, I edited /etc/fstab
to remove the line about the swapfile and to add the newly created swap partition:
UUID=506d48e6-1cc0-4136-ba55-6f2f187bcdb1 swap swap defaults 0 0 # /swapfile none swap sw 0 0
I took the UUID from
sh
$ sudo blkid /dev/nvme0n1p3: LABEL="swap" UUID="506d48e6-1cc0-4136-ba55-6f2f187bcdb1" TYPE="swap" PARTLABEL="SWAP" PARTUUID="b4543e4e-4623-4317-99aa-086b0e62836e" ...
if I run sudo swapon -a
it gets enabled correctly and it all works fine. The problem however is that when I reboot the machine, it gets stuck in the systemd screen saying "a job is running for /dev/disk/etc..." forever, and the only way I have to log in is to boot from a live USB, modify /efi/loader/entries/somethingverylong.conf
to add these kernel options:
systemd.swap=0 noresume
and then reboot, and manually enable the swap.
I'm not understanding very well what's happening here. why is the system stuck if I don't add these parameters? how can I solve it?
thanks in advance!
which systemd unit/target does it get stuck on?
it's really strange, I just noticed that it's the UUID of... the original swap partition (now gone) the entry is still commented in /etc/fstab:
is there another place other than /etc/fstab where I should remove it?
thanks for the help!
EDIT: this is the whole output of
sudo blkid
if needed:it sounds like it unrelated to /etc/fstab and that there's something in your systemd config that's expecting it.
if you don't have the name of the unit; i think you search through your systemd config in /etc/ to find & disable it. (ie grep -ir $uuid /etc/)