Jump to content
Read the Funtoo Newsletter: Summer 2023 ×
  • 0

How can I get s2disk to work, disk UUID changing after reboot.


xspectatpr

Question

Hello,

I've trying to get suspend to disk to work but been unable to do so. It looks like it dumps the memory into the swap partition just fine and I'm setting the following options in the boot.cfg:

"Funtoo Linux genkernelHibernate" {
	kernel kernel[-v]
	initrd initramfs[-v]

	params += real_root=auto rootfstype=auto 
	params += real_resume=UUID=2b8cda5c-8449-4874-a3e9-583bbb0f47b3 resume=UUID=2b8cda5c-8449-4874-a3e9-583bbb0f47b3 
}

problem seems to be that the UUID for /dev/nvme0n1p2 is changing between reboots(I thought I was putting the wrong one lol) .

blkid outpout

/dev/nvme0n1p2: UUID="2b8cda5c-8449-4874-a3e9-583bbb0f47b3" TYPE="swap" PARTUUID="71e22c3d-02"
/dev/nvme0n1p1: UUID="f3c092b7-bc8d-495c-9b2a-eb4caab4a092" TYPE="ext2" PARTUUID="71e22c3d-01"
/dev/nvme0n1p3: UUID="f5efcbc3-63f8-4585-b12d-7512f70a774b" TYPE="ext4" PARTUUID="71e22c3d-03"
/dev/nvme1n1p1: LABEL_FATBOOT="EFI" LABEL="EFI" UUID="67E3-17ED" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="44846f7e-c146-40b4-b262-98e5b2b54aac"
/dev/nvme1n1p2: UUID="3507a799-1499-4147-94d3-d6c309121e89" TYPE="apfs" PARTUUID="7c3f453a-d56f-4b73-9df8-2df3d6bed583"
/dev/sdc2: UUID="F45C99C15C997ED4" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="4ac53b62-3271-4c5a-96df-b15f3078fe60"
/dev/sdc3: UUID="7A3499113498D20D" TYPE="ntfs" PARTUUID="69603acb-43af-472e-860e-dcc1a0d7dbac"
/dev/sdb2: UUID="FA50108D501052AD" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="64025974-bd7d-45f0-bb32-77eb6c1f7910"
/dev/sdb3: UUID="7610D2A510D26C1D" TYPE="ntfs" PARTUUID="ac32c444-4038-4a8c-bd9e-385dde6c75e8"
/dev/sdd2: LABEL="Shared" UUID="3E6CB27D6CB2300F" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="ea529657-6f9d-4334-b096-38c54a02f2c3"
/dev/sda1: UUID="A5DD-B490" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="210a1aa9-a1d6-4399-81b8-8d9ad008c1bb"
/dev/sda2: UUID="1511a879-f9eb-42c5-a237-b18d78cc4a2d" TYPE="ext4" PARTUUID="69e9917d-3834-4464-b894-6e26ba2a9b64"
/dev/sda3: UUID="b4be1785-1d96-4917-89ac-9f33085d380a" TYPE="swap" PARTUUID="45ae0b54-34fb-4443-aefc-2a3f61f2300b"
/dev/sdc1: PARTLABEL="Microsoft reserved partition" PARTUUID="811382e5-18b2-4604-b526-1cb86124eda4"
/dev/sdb1: PARTLABEL="Microsoft reserved partition" PARTUUID="3cc53d63-b978-4179-aefd-8363b8ebe08f"
/dev/sdd1: PARTLABEL="Microsoft reserved partition" PARTUUID="7fbc6c2e-da94-4e27-b138-aebfed39cdb9"

blkid after rebooting

