Laptop does not sleep when lid is closed

Hi there!

Ok, I searched the forums and found out 2 recent related issues, but none of them really solved my issue, so here it goes: “sometimes” when I close the lid the laptop just won’t sleep.

My system configuration:

$ inxi --admin --verbosity=7 --filter --no-host --width
System:
  Kernel: 5.10.68-1-MANJARO x86_64 bits: 64 compiler: gcc v: 11.1.0 
  parameters: BOOT_IMAGE=/boot/vmlinuz-5.10-x86_64 
  root=UUID=9ba09378-d7f5-44e4-9ae9-0d560f8f2481 ro quiet apparmor=1 
  security=apparmor udev.log_priority=3 
  Desktop: KDE Plasma 5.22.5 tk: Qt 5.15.2 info: latte-dock wm: kwin_x11 vt: 1 
  dm: SDDM Distro: Manjaro Linux base: Arch Linux 
Machine:
  Type: Laptop System: Dell product: Vostro 5402 v: N/A serial: <filter> 
  Chassis: type: 10 serial: <filter> 
  Mobo: Dell model: 0TMFFT v: A00 serial: <filter> UEFI: Dell v: 1.5.1 
  date: 06/04/2021 
Battery:
  ID-1: BAT0 charge: 47.7 Wh (83.7%) condition: 57.0/53.0 Wh (107.6%) 
  volts: 17.2 min: 15.0 model: BYD DELL TXD0314 type: Unknown serial: <filter> 
  status: Charging 
Memory:
  RAM: total: 15.37 GiB used: 4.07 GiB (26.5%) 
  RAM Report: permissions: Unable to run dmidecode. Root privileges required. 
CPU:
  Info: Quad Core model: 11th Gen Intel Core i7-1165G7 bits: 64 type: MT MCP 
  arch: Tiger Lake family: 6 model-id: 8C (140) stepping: 1 microcode: 88 
  cache: L2: 12 MiB bogomips: 27040 
  Speed: 1263 MHz min/max: 400/4700 MHz Core speeds (MHz): 1: 1263 2: 1496 
  3: 1690 4: 2226 5: 1472 6: 1154 7: 2450 8: 2015 
  Flags: 3dnowprefetch abm acpi adx aes aperfmperf apic arat arch_capabilities 
  arch_perfmon art avx avx2 avx512_bitalg avx512_vbmi2 avx512_vnni 
  avx512_vp2intersect avx512_vpopcntdq avx512bw avx512cd avx512dq avx512f 
  avx512ifma avx512vbmi avx512vl bmi1 bmi2 bts cat_l2 cdp_l2 clflush 
  clflushopt clwb cmov constant_tsc cpuid cpuid_fault cx16 cx8 de ds_cpl 
  dtes64 dtherm dts epb ept ept_ad erms est f16c flexpriority flush_l1d fma 
  fpu fsgsbase fsrm fxsr gfni ht hwp hwp_act_window hwp_epp hwp_notify 
  hwp_pkg_req ibpb ibrs ibrs_enhanced ida intel_pt invpcid invpcid_single 
  lahf_lm lm mca mce md_clear mmx monitor movbe movdir64b movdiri msr mtrr 
  nonstop_tsc nopl nx ospke pae pat pbe pcid pclmulqdq pdcm pdpe1gb pebs pge 
  pku pln pni popcnt pse pse36 pts rdpid rdrand rdseed rdt_a rdtscp rep_good 
  sdbg sep sha_ni smap smep split_lock_detect ss ssbd sse sse2 sse4_1 sse4_2 
  ssse3 stibp syscall tm tm2 tpr_shadow tsc tsc_adjust tsc_deadline_timer 
  tsc_known_freq umip vaes vme vmx vnmi vpclmulqdq vpid x2apic xgetbv1 xsave 
  xsavec xsaveopt xsaves xtopology xtpr 
  Vulnerabilities: Type: itlb_multihit status: Not affected 
  Type: l1tf status: Not affected 
  Type: mds status: Not affected 
  Type: meltdown status: Not affected 
  Type: spec_store_bypass 
  mitigation: Speculative Store Bypass disabled via prctl and seccomp 
  Type: spectre_v1 
  mitigation: usercopy/swapgs barriers and __user pointer sanitization 
  Type: spectre_v2 mitigation: Enhanced IBRS, IBPB: conditional, RSB filling 
  Type: srbds status: Not affected 
  Type: tsx_async_abort status: Not affected 
