[RESPONDED] Laptop crashes and reboot sometimes after resuming from suspend

Dear all,

I have a Framework Laptop 13 (AMD Ryzen™ 7040 Series) installed with Ubuntu 22.04LTS (updated).

Not always, but sometimes, a few second after logged in into the laptop following a suspend, the computer suddenly crashes and reboot from scratch (black screen, then BIOS, etc.).

It is not systematic and I am not sure how to better diagnose the issue.
I was wondering if any of you experienced the same issue.

Thanks in advance for your support,
Pierre

Try to check the last log after the reboot.
With journalctl --list-boot list the existing boots.
Then, take the one that has crashed (actually, should be the one before your session), and use the -? in front to look at that log with:
journalctl -b -1 -r where the -1 corresponds to the entry of the boot session you went into suspend.
The -r will show the log in reverse time, means what happened just before the crash, if it was written down, should show up at the beginning.

That’s how I go about that.

Thanks Jord for the tips.

Hereunder are the last lines of log (in the chronological order), but not sure there is anything related to this crash. I will try again after the next one.

Best regards,
Pierre

jan 19 14:46:16 framework NetworkManager[1191]: [1705671976.4406] manager: NetworkManager state is now CONNECTED_GLOBAL
jan 19 14:46:16 framework systemd-resolved[1109]: wlp1s0: Bus client set search domain list to: home
jan 19 14:46:16 framework systemd-resolved[1109]: wlp1s0: Bus client set default route setting: yes
jan 19 14:46:16 framework systemd-resolved[1109]: wlp1s0: Bus client set DNS server list to: 192.168.1.1
jan 19 14:46:16 framework tincd[1230]: Got ALRM signal
jan 19 14:46:16 framework tincd[1230]: Flushing event queue
jan 19 14:46:16 framework gdm-fingerprint][300468]: gkr-pam: no password is available for user
jan 19 14:46:16 framework tincd[1230]: Metadata socket read error for ncsrv (85.57.195.9 port 655): Connection reset by peer
jan 19 14:46:16 framework tincd[1230]: Got ALRM signal
jan 19 14:46:16 framework tincd[1230]: Flushing event queue
jan 19 14:46:16 framework NetworkManager[1191]: [1705671976.9761] agent-manager: agent[6d959809613f8784,:1.97/org.gnome.Shell.NetworkAgent/1000]: agent registered
jan 19 14:46:16 framework ubuntu-appindicators@ubuntu.com[3498]: unable to update icon for software-update-available
jan 19 14:46:16 framework ubuntu-appindicators@ubuntu.com[3498]: unable to update icon for livepatch
jan 19 14:46:17 framework audit[1188]: USER_AVC pid=1188 uid=102 auid=4294967295 ses=4294967295 subj=unconfined msg=‘apparmor=“DENIED” operation=“dbus_signal” bus=“system” path=“/org/freedesktop/login1” interface=“org.freedesktop.DBus.Properties” member=“PropertiesChanged” name=“:1.20” mask=“receive” pid=106896 label=“firefox” peer_pid=1228 peer_label=“unconfined”
exe=“/usr/bin/dbus-daemon” sauid=102 hostname=? addr=? terminal=?’
jan 19 14:46:17 framework kernel: audit: type=1107 audit(1705671977.051:6926): pid=1188 uid=102 auid=4294967295 ses=4294967295 subj=unconfined msg=‘apparmor=“DENIED” operation=“dbus_signal” bus=“system” path=“/org/freedesktop/login1” interface=“org.freedesktop.DBus.Properties” member=“PropertiesChanged” name=“:1.20” mask=“receive” pid=106896 label=“firefox” peer_pid=1228 peer_label=“unconfined”
exe=“/usr/bin/dbus-daemon” sauid=102 hostname=? addr=? terminal=?’
jan 19 14:46:17 framework gnome-shell[3498]: g_signal_handler_disconnect: assertion ‘handler_id > 0’ failed
jan 19 14:46:17 framework gnome-shell[3498]: g_signal_handler_disconnect: assertion ‘handler_id > 0’ failed
jan 19 14:46:17 framework gnome-shell[3498]: g_signal_handler_disconnect: assertion ‘handler_id > 0’ failed
jan 19 14:46:17 framework gnome-shell[3498]: g_signal_handler_disconnect: assertion ‘handler_id > 0’ failed
jan 19 14:46:17 framework gnome-shell[3498]: g_signal_handler_disconnect: assertion ‘handler_id > 0’ failed
jan 19 14:46:17 framework gnome-shell[3498]: g_signal_handler_disconnect: assertion ‘handler_id > 0’ failed
jan 19 14:46:17 framework gnome-shell[3498]: g_signal_handler_disconnect: assertion ‘handler_id > 0’ failed
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 31 with keysym 31 (keycode a).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 32 with keysym 32 (keycode b).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 33 with keysym 33 (keycode c).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 34 with keysym 34 (keycode d).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 35 with keysym 35 (keycode e).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 36 with keysym 36 (keycode f).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 37 with keysym 37 (keycode 10).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 38 with keysym 38 (keycode 11).
jan 19 14:46:17 framework gnome-shell[3498]: Window manager warning: Overwriting existing binding of keysym 39 with keysym 39 (keycode 12).
jan 19 14:46:17 framework dbus-daemon[3218]: apparmor=“DENIED” operation=“dbus_method_call” bus=“session” path=“/” interface=“org.freedesktop.DBus.Introspectable” member=“Introspect” name=“:1.39” mask=“receive” pid=106896 label=“firefox” peer_pid=3498 peer_label=“unconfined”
jan 19 14:46:17 framework dbus-daemon[3218]: apparmor=“DENIED” operation=“dbus_method_call” bus=“session” path=“/” interface=“org.freedesktop.DBus.Introspectable” member=“Introspect” name=“:1.39” mask=“receive” pid=106896 label=“firefox” peer_pid=3498 peer_label=“unconfined”
jan 19 14:46:20 framework audit[1188]: USER_AVC pid=1188 uid=102 auid=4294967295 ses=4294967295 subj=unconfined msg=‘apparmor=“DENIED” operation=“dbus_signal” bus=“system” path=“/org/freedesktop/login1” interface=“org.freedesktop.DBus.Properties” member=“PropertiesChanged” name=“:1.20” mask=“receive” pid=106896 label=“firefox” peer_pid=1228 peer_label=“unconfined”
exe=“/usr/bin/dbus-daemon” sauid=102 hostname=? addr=? terminal=?’
jan 19 14:46:20 framework kernel: audit: type=1107 audit(1705671980.387:6927): pid=1188 uid=102 auid=4294967295 ses=4294967295 subj=unconfined msg=‘apparmor=“DENIED” operation=“dbus_signal” bus=“system” path=“/org/freedesktop/login1” interface=“org.freedesktop.DBus.Properties” member=“PropertiesChanged” name=“:1.20” mask=“receive” pid=106896 label=“firefox” peer_pid=1228 peer_label=“unconfined”
exe=“/usr/bin/dbus-daemon” sauid=102 hostname=? addr=? terminal=?’

