Read last 4 lines of this reply, I'll wait . . . . . . . . . . . . . . .
Post by Runner1) Opened grub sudo nano /etc/default/grub.
2) In a separate terminal, used ls -l /dev/disk/by-uuid to determine
uuid of swap partition
FYI: You might want to look into using lsblk. Lots of options that
you could use in an alias. Try this in a wide terminal
lsblk -o NAME,TYPE,FSTYPE,MOUNTPOINT,LABEL,PARTLABEL,UUID,PTUUID
Run "lsblk --help" for other options.
Post by Runner3) In nano, changed grub line GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
to GRUB_CMDLINE_LINUX_DEFAULT="quiet splash resume=/dev/disk/by-uuid/X"
with X being replaced by swap partition uuid
Ok, for whatever reason you Distribution is not setting resume argument.
I have seen a distribution replacing GRUB_CMDLINE_LINUX_DEFAULT and
wiping out user modifications.
If you were to look through scripts in /etc/grub.d/ you might notice
that GRUB_CMDLINE_LINUX is in front of GRUB_CMDLINE_LINUX_DEFAULT.
As a result you can put whatever you like to add into that variable
and it will be added to the boot line. For example:
$ grep GRUB_CMDLINE_LINUX /etc/default/grub
GRUB_CMDLINE_LINUX_DEFAULT=noiswmd
GRUB_CMDLINE_LINUX="ipv6.disable=1 audit=0 splash=off plymouth.enable=0
noresume mitigations=off vblank_mode=0 "
Fun fact, anytime you do an install, swap will probably get formatted.
as a result swap's UUID has a new value and Label is erased.
Same thing happens when any partition is formatted.
If you wanted to negate that kind of problem you can use the partition
uuid or PARTLABEL in those situations.
For example
$ grep swap /etc/fstab
PARTLABEL=swap swap swap defaults,nofail 0 0
I do not use resume, but I suggest that you can add
GRUB_CMDLINE_LINUX="resume=PARTLABEL=swap"
to /etc/default/grub
and remove resume=whatever from GRUB_CMDLINE_LINUX_DEFAULT
That assumes you have set a partition label for swap.
I find it handy to use gparted for setting media label and partition names.
Post by Runner4) Saved modified grub and exited.
5) sudo update-grub
Good, anytime /etc/default/grub is changed that has to be done.
--
The warranty and liability expired as you read this message.
If the above breaks your system, it's yours and you keep both pieces.
Practice safe computing. Backup the file before you change it.
Do a, man command_here or cat command_here, before using it.