Graphics:
  Device-1: Intel TigerLake-LP GT2 [Iris Xe Graphics] vendor: Dell 
  driver: i915 v: kernel bus-ID: 00:02.0 chip-ID: 8086:9a49 class-ID: 0300 
  Device-2: NVIDIA GP108M [GeForce MX330] driver: nvidia v: 470.63.01 
  alternate: nouveau,nvidia_drm bus-ID: 2c:00.0 chip-ID: 10de:1d16 
  class-ID: 0302 
  Device-3: Realtek Integrated_Webcam_HD type: USB driver: uvcvideo 
  bus-ID: 3-6:4 chip-ID: 0bda:5538 class-ID: 0e02 serial: <filter> 
  Display: x11 server: X.Org 1.20.13 compositor: kwin_x11 driver: 
  loaded: modesetting,nvidia alternate: fbdev,nouveau,nv,vesa display-ID: :0 
  screens: 1 
  Screen-1: 0 s-res: 1920x1080 s-dpi: 96 s-size: 506x285mm (19.9x11.2") 
  s-diag: 581mm (22.9") 
  Monitor-1: eDP-1 res: 1920x1080 hz: 60 dpi: 158 size: 309x174mm (12.2x6.9") 
  diag: 355mm (14") 
  Monitor-2: HDMI-1 res: 1920x1080 hz: 60 dpi: 96 size: 510x290mm (20.1x11.4") 
  diag: 587mm (23.1") 
  OpenGL: renderer: Mesa Intel Xe Graphics (TGL GT2) v: 4.6 Mesa 21.2.2 
  direct render: Yes 
Audio:
  Device-1: Intel Tiger Lake-LP Smart Sound Audio vendor: Dell 
  driver: sof-audio-pci alternate: snd_hda_intel,snd_sof_pci bus-ID: 00:1f.3 
  chip-ID: 8086:a0c8 class-ID: 0401 
  Sound Server-1: ALSA v: k5.10.68-1-MANJARO running: yes 
  Sound Server-2: sndio v: N/A running: no 
  Sound Server-3: JACK v: 1.9.19 running: no 
  Sound Server-4: PulseAudio v: 15.0 running: yes 
  Sound Server-5: PipeWire v: 0.3.37 running: yes 
Network:
  Device-1: Intel Wi-Fi 6 AX201 driver: iwlwifi v: kernel port: 5000 
  bus-ID: 00:14.3 chip-ID: 8086:a0f0 class-ID: 0280 
  IF: wlp0s20f3 state: up mac: <filter> 
  IP v4: <filter> type: dynamic noprefixroute scope: global 
  broadcast: <filter> 
  IP v6: <filter> type: dynamic noprefixroute scope: global 
  IP v6: <filter> type: dynamic noprefixroute scope: global 
  IP v6: <filter> type: noprefixroute scope: link 
  Device-2: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet 
  vendor: Dell driver: r8169 v: kernel port: 3000 bus-ID: 2d:00.0 
  chip-ID: 10ec:8168 class-ID: 0200 
  IF: enp45s0 state: down mac: <filter> 
  WAN IP: <filter> 
Bluetooth:
  Device-1: Intel Bluetooth 9460/9560 Jefferson Peak (JfP) type: USB 
  driver: btusb v: 0.8 bus-ID: 3-10:5 chip-ID: 8087:0aaa class-ID: e001 
  Report: rfkill ID: hci0 rfk-id: 1 state: up address: see --recommends 
Logical:
  Message: No logical block device data found. 
RAID:
  Message: No RAID data found. 
Drives:
  Local Storage: total: 476.94 GiB used: 39.85 GiB (8.4%) 
  SMART Message: Unable to run smartctl. Root privileges required. 
  ID-1: /dev/nvme0n1 maj-min: 259:0 vendor: SK Hynix model: BC711 NVMe 512GB 
  size: 476.94 GiB block-size: physical: 512 B logical: 512 B speed: 31.6 Gb/s 
  lanes: 4 type: SSD serial: <filter> rev: 41002131 temp: 31.9 C scheme: GPT 
  Message: No optical or floppy data found. 
Partition:
  ID-1: / raw-size: 476.64 GiB size: 468.16 GiB (98.22%) 
  used: 39.85 GiB (8.5%) fs: ext4 dev: /dev/nvme0n1p2 maj-min: 259:2 
  label: N/A uuid: 9ba09378-d7f5-44e4-9ae9-0d560f8f2481 
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%) 
  used: 312 KiB (0.1%) fs: vfat dev: /dev/nvme0n1p1 maj-min: 259:1 label: N/A 
  uuid: 2EA7-013B 
Swap:
  Kernel: swappiness: 60 (default) cache-pressure: 100 (default) 
  ID-1: swap-1 type: file size: 512 MiB used: 0 KiB (0.0%) priority: -2 
  file: /swapfile 
Unmounted:
  Message: No unmounted partitions found. 
USB:
  Hub-1: 1-0:1 info: Full speed (or root) Hub ports: 1 rev: 2.0 
  speed: 480 Mb/s chip-ID: 1d6b:0002 class-ID: 0900 
  Hub-2: 2-0:1 info: Full speed (or root) Hub ports: 4 rev: 3.1 speed: 10 Gb/s 
  chip-ID: 1d6b:0003 class-ID: 0900 
  Hub-3: 3-0:1 info: Full speed (or root) Hub ports: 12 rev: 2.0 
  speed: 480 Mb/s chip-ID: 1d6b:0002 class-ID: 0900 
  Device-1: 3-2:2 info: Dell Dell Universal Receiver type: Keyboard,Mouse,HID 
  driver: hid-generic,usbhid interfaces: 3 rev: 2.0 speed: 12 Mb/s 
  power: 100mA chip-ID: 413c:8505 class-ID: 0300 
  Device-2: 3-5:3 info: Shenzhen Goodix FingerPrint type: <vendor specific> 
  driver: N/A interfaces: 1 rev: 2.0 speed: 12 Mb/s power: 100mA 
  chip-ID: 27c6:538d class-ID: ff00 
  Device-3: 3-6:4 info: Realtek Integrated_Webcam_HD type: Video 
  driver: uvcvideo interfaces: 2 rev: 2.0 speed: 480 Mb/s power: 500mA 
  chip-ID: 0bda:5538 class-ID: 0e02 serial: <filter> 
  Device-4: 3-10:5 info: Intel Bluetooth 9460/9560 Jefferson Peak (JfP) 
  type: Bluetooth driver: btusb interfaces: 2 rev: 2.0 speed: 12 Mb/s 
  power: 100mA chip-ID: 8087:0aaa class-ID: e001 
  Hub-4: 4-0:1 info: Full speed (or root) Hub ports: 4 rev: 3.1 speed: 10 Gb/s 
  chip-ID: 1d6b:0003 class-ID: 0900 
Sensors:
  System Temperatures: cpu: N/A mobo: N/A 
  Fan Speeds (RPM): cpu: 2952 
Info:
  Processes: 278 Uptime: 1h 51m wakeups: 13 Init: systemd v: 249 
  tool: systemctl Compilers: gcc: 11.1.0 Packages: 1369 pacman: 1362 lib: 414 
  flatpak: 0 snap: 7 Shell: Bash v: 5.1.8 running-in: konsole inxi: 3.3.06

I am using Plasma/KDE with the right energy settings (sleep when laptop lid closed). Last night I disconnected the power cable and when I woke up this morning it ran out of battery. Here is the main part of the log when it was just about to “die”:

out 12 08:29:44 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:29:44 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:29:44 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:29:44 kernel: audit: type=1400 audit(1634038184.065:11224): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:29:44 kernel: audit: type=1400 audit(1634038184.068:11225): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:29:44 kernel: audit: type=1400 audit(1634038184.068:11226): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:10 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:10 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:10 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:10 kernel: audit: type=1400 audit(1634038210.784:11227): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:10 kernel: audit: type=1400 audit(1634038210.784:11228): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:10 kernel: audit: type=1400 audit(1634038210.784:11229): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:17 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:17 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:17 kernel: audit: type=1400 audit(1634038217.858:11230): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:17 kernel: audit: type=1400 audit(1634038217.858:11231): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:17 kernel: audit: type=1400 audit(1634038217.858:11232): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:17 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 kded5[1115]: bluedevil: About to suspend
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.5196] manager: sleep: sleep requested (sleeping: no  enabled: yes)
out 12 08:30:19 ModemManager[458]: <info>  [sleep-monitor] system is about to suspend
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.5197] device (enp45s0): state change: unavailable -> unmanaged (reason 'sleeping', sys-iface-state: 'managed')
out 12 08:30:19 kscreenlocker_greet[39950]: Qt: Session management error: networkIdsList argument is NULL
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7544] device (p2p-dev-wlp0s20f3): state change: disconnected -> unmanaged (reason 'sleeping', sys-iface-state: 'managed')
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7548] manager: NetworkManager state is now ASLEEP
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7551] device (wlp0s20f3): state change: activated -> deactivating (reason 'sleeping', sys-iface-state: 'managed')
out 12 08:30:19 kernel: audit: type=1400 audit(1634038219.751:11233): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 kernel: audit: type=1400 audit(1634038219.751:11234): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 kernel: audit: type=1400 audit(1634038219.751:11235): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 kded5[1115]: plasma-nm: Unhandled active connection state change:  3
out 12 08:30:19 dbus-daemon[410]: [system] Activating via systemd: service name='org.freedesktop.nm_dispatcher' unit='dbus-org.freedesktop.nm-dispatcher.service' requested by ':1.4' (uid=0 pid=411 comm="/usr/bin/NetworkManager --no-daemon ")
out 12 08:30:19 systemd[1]: Starting Network Manager Script Dispatcher Service...
out 12 08:30:19 dbus-daemon[410]: [system] Successfully activated service 'org.freedesktop.nm_dispatcher'
out 12 08:30:19 systemd[1]: Started Network Manager Script Dispatcher Service.
out 12 08:30:19 audit[1]: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj==unconfined msg='unit=NetworkManager-dispatcher comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
out 12 08:30:19 kernel: audit: type=1130 audit(1634038219.768:11236): pid=1 uid=0 auid=4294967295 ses=4294967295 subj==unconfined msg='unit=NetworkManager-dispatcher comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
out 12 08:30:19 kernel: wlp0s20f3: deauthenticating from e8:20:e2:ce:22:bc by local choice (Reason: 3=DEAUTH_LEAVING)
out 12 08:30:19 wpa_supplicant[911]: wlp0s20f3: CTRL-EVENT-DISCONNECTED bssid=e8:20:e2:ce:22:bc reason=3 locally_generated=1
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 kernel: audit: type=1400 audit(1634038219.778:11237): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 kernel: audit: type=1400 audit(1634038219.778:11238): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 kernel: audit: type=1400 audit(1634038219.778:11239): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7902] device (wlp0s20f3): supplicant interface state: completed -> disconnected
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7902] device (wlp0s20f3): state change: deactivating -> disconnected (reason 'sleeping', sys-iface-state: 'managed')
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7906] dhcp4 (wlp0s20f3): canceled DHCP transaction
out 12 08:30:19 avahi-daemon[408]: Withdrawing address record for 2804:14d:5282:8e2d::1000 on wlp0s20f3.
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7907] dhcp4 (wlp0s20f3): state changed extended -> terminated
out 12 08:30:19 avahi-daemon[408]: Withdrawing address record for 2804:14d:5282:8e2d:c22d:922a:79ba:e6eb on wlp0s20f3.
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7910] dhcp6 (wlp0s20f3): canceled DHCP transaction
out 12 08:30:19 avahi-daemon[408]: Leaving mDNS multicast group on interface wlp0s20f3.IPv6 with address 2804:14d:5282:8e2d:c22d:922a:79ba:e6eb.
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.7910] dhcp6 (wlp0s20f3): state changed bound -> terminated
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.8072] device (wlp0s20f3): set-hw-addr: set MAC address to 7A:C0:15:23:87:D1 (scanning)
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 avahi-daemon[408]: Joining mDNS multicast group on interface wlp0s20f3.IPv6 with address fe80::2436:d6eb:bd72:6c62.
out 12 08:30:19 avahi-daemon[408]: Registering new address record for fe80::2436:d6eb:bd72:6c62 on wlp0s20f3.*.
out 12 08:30:19 avahi-daemon[408]: Withdrawing address record for fe80::2436:d6eb:bd72:6c62 on wlp0s20f3.
out 12 08:30:19 avahi-daemon[408]: Leaving mDNS multicast group on interface wlp0s20f3.IPv6 with address fe80::2436:d6eb:bd72:6c62.
out 12 08:30:19 skypeforlinux.desktop[1463]: ioctl failed for wlan0, errno = 19 (No such device)
out 12 08:30:19 skypeforlinux.desktop[1463]: ioctl failed for wlp2s0, errno = 19 (No such device)
out 12 08:30:19 skypeforlinux.desktop[1463]: ioctl failed for wlp3s0, errno = 19 (No such device)
out 12 08:30:19 skypeforlinux.desktop[1463]: ioctl failed for wlp4s0, errno = 19 (No such device)
out 12 08:30:19 avahi-daemon[408]: Interface wlp0s20f3.IPv6 no longer relevant for mDNS.
out 12 08:30:19 avahi-daemon[408]: Interface wlp0s20f3.IPv4 no longer relevant for mDNS.
out 12 08:30:19 avahi-daemon[408]: Leaving mDNS multicast group on interface wlp0s20f3.IPv4 with address 192.168.0.40.
out 12 08:30:19 avahi-daemon[408]: Withdrawing address record for 192.168.0.40 on wlp0s20f3.
out 12 08:30:19 avahi-daemon[408]: Joining mDNS multicast group on interface wlp0s20f3.IPv4 with address 192.168.0.40.
out 12 08:30:19 avahi-daemon[408]: New relevant interface wlp0s20f3.IPv4 for mDNS.
out 12 08:30:19 avahi-daemon[408]: Registering new address record for 192.168.0.40 on wlp0s20f3.IPv4.
out 12 08:30:19 avahi-daemon[408]: Withdrawing address record for 192.168.0.40 on wlp0s20f3.
out 12 08:30:19 avahi-daemon[408]: Leaving mDNS multicast group on interface wlp0s20f3.IPv4 with address 192.168.0.40.
out 12 08:30:19 avahi-daemon[408]: Interface wlp0s20f3.IPv4 no longer relevant for mDNS.
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.9607] device (wlp0s20f3): state change: disconnected -> unmanaged (reason 'sleeping', sys-iface-state: 'managed')
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:19 NetworkManager[411]: <info>  [1634038219.9745] device (wlp0s20f3): set-hw-addr: reset MAC address to 00:D7:6D:01:DE:E3 (unmanage)
out 12 08:30:19 kscreenlocker_greet[39950]: qt.svg: link #fcitx-kbd is undefined!
out 12 08:30:20 kscreenlocker_greet[39950]: qt.virtualkeyboard.hunspell: Hunspell dictionary is missing for "en_US" . Search paths ("/usr/share/qt/qtvirtualkeyboard/hunspell", "/usr/share/hunspell", "/usr/share/myspell/dicts")
out 12 08:30:20 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:20 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:20 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:20 systemd[1]: Reached target Sleep.
out 12 08:30:20 systemd[1]: Starting Hybrid Suspend+Hibernate...
out 12 08:30:20 kernel: PM: Image not found (code -22)
out 12 08:30:20 wpa_supplicant[911]: wlp0s20f3: CTRL-EVENT-REGDOM-CHANGE init=DRIVER type=WORLD
out 12 08:30:20 wpa_supplicant[911]: wlp0s20f3: CTRL-EVENT-REGDOM-CHANGE init=DRIVER type=WORLD
out 12 08:30:20 systemd-sleep[39983]: Entering sleep state 'hybrid-sleep'...
out 12 08:30:20 kernel: PM: hibernation: hibernation entry
out 12 08:30:25 kernel: Filesystems sync: 0.007 seconds
out 12 08:30:25 kernel: Freezing user space processes ... (elapsed 0.008 seconds) done.
out 12 08:30:25 kernel: OOM killer disabled.
out 12 08:30:25 kernel: PM: hibernation: Marking nosave pages: [mem 0x00000000-0x00000fff]
out 12 08:30:25 kernel: PM: hibernation: Marking nosave pages: [mem 0x0009f000-0x000fffff]
out 12 08:30:25 kernel: PM: hibernation: Marking nosave pages: [mem 0x5ac68000-0x5acf0fff]
out 12 08:30:25 kernel: PM: hibernation: Marking nosave pages: [mem 0x5f72b000-0x63ffefff]
out 12 08:30:25 kernel: PM: hibernation: Marking nosave pages: [mem 0x64000000-0xffffffff]
out 12 08:30:25 kernel: PM: hibernation: Basic memory bitmaps created
out 12 08:30:25 kernel: PM: hibernation: Preallocating image memory
out 12 08:30:25 kernel: PM: hibernation: Allocated 1160221 pages for snapshot
out 12 08:30:25 kernel: PM: hibernation: Allocated 4640884 kbytes in 2.57 seconds (1805.79 MB/s)
out 12 08:30:25 kernel: Freezing remaining freezable tasks ... (elapsed 0.001 seconds) done.
out 12 08:30:25 kernel: printk: Suspending console(s) (use no_console_suspend to debug)
out 12 08:30:25 kernel: ACPI: EC: interrupt blocked
out 12 08:30:25 kernel: Disabling non-boot CPUs ...
out 12 08:30:25 kernel: IRQ 158: no longer affine to CPU1
out 12 08:30:25 kernel: smpboot: CPU 1 is now offline
out 12 08:30:25 kernel: IRQ 159: no longer affine to CPU2
out 12 08:30:25 kernel: smpboot: CPU 2 is now offline
out 12 08:30:25 kernel: IRQ 160: no longer affine to CPU3
out 12 08:30:25 kernel: smpboot: CPU 3 is now offline
out 12 08:30:25 kernel: IRQ 161: no longer affine to CPU4
out 12 08:30:25 kernel: smpboot: CPU 4 is now offline
out 12 08:30:25 kernel: IRQ 162: no longer affine to CPU5
out 12 08:30:25 kernel: smpboot: CPU 5 is now offline
out 12 08:30:25 kernel: IRQ 163: no longer affine to CPU6
out 12 08:30:25 kernel: smpboot: CPU 6 is now offline
out 12 08:30:25 kernel: IRQ 164: no longer affine to CPU7
out 12 08:30:25 kernel: smpboot: CPU 7 is now offline
out 12 08:30:25 kernel: PM: hibernation: Creating image:
out 12 08:30:25 kernel: PM: hibernation: Need to copy 1147327 pages
out 12 08:30:25 kernel: PM: hibernation: Normal pages needed: 1147327 + 1024, available pages: 2976598
out 12 08:30:25 kernel: PM: hibernation: Image created (1147327 pages copied)
out 12 08:30:25 kernel: Enabling non-boot CPUs ...
out 12 08:30:25 kernel: x86: Booting SMP configuration:
out 12 08:30:25 kernel: smpboot: Booting Node 0 Processor 1 APIC 0x2
out 12 08:30:25 kernel: CPU1 is up
out 12 08:30:25 kernel: smpboot: Booting Node 0 Processor 2 APIC 0x4
out 12 08:30:25 kernel: CPU2 is up
out 12 08:30:25 kernel: smpboot: Booting Node 0 Processor 3 APIC 0x6
out 12 08:30:25 kernel: CPU3 is up
out 12 08:30:25 kernel: smpboot: Booting Node 0 Processor 4 APIC 0x1
out 12 08:30:25 kernel: CPU4 is up
out 12 08:30:25 kernel: smpboot: Booting Node 0 Processor 5 APIC 0x3
out 12 08:30:25 kernel: CPU5 is up
out 12 08:30:25 kernel: smpboot: Booting Node 0 Processor 6 APIC 0x5
out 12 08:30:25 kernel: CPU6 is up
out 12 08:30:25 kernel: smpboot: Booting Node 0 Processor 7 APIC 0x7
out 12 08:30:25 kernel: CPU7 is up
out 12 08:30:25 kernel: ACPI: EC: interrupt unblocked
out 12 08:30:25 kernel: nvme nvme0: 8/0/0 default/read/poll queues
out 12 08:30:25 kernel: PM: Cannot get swap writer
out 12 08:30:25 kernel: mei_hdcp 0000:00:16.0-b638ab7e-94e2-4ea2-a552-d1c54b627f04: bound 0000:00:02.0 (ops i915_hdcp_component_ops [i915])
out 12 08:30:25 kernel: PM: hibernation: Basic memory bitmaps freed
out 12 08:30:25 kernel: OOM killer enabled.
out 12 08:30:25 kernel: Restarting tasks ... done.
out 12 08:30:25 kernel: kauditd_printk_skb: 18 callbacks suppressed
out 12 08:30:25 kernel: audit: type=1400 audit(1634038225.869:11258): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 kernel: audit: type=1400 audit(1634038225.869:11259): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 kernel: audit: type=1400 audit(1634038225.869:11260): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 wpa_supplicant[911]: wlp0s20f3: CTRL-EVENT-REGDOM-CHANGE init=DRIVER type=COUNTRY alpha2=BR
out 12 08:30:25 kded5[1115]: plasma-nm: Not emitting connection deactivated notification as we're about to suspend
out 12 08:30:25 kernel: PM: hibernation: hibernation exit
out 12 08:30:25 wpa_supplicant[911]: wlp0s20f3: CTRL-EVENT-REGDOM-CHANGE init=DRIVER type=WORLD
out 12 08:30:25 systemd-sleep[39983]: Failed to put system to sleep. System resumed again: No space left on device
out 12 08:30:25 wpa_supplicant[911]: nl80211: deinit ifname=wlp0s20f3 disabled_11b_rates=0
out 12 08:30:25 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 audit[1759]: AVC apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 kernel: audit: type=1400 audit(1634038225.966:11261): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/virtual/net/lo/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 kernel: audit: type=1400 audit(1634038225.966:11262): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:1c.7/0000:2d:00.0/net/enp45s0/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:25 kernel: audit: type=1400 audit(1634038225.966:11263): apparmor="DENIED" operation="open" profile="snap.skype.skype" name="/sys/devices/pci0000:00/0000:00:14.3/net/wlp0s20f3/speed" pid=1759 comm="skypeforlinux" requested_mask="r" denied_mask="r" fsuid=1000 ouid=0
out 12 08:30:26 systemd-sleep[39983]: Couldn't hybrid sleep, will try to suspend instead.
out 12 08:30:26 systemd-sleep[39983]: Entering sleep state 'suspend'...
out 12 08:30:26 kernel: PM: suspend entry (s2idle)
out 12 08:30:26 kernel: Filesystems sync: 0.001 seconds
out 12 08:30:30 systemd[1]: NetworkManager-dispatcher.service: Deactivated successfully.
out 12 08:30:30 audit[1]: SERVICE_STOP pid=1 uid=0 auid=4294967295 ses=4294967295 subj==unconfined msg='unit=NetworkManager-dispatcher comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
out 12 08:30:30 kernel: audit: type=1131 audit(1634038230.723:11264): pid=1 uid=0 auid=4294967295 ses=4294967295 subj==unconfined msg='unit=NetworkManager-dispatcher comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'
-- Boot bc2cef7da8c449c49799685dcab1bf1c --

Apparently, skype is not allowing the system to sleep. It eventually tries to hibernate, but that does not work either. The thing is that this is not the first time it happened. Previously, I did not have skype installed yet, so I assume it could be something else? The same thing happened on my previous laptop (running Arch Linux with Plasma).

Thanks!

sleep and hibernation is a user choice and it always requires tweaking for the specific hardware in question and hibernation requires a regular swapfile or partition.

I was not able to reproduce the problem (looks very random). What I did notice is that when it indeed slept, the message “Reached target Sleep” was logged whereas in the faulty case it did not. It seems like the event (closing the lid) was not interpreted and did not trigger the action (sleep).

@linux-aarhus: any idea on where I could find information about tweaking for my hardware? As for hibernation, I never intended to use it (thus lacking swapping space). It happened because the computer did not sleep and reached the hibernation condition (extremely low battery).

Thanks!

KDE is out my league - but usually you setup the various actions in the power settings section.

Also be aware that you need to set a specific action to none if it otherwise implies an action which is not available - like hibernation when there is no swapspace.