➜  ~ sudo blkid            
/dev/nvme0n1p1: UUID="f3c092b7-bc8d-495c-9b2a-eb4caab4a092" TYPE="ext2" PARTUUID="71e22c3d-01"
/dev/nvme0n1p2: UUID="ad07eb1d-4af3-4048-8b98-4eb68db1a488" TYPE="swap" PARTUUID="71e22c3d-02"
/dev/nvme0n1p3: UUID="f5efcbc3-63f8-4585-b12d-7512f70a774b" TYPE="ext4" PARTUUID="71e22c3d-03"
/dev/nvme1n1p1: LABEL_FATBOOT="EFI" LABEL="EFI" UUID="67E3-17ED" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="44846f7e-c146-40b4-b262-98e5b2b54aac"
/dev/nvme1n1p2: UUID="3507a799-1499-4147-94d3-d6c309121e89" TYPE="apfs" PARTUUID="7c3f453a-d56f-4b73-9df8-2df3d6bed583"
/dev/sda1: UUID="A5DD-B490" TYPE="vfat" PARTLABEL="EFI System Partition" PARTUUID="210a1aa9-a1d6-4399-81b8-8d9ad008c1bb"
/dev/sda2: UUID="1511a879-f9eb-42c5-a237-b18d78cc4a2d" TYPE="ext4" PARTUUID="69e9917d-3834-4464-b894-6e26ba2a9b64"
/dev/sda3: UUID="b4be1785-1d96-4917-89ac-9f33085d380a" TYPE="swap" PARTUUID="45ae0b54-34fb-4443-aefc-2a3f61f2300b"
/dev/sdb1: PARTLABEL="Microsoft reserved partition" PARTUUID="3cc53d63-b978-4179-aefd-8363b8ebe08f"
/dev/sdb2: UUID="FA50108D501052AD" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="64025974-bd7d-45f0-bb32-77eb6c1f7910"
/dev/sdb3: UUID="7610D2A510D26C1D" TYPE="ntfs" PARTUUID="ac32c444-4038-4a8c-bd9e-385dde6c75e8"
/dev/sdd1: PARTLABEL="Microsoft reserved partition" PARTUUID="7fbc6c2e-da94-4e27-b138-aebfed39cdb9"
/dev/sdd2: LABEL="Shared" UUID="3E6CB27D6CB2300F" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="ea529657-6f9d-4334-b096-38c54a02f2c3"
/dev/sdc1: PARTLABEL="Microsoft reserved partition" PARTUUID="811382e5-18b2-4604-b526-1cb86124eda4"
/dev/sdc2: UUID="F45C99C15C997ED4" TYPE="ntfs" PARTLABEL="Basic data partition" PARTUUID="4ac53b62-3271-4c5a-96df-b15f3078fe60"
/dev/sdc3: UUID="7A3499113498D20D" TYPE="ntfs" PARTUUID="69603acb-43af-472e-860e-dcc1a0d7dbac"

My guess is that, that's the reason why the kernel is not resuming. From dmesg it looks like it grub config points the UUID I configured just fine:

➜  ~ sudo dmesg |grep resu
[    0.000000] Command line: BOOT_IMAGE=/kernel-debian-sources-x86_64-5.10.13_p1 real_resume=UUID=2b8cda5c-8449-4874-a3e9-583bbb0f47b3 resume=UUID=2b8cda5c-8449-4874-a3e9-583bbb0f47b3 real_root=/dev/nvme0n1p3 rootfstype=ext4 rand_id=JUEYJQE2
[    0.015130] Kernel command line: BOOT_IMAGE=/kernel-debian-sources-x86_64-5.10.13_p1 real_resume=UUID=2b8cda5c-8449-4874-a3e9-583bbb0f47b3 resume=UUID=2b8cda5c-8449-4874-a3e9-583bbb0f47b3 real_root=/dev/nvme0n1p3 rootfstype=ext4 rand_id=JUEYJQE2
[    1.011579]     real_resume=UUID=2b8cda5c-8449-4874-a3e9-583bbb0f47b3

 

Help very much appreciated, thanks!.

Link to comment
Share on other sites

2 answers to this question

Recommended Posts

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...