Nothing relevant in there, you’re right. Probably crashed before anything could have been written to log.
You’d need to prevent the kernel from rebooting the system so you can still check the kernel ring-buffer displayed on the screen.
If it is a panic, you could try to check out this: linux - Automatic Reboot after Kernel Panic - Server Fault

then use the sysreq keys Magic SysRq key - Wikipedia to get as much as possible out of the kernel (if it still responds).

I’s what I would do :}

The problem is that the laptop doesn’t freeze. It just completely crash and reboot straight away. No much I can do then. But I should not be the only one…

What could be done is a script to execute when resuming from suspend to log the state of the kernel at that time.

Hi @Pierre_van_Male

Is you BIOS version already up to date?
does the issue happen for both plugged and unplugged power cable?

Hi @Loell_Framework ,

Yes, my BIOS is up to date:

vmalep@framework:~$ sudo dmidecode -s bios-version
[sudo] password for vmalep: 
03.03

If it happens with the power cable plugged or not: good question. It only occurred a few time until now, so I am not sure. Definitely unplugged, but I will pay attention if it happens when plugged also.

Best regards,
Pierre

New crash this morning (laptop unplugged).

This is the last line of the journal log (just in case):


jan 22 08:08:07 framework avahi-daemon[1195]: New relevant interface wlp1s0.IPv6 for mDNS.
jan 22 08:08:07 framework avahi-daemon[1195]: Registering new address record for fe80::1957:f54f:f2ab:2818 on wlp1s0.*.
jan 22 08:08:07 framework dbus-daemon[2144]: apparmor="DENIED" operation="dbus_method_call"  bus="session" path="/" interface="org.freedesktop.DBus.Introspectable" member="Introspect" name=":1.39" mask="receive" pid=49568 label="firefox" peer_pid=2443 peer_label="unconfined"
jan 22 08:08:07 framework dbus-daemon[2144]: apparmor="DENIED" operation="dbus_method_call"  bus="session" path="/" interface="org.freedesktop.DBus.Introspectable" member="Introspect" name=":1.39" mask="receive" pid=49568 label="firefox" peer_pid=2443 peer_label="unconfined"

Is it from suspend or sleep mode?
If it is suspend, make sure your SWAP partition/file is a little larger than your RAM.
For suspend, can’t tell. The logs tell us nothing here.

Thanks @Jorg_Mertin for the FUP.

I guess it is suspend, because it is after having reopened the lid:

/etc/systemd/logind.conf:

#HandleLidSwitch=suspend

This said, I have 32Gb of RAM and 2GB of swap:

vmalep@framework:~$ free
total used free shared buff/cache available
Mem: 32016992 6473120 21463144 140424 4080728 24937572
Swap: 2002940 0 2002940

I will increase the swap anyway and see how it goes…

ref:

vmalep@framework:~$ free -h
total used free shared buff/cache available
Mem: 30Gi 6.4Gi 20Gi 114Mi 3.9Gi 23Gi
Swap: 32Gi 0B 32Gi

:crossed_fingers:

Best regards,
Pierre

If the laptop crashes again, I will resume this topic, but it seems to me that the issue was as swap file to small to store the RAM when the computer was ongoing on sleep mode.

Thanks @Jorg_Mertin for your support!