You are not logged in.

#1 2024-02-25 11:15:41

zw963
Member
Registered: 2018-06-18
Posts: 213

Keeping hang when hibernate occasionally.

Hi, all.  I meet hibernate failed occasionally issue on Arch linux.

i use minisform Venus UM780 XTX miniPC(AMD Ryzen™ 7 7840HS with 780M), with 64GB memory + 64GB swap partition(label is swap, this is the only swap partition.)

i enable hibernate use following process:

1. Add "resume" into HOOKS of /etc/mkinitcpio.conf, like this: HOOKS=(.... resume fsck), then run "mkinitcpio -P" to rebuild.
2. add  "resume=LABEL=swap zswap.enabled=0" into refind.conf for kernel args.

Because i use zram for a memory disk,  like following, so i disable `zswap` in kernel too following the wiki.

zramctl /dev/zram0 --algorithm zstd --size 32G;
mkfs.ext4 /dev/zram0;
mount /dev/zram0 /path

And run "systemctl hibernate",  when the hibernate issue happen, i even can't  use Alt + Prtsc + R E I S U B to make my pc reboot use a 2.4G wireless keyboard, i have to force poweroff.

there is no meanful log output when i run sudo journalctl --system --boot=-1 |tail -50 after reboot.


Feb 25 18:06:52 mingfan systemd[1]: Starting System Hibernate...
Feb 25 18:06:52 mingfan rtkit-daemon[1161]: Successfully made thread 1474 of process 1443 owned by '1000' high priority at nice level 0.
Feb 25 18:06:52 mingfan rtkit-daemon[1161]: Supervising 4 threads of 4 processes of 1 users.
Feb 25 18:06:52 mingfan rtkit-daemon[1161]: Supervising 3 threads of 3 processes of 1 users.
Feb 25 18:06:52 mingfan rtkit-daemon[1161]: Supervising 3 threads of 3 processes of 1 users.
Feb 25 18:06:52 mingfan systemd-sleep[424637]: Performing sleep operation 'hibernate'...
Feb 25 18:06:52 mingfan kernel: PM: hibernation: hibernation entry
Feb 25 18:06:52 mingfan rtkit-daemon[1161]: Successfully made thread 1474 of process 1443 owned by '1000' RT at priority 20.
Feb 25 18:06:52 mingfan rtkit-daemon[1161]: Supervising 4 threads of 4 processes of 1 users.


I use linux-amd 6.7.v.6-1 kernel, with GNOME 45 + Wayland,  any clue? 

———————-

EDIT: it should not OOM issue, because memory usage is very low. although, i use zram memory disk for docker container data folder, don't know if involves.

---------------

EDIT: i use following AMD GPU driver.

pacman -S mesa lib32-mesa
pacman -S xf86-video-amdgpu
pacman -S amdvlk lib32-amdvlk
pacman -S libva-mesa-driver lib32-libva-mesa-driver


Thanks.

Last edited by zw963 (2024-02-25 16:05:09)

Offline

#2 2024-02-28 18:07:19

zw963
Member
Registered: 2018-06-18
Posts: 213

Re: Keeping hang when hibernate occasionally.

It's seem like never happened since i replace /dev/zram with /dev/ram.

Offline

#3 2024-03-06 05:49:44

zw963
Member
Registered: 2018-06-18
Posts: 213

Re: Keeping hang when hibernate occasionally.

It hang again, i need more time to check the possibility of which following factor cause this issue.

0. use /dev/ram instead of /dev/zram (unrelated)
1. run `mkinitcpio -P` to rebuild kernel. (testing)
2. disable ram disk completely. (pending)
3. use vulkan-radeon instead of amdvlk driver. (pending)
4. update bios version. (pending)

Last edited by zw963 (2024-03-06 05:49:56)

Offline

#4 2024-03-06 08:08:23

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 75,315

Re: Keeping hang when hibernate occasionally.

i even can't  use Alt + Prtsc + R E I S U B

nb. that you've to first enable that, https://wiki.archlinux.org/title/Keyboa … el_(SysRq)

use a 2.4G wireless keyboard

… and attach a $5 office supply one.

Does this also happen for S3 attempts?
https://bbs.archlinux.org/viewtopic.php … 3#p2154943 ?
(false positive APU VRAM eviction)

Offline

#5 2024-03-07 11:43:23

zw963
Member
Registered: 2018-06-18
Posts: 213

Re: Keeping hang when hibernate occasionally.

seth wrote:

i even can't  use Alt + Prtsc + R E I S U B

nb. that you've to first enable that, https://wiki.archlinux.org/title/Keyboa … el_(SysRq)

use a 2.4G wireless keyboard

… and attach a $5 office supply one.

Does this also happen for S3 attempts?
https://bbs.archlinux.org/viewtopic.php … 3#p2154943 ?
(false positive APU VRAM eviction)

> nb. that you've to first enable that, https://wiki.archlinux.org/title/Keyboa … el_(SysRq)

Yes, i enable it in sysctl.d, i can reboot use REISUB  when system is on.

> If you want to make sure it will be enabled even before the partitions are mounted and in the initrd, then add sysrq_always_enabled=1 to your kernel parameters.

Probably caused by this?  i will add this kernel parameters, and check if can get the expected failed log.

> Does this also happen for S3 attempts?

~~You means suspend, right? never.~~

> … and attach a $5 office supply one.

No attached USB keyboard nowadays ....  :smile:

-----------------


EDIT:

 ╰─ $ \cat /sys/power/mem_sleep
[s2idle]

My new minipc seem like only support s2idle, not s3, i try add sleep into it, failed.


[root@mingfan Dropbox]# echo "deep" > /sys/power/mem_sleep
bash: echo: write error: Invalid argument

So, i don't know if this issue happen on S3

Last edited by zw963 (2024-03-07 12:59:22)

Offline

#6 2024-03-07 15:48:38

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 75,315

Re: Keeping hang when hibernate occasionally.

https://bbs.archlinux.org/help.php#bbcode

So it already happens on S2, the idea was to plug a usb keyboard to get the radio problem out of the way and see whether you can use the magic sysrq from there.
https://bbs.archlinux.org/viewtopic.php … 3#p2155023 - not idea, but it's worth a shot

Offline

#7 2024-03-08 14:33:29

zw963
Member
Registered: 2018-06-18
Posts: 213

Re: Keeping hang when hibernate occasionally.

seth wrote:

https://bbs.archlinux.org/help.php#bbcode

So it already happens on S2, the idea was to plug a usb keyboard to get the radio problem out of the way and see whether you can use the magic sysrq from there.
https://bbs.archlinux.org/viewtopic.php … 3#p2155023 - not idea, but it's worth a shot

Just for clarify, hang issue never happen when i run `systemctl suspend`, it only happen when `systemctl hiberante` occasionally.

-----------

BTW: it hung a again when hibernate, and i forget add `sysrq_always_enabled=1`, so, still unluck when REISUB.

I am continuing exclusion follow following cases:

0. use /dev/ram instead of /dev/zram (unrelated)
1. run `mkinitcpio -P` to rebuild kernel. (unrelated)
2. disable ram disk completely. (testing)
3. use vulkan-radeon instead of amdvlk driver. (pending)
4. update bios version. (pending)

--------------
EDIT:

I am using following kernel boot args

 ╰─ $ \cat /proc/cmdline
root=LABEL=ArchLinux rw initrd=boot\amd-ucode.img pci=nommconf resume=LABEL=swap sysrq_always_enabled=1 initrd=\boot\initramfs-linux-lts.img

Last edited by zw963 (2024-03-08 18:34:05)

Offline

Board footer

Powered by FluxBB