Sample Header Ad - 728x90

Unix & Linux Stack Exchange

Q&A for users of Linux, FreeBSD and other Unix-like operating systems

Latest Questions

0 votes
0 answers
28 views
External USB drive with zfs pool won't go to sleep (most of the time)
I have an external hard disk with a ZFS pool on it. The data is accessed very infrequently so I would like to drive to go to sleep after some inactivity, which I set to 10min: hdparm -S 120 /dev/disk/by-id/usb-Seagate_Expansion_Desk_NAABDT6W-0\:0 With a cron script I check the status of the drive ov...
I have an external hard disk with a ZFS pool on it. The data is accessed very infrequently so I would like to drive to go to sleep after some inactivity, which I set to 10min: hdparm -S 120 /dev/disk/by-id/usb-Seagate_Expansion_Desk_NAABDT6W-0\:0 With a cron script I check the status of the drive over time: hdparm -C /dev/disk/by-id/usb-Seagate_Expansion_Desk_NAABDT6W-0\:0 This works sometimes but most of the time, the drive remains in "active/idle" all the time, even if no access occurs. The ZFS pool is not performing scrubs. There are no zvols. All datasets (some of them encrypted) are mounted to under /zpseagate8tb/ (and /zpseagate8tb_bind/ for use in LXC containers). I confirmed no file descriptors to any of the datasets are open: # lsof -w | grep zpseagate8tb # What else could be preventing the drive from going to sleep?
divB (218 rep)
May 29, 2025, 05:36 PM
0 votes
1 answers
2635 views
Second display does not turn on after sleep
After my machine (Fedora 35) goes to sleep and wakes, my second monitor won't turn on again. I can reproduce the same problem by running ``` xrandr --output HDMI-1-1 --off xrandr --output HDMI-1-1 --auto ``` The second command will output ```xrandr: Configure crtc 3 failed```, without turning on the...
After my machine (Fedora 35) goes to sleep and wakes, my second monitor won't turn on again. I can reproduce the same problem by running
xrandr --output HDMI-1-1 --off 
xrandr --output HDMI-1-1 --auto
The second command will output
: Configure crtc 3 failed
, without turning on the monitor. For some time now, my Problem Reporting shows a system failure "xorg-x11-drv-nouveau". I do not know if there is a link. My system journal shows the following:
Feb 13 18:33:46 fedora kernel: nouveau 0000:01:00.0: acr: AHESASC binary failed
Feb 13 18:33:46 fedora kernel: nouveau 0000:01:00.0: acr: init failed, -110
Feb 13 18:33:46 fedora kernel: nouveau 0000:01:00.0: init failed with -110
Feb 13 18:33:46 fedora kernel: nouveau: systemd-logind:00000000:00000080: init failed with -110
Feb 13 18:33:46 fedora kernel: nouveau: DRM-master:00000000:00000000: init failed with -110
Feb 13 18:33:46 fedora kernel: nouveau: DRM-master:00000000:00000000: init failed with -110
Feb 13 18:33:46 fedora kernel: nouveau 0000:01:00.0: DRM: Client resume failed with error: -110
Feb 13 18:33:46 fedora kernel: nouveau 0000:01:00.0: DRM: resume failed with: -110
Feb 13 18:33:47 fedora kernel: nouveau 0000:01:00.0: DRM: Dropped ACPI reprobe event due to RPM error: -22
Feb 13 18:33:47 fedora kernel: nouveau 0000:01:00.0: DRM: Dropped ACPI reprobe event due to RPM error: -22
Feb 13 18:33:48 fedora abrt-server: Oops looks like a problem in kernel module, new component xorg-x11-drv-nouveau
Thank you!
ibroketheinternet (1 rep)
Feb 13, 2022, 06:53 PM • Last activity: May 2, 2025, 03:04 PM
11 votes
1 answers
743 views
How do I figure out what is inhibiting my screensaver and preventing lock screen/sleep?
At some point last month, I realized my screensaver (`xscreensaver` in this case) was no longer blanking the screen (and therefore also not locking it, and going into dpms idle/standby) at all. I had not changed any settings, but I did install `nomachine` in that time, which I suspected might be the...
At some point last month, I realized my screensaver (xscreensaver in this case) was no longer blanking the screen (and therefore also not locking it, and going into dpms idle/standby) at all. I had not changed any settings, but I did install nomachine in that time, which I suspected might be the culprit, but the nomachine server was disabled and that did not make a difference. Strangely, even when I manually locked the screen, after a few seconds of the screen being locked, it would prompt for my password to unlock, as if the mouse had been moved, and therefore dpms/standby never had a chance to kick in. But checking my mouse, and putting it on its side, and running xinput diagnostics eliminated hardware issues as the reason. Other questions ask similar things, but I figured I would create this question to compile what I did to solve my problem, in the hopes that it will help someone else. In other forums/questions, it is mentioned that this affects other things like hibernation and sleep, so hopefully this will give others a chance at solving this if they run into it in their use cases.
insaner (541 rep)
Apr 3, 2025, 11:50 AM • Last activity: Apr 3, 2025, 09:35 PM
0 votes
0 answers
44 views
Black Screen after dim/sleep
I am using Ubuntu-based KDE Neon and recently added a new user to my machine. Ever since I added the new user, whenever the machine goes to sleep - usually due to inactivity - the screen stays black, no matter what I do. The only thing that is visible is the cursor and it disappears when I press esc...
I am using Ubuntu-based KDE Neon and recently added a new user to my machine. Ever since I added the new user, whenever the machine goes to sleep - usually due to inactivity - the screen stays black, no matter what I do. The only thing that is visible is the cursor and it disappears when I press escape key and appears when I press anything else. This laptop has an AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx. I do not dual boot and kernel is Linux 6.8.0-52-generic x86_64, the operating system is KDE Neon 6.2 with release 22.04 (jammy), and the laptop is an Asus VivoBook X512DA.
ape1r0n (1 rep)
Mar 22, 2025, 07:26 PM • Last activity: Mar 23, 2025, 12:12 PM
1 votes
1 answers
41 views
Can Audacious be configured to keep the computer awake while playing music?
Please read before typing: "No, it is not possible with Audacious on its own" is a *totally OK* answer **I would accept** as the answer, if so. If you *do not know* that is totally OK, but please **do not** speculate out-loud here for the sake of getting points. Please do not recommend a solution th...
Please read before typing: "No, it is not possible with Audacious on its own" is a *totally OK* answer **I would accept** as the answer, if so. If you *do not know* that is totally OK, but please **do not** speculate out-loud here for the sake of getting points. Please do not recommend a solution that involves a disparate piece of software (like caffeine-ng). When playing back music with Audacious, my desktop computer (running Manjaro) goes to sleep after 10 minutes (as configured in power settings). This does not happen when playing back video in programs like mpv or VLC. Can Audacious itself be configured somehow to keep the computer awake while playing music?
aoeu (111 rep)
Mar 10, 2025, 09:06 PM • Last activity: Mar 11, 2025, 12:37 AM
-4 votes
2 answers
126 views
What is difference between suspending a computer and just walking away from it?
I've been looking at lots of web content about sleep, suspend, hibernate modes of a computer but I have not come across any discussion of this seemingly simple question: **What, if anything, is the difference between** 1. **just walking away from a linux computer**, running, let's say Ubuntu 22.4 LT...
I've been looking at lots of web content about sleep, suspend, hibernate modes of a computer but I have not come across any discussion of this seemingly simple question: **What, if anything, is the difference between** 1. **just walking away from a linux computer**, running, let's say Ubuntu 22.4 LTS but it really could be any distro and version, and 2. **explicitly invoking the suspend command**, either from the command line or a gui? Both cases are supposed to enable you to come back to the computer later, click the mouse or type a key and "wake it up". ***If there is a difference, what is it? If there is no difference, why is the suspend command necessary?*** And by the way, is there a name for "just walking away"? Is that what "sleep" means? I find these terms thrown around without any precise definition of what each means. **Update: Why am I asking this?** **Most of the material I find in relation to the different forms of computer sleep, suspend, or hibernation assume that the main concern of anyone asking it is power consumption. This is not my concern.** **My concern is that when I leave my computer I can reliably come back to it and not need to reboot.** My concern is that I have purchased a fairly expensive laptop computer from Lenovo, with an nVidia graphics card (not going to get into the technical details here) that I cannot walk away from and reliably assume the system will wake up when I come back to it and press a key or make a mouse click. Sometimes it works, sometimes it doesn't. It seems that explicitly invoking suspend is a little more reliable, doesn't crash as often, but it is not 100% reliable, maybe 90%. On my previous computer, a 10-year old Lenovo laptop, I did not have to worry about any of this. ***Update 2: correcting original to mention "getting rid of Secure Boot under UEFI" rather than "getting rid of UEFI" as a prerequisite of achieving hibernation.*** Hibernation suggests itself as the most reliable way to achieve what I am after, but it is not currently available on my computer which uses Secure Boot under UEFI. So one option is disabling Secure Boot. I was reluctant to do it but that seems to be the way I have to go. **My main concern is reliability, not power consumption.**
Steve Cohen (519 rep)
Mar 6, 2025, 08:45 PM • Last activity: Mar 7, 2025, 08:07 AM
1 votes
0 answers
117 views
Asus TUF A16 AMD Laptop wakes up immediately after sleep when External Monitor is plugged in
I'm using the ASUS TUF A16 which comes with AMD Radeon RX 7700S dedicated GPU, and an integrated Radeon 680M. It manages them through a MUX switcher in the laptop, with the only option to run dedicated-gpu only on boot menu. I'm on KDE-fedora, but I have replicated the problem on multiple distros an...
I'm using the ASUS TUF A16 which comes with AMD Radeon RX 7700S dedicated GPU, and an integrated Radeon 680M. It manages them through a MUX switcher in the laptop, with the only option to run dedicated-gpu only on boot menu. I'm on KDE-fedora, but I have replicated the problem on multiple distros and desktop environments. The problem I'm having is that the laptop goes to sleep and immediately wakes up when my external monitor is plugged in. I've done some research and troubleshooting, and I've come to think the cause is that the external GPU restarts whenever it goes to sleep with the external monitor on, possibly related to AMD's MUX switch, but that's just speculation. I assume this is because the hdmi is run by the dgpu, and doesn't work with the igpu, but how to fix it has proven so far to be out of my league. This is the last minute of journalctl log after suspension: Dec 31 12:13:29 LaptopHostName systemd-logind: The system will suspend now! Dec 31 12:13:29 LaptopHostName ModemManager: [sleep-monitor-systemd] system is about to suspend Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.7223] manager: sleep: sleep requested (sleeping: no enabled: yes) Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.7229] device (eno1): state change: unavailable -> unmanaged (reason 'unmanaged-sleeping', managed-type: 'full') Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.7347] device (p2p-dev-wlp6s0): state change: disconnected -> unmanaged (reason 'unmanaged-sleeping', managed-type: 'full') Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.7350] manager: NetworkManager state is now ASLEEP Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.7352] device (wlp6s0): state change: activated -> deactivating (reason 'sleeping', managed-type: 'full') Dec 31 12:13:29 LaptopHostName kded6: org.kde.plasma.nm.kded: Unhandled active connection state change: 3 Dec 31 12:13:29 LaptopHostName systemd: Starting NetworkManager-dispatcher.service - Network Manager Script Dispatcher Service... ░░ Subject: A start job for unit NetworkManager-dispatcher.service has begun execution ░░ Defined-By: systemd ░░ Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel ░░ ░░ A start job for unit NetworkManager-dispatcher.service has begun execution. ░░ ░░ The job identifier is 13845. Dec 31 12:13:29 LaptopHostName systemd: Started NetworkManager-dispatcher.service - Network Manager Script Dispatcher Service. ░░ Subject: A start job for unit NetworkManager-dispatcher.service has finished successfully ░░ Defined-By: systemd ░░ Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel ░░ ░░ A start job for unit NetworkManager-dispatcher.service has finished successfully. ░░ ░░ The job identifier is 13845. Dec 31 12:13:29 LaptopHostName audit: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=NetworkManager-dispatcher comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success' Dec 31 12:13:29 LaptopHostName kernel: wlp6s0: deauthenticating from 58:ae:f1:59:cf:cc by local choice (Reason: 3=DEAUTH_LEAVING) Dec 31 12:13:29 LaptopHostName wpa_supplicant: nl80211: send_event_marker failed: Source based routing not supported Dec 31 12:13:29 LaptopHostName wpa_supplicant: wlp6s0: CTRL-EVENT-DISCONNECTED bssid=58:ae:f1:59:cf:cc reason=3 locally_generated=1 Dec 31 12:13:29 LaptopHostName wpa_supplicant: wlp6s0: CTRL-EVENT-DSCP-POLICY clear_all Dec 31 12:13:29 LaptopHostName wpa_supplicant: wlp6s0: CTRL-EVENT-REGDOM-CHANGE init=CORE type=WORLD Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.9105] device (wlp6s0): supplicant interface state: completed -> disconnected Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.9107] device (wlp6s0): state change: deactivating -> disconnected (reason 'sleeping', managed-type: 'full') Dec 31 12:13:29 LaptopHostName avahi-daemon: Withdrawing address record for fe80::55c1:d249:2295:4446 on wlp6s0. Dec 31 12:13:29 LaptopHostName avahi-daemon: Leaving mDNS multicast group on interface wlp6s0.IPv6 with address fe80::55c1:d249:2295:4446. Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.9114] dhcp4 (wlp6s0): canceled DHCP transaction Dec 31 12:13:29 LaptopHostName avahi-daemon: Interface wlp6s0.IPv6 no longer relevant for mDNS. Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.9114] dhcp4 (wlp6s0): activation: beginning transaction (timeout in 45 seconds) Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.9114] dhcp4 (wlp6s0): state changed no lease Dec 31 12:13:29 LaptopHostName audit: NETFILTER_CFG table=firewalld:51 family=1 entries=34 op=nft_unregister_rule pid=2027 subj=system_u:system_r:firewalld_t:s0 comm="firewalld" Dec 31 12:13:29 LaptopHostName audit: SYSCALL arch=c000003e syscall=46 success=yes exit=2680 a0=6 a1=7fffc43f33f0 a2=0 a3=7fffc43f3560 items=0 ppid=1 pid=2027 auid=4294967295 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4294967295 comm="firewalld" exe="/usr/bin/python3.13" subj=system_u:system_r:firewalld_t:s0 key=(null) Dec 31 12:13:29 LaptopHostName audit: PROCTITLE proctitle=2F7573722F62696E2F707974686F6E33002D7350002F7573722F7362696E2F6669726577616C6C64002D2D6E6F666F726B002D2D6E6F706964 Dec 31 12:13:29 LaptopHostName avahi-daemon: Interface wlp6s0.IPv4 no longer relevant for mDNS. Dec 31 12:13:29 LaptopHostName avahi-daemon: Leaving mDNS multicast group on interface wlp6s0.IPv4 with address 192.168.1.9. Dec 31 12:13:29 LaptopHostName avahi-daemon: Withdrawing address record for 192.168.1.9 on wlp6s0. Dec 31 12:13:29 LaptopHostName NetworkManager: [1735658009.9423] device (wlp6s0): set-hw-addr: set MAC address to 1A:DF:02:F4:56:54 (scanning) Dec 31 12:13:29 LaptopHostName avahi-daemon: Joining mDNS multicast group on interface wlp6s0.IPv4 with address 192.168.1.9. Dec 31 12:13:29 LaptopHostName avahi-daemon: New relevant interface wlp6s0.IPv4 for mDNS. Dec 31 12:13:29 LaptopHostName avahi-daemon: Registering new address record for 192.168.1.9 on wlp6s0.IPv4. Dec 31 12:13:29 LaptopHostName avahi-daemon: Withdrawing address record for 192.168.1.9 on wlp6s0. Dec 31 12:13:29 LaptopHostName avahi-daemon: Leaving mDNS multicast group on interface wlp6s0.IPv4 with address 192.168.1.9. Dec 31 12:13:29 LaptopHostName avahi-daemon: Interface wlp6s0.IPv4 no longer relevant for mDNS. Dec 31 12:13:29 LaptopHostName systemd-resolved: wlp6s0: Bus client set default route setting: no Dec 31 12:13:29 LaptopHostName systemd-resolved: wlp6s0: Bus client reset DNS server list. Dec 31 12:13:30 LaptopHostName NetworkManager: [1735658010.0132] device (wlp6s0): supplicant interface state: disconnected -> interface_disabled Dec 31 12:13:30 LaptopHostName NetworkManager: [1735658010.0134] device (wlp6s0): supplicant interface state: interface_disabled -> disconnected Dec 31 12:13:30 LaptopHostName NetworkManager: [1735658010.0136] device (wlp6s0): state change: disconnected -> unmanaged (reason 'unmanaged-sleeping', managed-type: 'full') Dec 31 12:13:30 LaptopHostName chronyd: Source 216.238.106.159 offline Dec 31 12:13:30 LaptopHostName chronyd: Source 143.107.229.210 offline Dec 31 12:13:30 LaptopHostName chronyd: Source 200.160.7.197 offline Dec 31 12:13:30 LaptopHostName chronyd: Can't synchronise: no selectable sources Dec 31 12:13:30 LaptopHostName chronyd: Source 200.160.7.193 offline Dec 31 12:13:30 LaptopHostName NetworkManager: [1735658010.0599] device (wlp6s0): set-hw-addr: reset MAC address to 94:BB:43:74:7D:0D (unmanage) Dec 31 12:13:30 LaptopHostName wpa_supplicant: wlp6s0: CTRL-EVENT-DSCP-POLICY clear_all Dec 31 12:13:30 LaptopHostName systemd: Reached target sleep.target - Sleep. ░░ Subject: A start job for unit sleep.target has finished successfully ░░ Defined-By: systemd ░░ Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel ░░ ░░ A start job for unit sleep.target has finished successfully. ░░ ░░ The job identifier is 14007. Dec 31 12:13:30 LaptopHostName systemd: Starting systemd-suspend.service - System Suspend... ░░ Subject: A start job for unit systemd-suspend.service has begun execution ░░ Defined-By: systemd ░░ Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel ░░ ░░ A start job for unit systemd-suspend.service has begun execution. ░░ ░░ The job identifier is 14004. Dec 31 12:13:30 LaptopHostName wpa_supplicant: wlp6s0: CTRL-EVENT-DSCP-POLICY clear_all Dec 31 12:13:30 LaptopHostName wpa_supplicant: nl80211: deinit ifname=wlp6s0 disabled_11b_rates=0 Dec 31 12:13:30 LaptopHostName systemd-sleep: User sessions remain unfrozen on explicit request ($SYSTEMD_SLEEP_FREEZE_USER_SESSIONS=0). Dec 31 12:13:30 LaptopHostName systemd-sleep: This is not recommended, and might result in unexpected behavior, particularly Dec 31 12:13:30 LaptopHostName systemd-sleep: in suspend-then-hibernate operations or setups with encrypted home directories. Dec 31 12:13:30 LaptopHostName systemd-sleep: Performing sleep operation 'suspend'... ░░ Subject: System sleep state suspend entered ░░ Defined-By: systemd ░░ Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel ░░ ░░ The system has now entered the suspend sleep state. Dec 31 12:13:30 LaptopHostName kernel: PM: suspend entry (s2idle) Dec 31 12:13:30 LaptopHostName kernel: Filesystems sync: 0.032 seconds Dec 31 12:13:32 LaptopHostName kernel: Freezing user space processes Dec 31 12:13:32 LaptopHostName kernel: Freezing user space processes completed (elapsed 0.003 seconds) Dec 31 12:13:32 LaptopHostName kernel: OOM killer disabled. Dec 31 12:13:32 LaptopHostName kernel: Freezing remaining freezable tasks Dec 31 12:13:32 LaptopHostName kernel: Freezing remaining freezable tasks completed (elapsed 0.001 seconds) Dec 31 12:13:32 LaptopHostName kernel: printk: Suspending console(s) (use no_console_suspend to debug) Dec 31 12:13:32 LaptopHostName kernel: queueing ieee80211 work while going to suspend Dec 31 12:13:32 LaptopHostName kernel: PM: suspend devices took 0.282 seconds Dec 31 12:13:32 LaptopHostName kernel: [drm] PCIE GART of 1024M enabled (table at 0x000000F41FC00000). Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: SMU is resuming... Dec 31 12:13:32 LaptopHostName kernel: [drm] PCIE GART of 512M enabled (table at 0x00000081FEB00000). Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: PSP is resuming... Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: SMU is resumed successfully! Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring gfx_0.0.0 uses VM inv eng 0 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring gfx_0.1.0 uses VM inv eng 1 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.0.0 uses VM inv eng 4 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.1.0 uses VM inv eng 5 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.2.0 uses VM inv eng 6 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.3.0 uses VM inv eng 7 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.0.1 uses VM inv eng 8 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.1.1 uses VM inv eng 9 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.2.1 uses VM inv eng 10 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring comp_1.3.1 uses VM inv eng 11 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring kiq_0.2.1.0 uses VM inv eng 12 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring sdma0 uses VM inv eng 13 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring vcn_dec_0 uses VM inv eng 0 on hub 8 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring vcn_enc_0.0 uses VM inv eng 1 on hub 8 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring vcn_enc_0.1 uses VM inv eng 4 on hub 8 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:77:00.0: amdgpu: ring jpeg_dec uses VM inv eng 5 on hub 8 Dec 31 12:13:32 LaptopHostName kernel: nvme nvme0: 16/0/0 default/read/poll queues Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: reserve 0x1300000 from 0x81fc000000 for PSP TMR Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: RAS: optional ras ta ucode is not available Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: RAP: optional rap ta ucode is not available Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: SECUREDISPLAY: securedisplay ta ucode is not available Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: SMU is resuming... Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: smu driver if version = 0x00000035, smu fw if version = 0x00000040, smu fw program = 0, smu fw version = 0x00525c00 (82.92.0) Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: SMU driver if version not matched Dec 31 12:13:32 LaptopHostName kernel: usb 9-1: reset full-speed USB device number 7 using xhci_hcd Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: SMU is resumed successfully! Dec 31 12:13:32 LaptopHostName kernel: [drm] DMUB hardware initialized: version=0x07002A00 Dec 31 12:13:32 LaptopHostName kernel: usb 9-1: PM: dpm_run_callback(): usb_dev_resume returns -5 Dec 31 12:13:32 LaptopHostName kernel: usb 9-1: PM: failed to resume async: error -5 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring gfx_0.0.0 uses VM inv eng 0 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.0.0 uses VM inv eng 1 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.1.0 uses VM inv eng 4 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.2.0 uses VM inv eng 6 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.3.0 uses VM inv eng 7 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.0.1 uses VM inv eng 8 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.1.1 uses VM inv eng 9 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.2.1 uses VM inv eng 10 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring comp_1.3.1 uses VM inv eng 11 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring sdma0 uses VM inv eng 12 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring sdma1 uses VM inv eng 13 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring vcn_unified_0 uses VM inv eng 0 on hub 8 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring jpeg_dec uses VM inv eng 1 on hub 8 Dec 31 12:13:32 LaptopHostName kernel: amdgpu 0000:03:00.0: amdgpu: ring mes_kiq_3.1.0 uses VM inv eng 14 on hub 0 Dec 31 12:13:32 LaptopHostName kernel: [drm] ring gfx_32823.1.1 was added Dec 31 12:13:32 LaptopHostName kernel: [drm] ring compute_32823.2.2 was added Dec 31 12:13:32 LaptopHostName kernel: [drm] ring sdma_32823.3.3 was added Dec 31 12:13:32 LaptopHostName kernel: [drm] ring gfx_32823.1.1 ib test pass Dec 31 12:13:32 LaptopHostName kernel: [drm] ring compute_32823.2.2 ib test pass Dec 31 12:13:32 LaptopHostName kernel: [drm] ring sdma_32823.3.3 ib test pass Dec 31 12:13:32 LaptopHostName kernel: PM: resume devices took 1.520 seconds Dec 31 12:13:32 LaptopHostName kernel: OOM killer enabled. Dec 31 12:13:32 LaptopHostName kernel: Restarting tasks ... Dec 31 12:13:32 LaptopHostName kernel: usb 9-1: USB disconnect, device number 7 Dec 31 12:13:32 LaptopHostName kernel: done. Dec 31 12:13:32 LaptopHostName kernel: random: crng reseeded on system resumption Dec 31 12:13:32 LaptopHostName kernel: PM: suspend exit Dec 31 12:13:32 LaptopHostName audit: SERVICE_START pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=systemd-suspend comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success' Dec 31 12:13:32 LaptopHostName plasmashell: org.kde.pulseaudio: No object for name "alsa_output.usb-ACTIONS_Pebble_V3-00.analog-stereo" Dec 31 12:13:32 LaptopHostName audit: SERVICE_STOP pid=1 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:init_t:s0 msg='unit=systemd-suspend comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success' Dec 31 12:13:32 LaptopHostName bluetoothd: Controller resume with wake event 0x0 Dec 31 12:13:32 LaptopHostName kded6: org.kde.pulseaudio: No object for name "alsa_output.usb-ACTIONS_Pebble_V3-00.analog-stereo" Dec 31 12:13:32 LaptopHostName systemd-sleep: System returned from sleep operation 'suspend'. ░░ Subject: System sleep state suspend left ░░ Defined-By: systemd ░░ Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel ░░ ░░ The system has now left the suspend sleep state. Dec 31 12:13:32 LaptopHostName systemd: systemd-suspend.service: Deactivated successfully. I also came across a python script which helps identify sleep problems, and this is the result (I'm gonna cut to the main line as the log is full of emojis and I want to spare you that): > 2024-12-31 12:25:21,494 INFO: Suspend count: 1 > 2024-12-31 12:25:21,494 INFO: ○ GPIOs active: ['29', '29', '29', '29', '29', '29', '29'] > 2024-12-31 12:25:21,494 INFO: Wakeup triggered from IRQ 7: GPIO Controller > 2024-12-31 12:25:21,494 DEBUG: Used Microsoft uPEP GUID in LPS0 _DSM > 2024-12-31 12:25:21,494 INFO: Woke up from IRQ 7: GPIO Controller > 2024-12-31 12:25:21,495 DEBUG: ACPI Lid (/proc/acpi/button/lid/LID0/state): closed > 2024-12-31 12:25:21,495 ERROR: ❌ Userspace suspended for 0:00:04.616088 ( 2024-12-31 12:25:21,496 ERROR: ❌ Did not reach hardware sleep state So, I assume this has to do with the GPU, as unplugging the hdmi let's the laptop sleep, and it's triggered by IRQ 7. I have found that IRQ7 is pinctrl_amd, so I'm not sure it's the responsible part, as it's a general-purpose GPIO driver as far as I know. /sys/kernel/irq/7/wakeup is enabled but I'm not sure it would be a good idea to disable it, and I have not even been able to find where to disable it for a test. Some of the things I have tried: - disable wakeup for the gpu drivers (only one of the cards seems to have the wakeup file though) - disabled everything on /proc/acpi/wakeup - Disabled wake up capability from every device with powertop - Tried the kernel parameters amdgpu.runpm=1 (default is 0), amdgpu.dpm=1 (-1 default), amdgpu.bapm=1 (-1 default), acpi.ec_no_wakeup=1 (default 0)
altz3r0 (11 rep)
Jan 2, 2025, 05:56 PM • Last activity: Jan 2, 2025, 06:44 PM
0 votes
0 answers
30 views
Delayed systemd slock autolock
I've been playing with this autoslock.service file: ``` [Unit] Description=Lock the screen on suspend +Before=sleep.target [Service] User=garrett Environment=DISPLAY=:0 ExecStart=/usr/local/bin/slock [Install] WantedBy=sleep.target ``` It almost works. The problem is that there's a brief period when...
I've been playing with this autoslock.service file:
[Unit]
Description=Lock the screen on suspend
+Before=sleep.target

[Service]
User=garrett
Environment=DISPLAY=:0
ExecStart=/usr/local/bin/slock

[Install]
WantedBy=sleep.target
It almost works. The problem is that there's a brief period when the screen wakes up where it's contents are visible before slock is triggered. What do I need to do to fix it? I would think there'd be a way for slock to be invoked immediately prior to sleep instead of after waking up, but I haven't been able to crack it.
kmaximus (1 rep)
Jan 1, 2025, 10:25 PM
2 votes
1 answers
1016 views
systemd.timer to catch up on missed runs of the services
Following up on https://unix.stackexchange.com/questions/744160/schedule-a-job-every-20-days, > This is for renewing purpose, thus can be done sooner than 20 days. But I'm doing it from my laptop, which would be put into sleep most of the time. Thus guarantee execution is a must (which I read that c...
Following up on https://unix.stackexchange.com/questions/744160/schedule-a-job-every-20-days , > This is for renewing purpose, thus can be done sooner than 20 days. But I'm doing it from my laptop, which would be put into sleep most of the time. Thus guarantee execution is a must (which I read that cron is lack of). I chose systemd.timer over crom as I was under the impression that _"it would even work when the scheduled time passes by during my system went in sleeping mode, after it wakes up"_ However, it turns out to be not the case for me. Per its man page, the only close option is the Persistent= one: > Takes a boolean argument. If true, the time when the service unit was last triggered is stored on disk. When the timer is activated, the service unit is triggered immediately if it would have been triggered at least once during the time when the timer was inactive. Such triggering is nonetheless subject to the delay imposed by RandomizedDelaySec=. This is useful to catch up on missed runs of the service when the system was powered down. Note that this setting only has an effect on timers configured with OnCalendar=. However, I just realized that I am using OnUnitActiveSec=20d instead of the required OnCalendar=, so having Persistent=true will not be helping for my https://unix.stackexchange.com/questions/744160/schedule-a-job-every-20-days case, right? Is it possible for systemd.timer to catch up on missed runs of the services, scheduled with OnUnitActiveSec=, after the computer system has waken up from sleep? PS. All my systemd packages:
libpam-systemd:amd64_249.11-0ubuntu3.6
 libsystemd0:amd64_249.11-0ubuntu3.6
 python3-systemd_234-3ubuntu2
 systemd_249.11-0ubuntu3.6
 systemd-sysv_249.11-0ubuntu3.6
 systemd-timesyncd_249.11-0ubuntu3.6
xpt (1858 rep)
May 29, 2023, 09:50 PM • Last activity: Nov 26, 2024, 10:56 PM
1 votes
0 answers
49 views
Why does my KDE make such a mess when coming back?
I want to do a bunch of tasks before and after the screensaver is activated in KDE (*still* using X11, since Wayland has too many flaws even after 10 years). So I made a custom script that is triggered after 5 minutes of inactivity (KDE settings > Power Management > Other Settings). The problem: whe...
I want to do a bunch of tasks before and after the screensaver is activated in KDE (*still* using X11, since Wayland has too many flaws even after 10 years). So I made a custom script that is triggered after 5 minutes of inactivity (KDE settings > Power Management > Other Settings). The problem: when I come back and press a key, KDE takes around 8 seconds to show the desktop, and when it does, it is not quite ready, turns the screen off/on, moves things around, blinks, etc, during around 6 to 8 seconds more until it is finally back from the Dead. Probably that consumes more energy than keeping the screen on! This is my script: #!/bin/bash sleep 2 xset dpms force off If instead of the xset line I put the next line the problem persists: dbus-send --session --print-reply --dest=org.kde.kglobalaccel \ /component/org_kde_powerdevil org.kde.kglobalaccel.Component.invokeShortcut \ string:'Turn Off Screen' So: why is KDE making such a mess, and how can I prevent it? Or maybe there is a better way to do this? I would love to know your own way.
Luis A. Florit (509 rep)
Nov 10, 2024, 01:00 PM • Last activity: Nov 10, 2024, 08:47 PM
0 votes
0 answers
55 views
Fedora 40 freezes on my thinkpad t460 when chrome is being is used
So,basically the title. Although I am not 100% sure but it happens when: *I am using a browser ( happened both on firefox and chrome) and the system has been woken up from the sleep/suspend.* Earlier I had system freeze issue due to keyboard (hardware related) , so got it replaced. Please help. I do...
So,basically the title. Although I am not 100% sure but it happens when: *I am using a browser ( happened both on firefox and chrome) and the system has been woken up from the sleep/suspend.* Earlier I had system freeze issue due to keyboard (hardware related) , so got it replaced. Please help. I don't know if it is caused by chrome/firefox or suspend/sleep or some driver issue or some issue in fedora 40 itself.
chanzerre (101 rep)
Oct 10, 2024, 05:50 PM • Last activity: Oct 10, 2024, 06:06 PM
0 votes
0 answers
42 views
Fedora Workstation does not suspend on HP Envy x360 Laptop (2018)
I have an older, but not old, 2018 laptop as indicated in the question, which for the life of me I cannot get to suspend with any of: Fedora Workstation; Atomic Desktops Silverblue, Kinoite, Budgie; the Fedora KDE Desktop Spin; nor Ubuntu Desktop. It *does* suspend/resume flawlessly with Fedora Atom...
I have an older, but not old, 2018 laptop as indicated in the question, which for the life of me I cannot get to suspend with any of: Fedora Workstation; Atomic Desktops Silverblue, Kinoite, Budgie; the Fedora KDE Desktop Spin; nor Ubuntu Desktop. It *does* suspend/resume flawlessly with Fedora Atomic Sway Desktop, and Windows 10. All with the latest versions downloaded yesterday and today, including all updates, installing onto a newly partitioned drive. The visible symptom is that the display goes black, and the system appears to freeze; no disk activity; no change after several minutes of waiting; power light remains on; keyboard backlight remains on. The only recourse is to force power off and reboot. One thing I have noticed with all the failing Linux distros is that they output a message at the beginning of booting saying "call_irq_handler: 0.110 No IRQ handler for vector", though I can find no entry in any logs, neither dmesg or the Logs GUI app, that references that. I mention that only because the Sway Atomic Desktop did not. It may be a complete red herring. I am relatively new(ish) to Linux, but know how to fiddle-fuddle my way to resolving most issues with a combination of decades of experience on computers of all stripes and searching the internet. But this one has me foxed. Clearly the computer *can* reliably suspend/resume, but something about Linux does not want to sleep. The big obstacle is that I don't really know where to look for information on this level of problem with Linux. Any help would be very much appreciated! **System Info** dmidecode -t bios:
`
Getting SMBIOS data from sysfs.
SMBIOS 3.0.0 present.

Handle 0x0000, DMI type 0, 24 bytes
BIOS Information
	Vendor: AMI
	Version: F.24
	Release Date: 03/16/2022
	Address: 0xF0000
	Runtime Size: 64 kB
	ROM Size: 16 MB
	Characteristics:
		PCI is supported
		BIOS is upgradeable
		BIOS shadowing is allowed
		Boot from CD is supported
		Selectable boot is supported
		EDD is supported
		5.25"/1.2 MB floppy services are supported (int 13h)
		3.5"/720 kB floppy services are supported (int 13h)
		3.5"/2.88 MB floppy services are supported (int 13h)
		Print screen service is supported (int 5h)
		8042 keyboard services are supported (int 9h)
		Serial services are supported (int 14h)
		Printer services are supported (int 17h)
		ACPI is supported
		USB legacy is supported
		Smart battery is supported
		BIOS boot specification is supported
		Function key-initiated network boot is supported
		Targeted content distribution is supported
		UEFI is supported
	BIOS Revision: 15.24
	Firmware Revision: 63.18
` dmidecode -t system:
`
Getting SMBIOS data from sysfs.
SMBIOS 3.0.0 present.

Handle 0x0001, DMI type 1, 27 bytes
System Information
	Manufacturer: HP
	Product Name: HP ENVY x360 Convertible 15-bq1xx
	Version:  
	Serial Number: 8CG802052W
	UUID: 4409c9d8-f508-11e7-9a05-2c6fc94442fa
	Wake-up Type: Power Switch
	SKU Number: 1ZA02AV
	Family: 103C_5335KV HP Envy

Handle 0x000E, DMI type 32, 20 bytes
System Boot Information
	Status: No errors detected
` lscpu:
`
Architecture:             x86_64
  CPU op-mode(s):         32-bit, 64-bit
  Address sizes:          43 bits physical, 48 bits virtual
  Byte Order:             Little Endian
CPU(s):                   8
  On-line CPU(s) list:    0-7
Vendor ID:                AuthenticAMD
  BIOS Vendor ID:         Advanced Micro Devices, Inc.
  Model name:             AMD Ryzen 5 2500U with Radeon Vega Mobile Gfx
    BIOS Model name:      AMD Ryzen 5 2500U with Radeon Vega Mobile Gfx   Unknown CPU @ 2.0GHz
    BIOS CPU family:      107
    CPU family:           23
    Model:                17
    Thread(s) per core:   2
    Core(s) per socket:   4
    Socket(s):            1
    Stepping:             0
    Frequency boost:      enabled
    CPU(s) scaling MHz:   89%
    CPU max MHz:          2000.0000
    CPU min MHz:          1600.0000
    BogoMIPS:             3992.26
    Flags:                fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflus
                          h mmx fxsr sse sse2 ht syscall nx mmxext fxsr_opt pdpe1gb rdtscp lm constant_t
                          sc rep_good nopl nonstop_tsc cpuid extd_apicid aperfmperf rapl pni pclmulqdq m
                          onitor ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrand lah
                          f_lm cmp_legacy extapic cr8_legacy abm sse4a misalignsse 3dnowprefetch osvw sk
                          init wdt tce topoext perfctr_core perfctr_nb bpext perfctr_llc mwaitx cpb hw_p
                          state ssbd ibpb vmmcall fsgsbase bmi1 avx2 smep bmi2 rdseed adx smap clflushop
                          t sha_ni xsaveopt xsavec xgetbv1 clzero irperf xsaveerptr arat npt lbrv svm_lo
                          ck nrip_save tsc_scale vmcb_clean flushbyasid decodeassists pausefilter pfthre
                          shold avic v_vmsave_vmload vgif overflow_recov succor smca sev sev_es
Caches (sum of all):      
  L1d:                    128 KiB (4 instances)
  L1i:                    256 KiB (4 instances)
  L2:                     2 MiB (4 instances)
  L3:                     4 MiB (1 instance)
NUMA:                     
  NUMA node(s):           1
  NUMA node0 CPU(s):      0-7
Vulnerabilities:          
  Gather data sampling:   Not affected
  Itlb multihit:          Not affected
  L1tf:                   Not affected
  Mds:                    Not affected
  Meltdown:               Not affected
  Mmio stale data:        Not affected
  Reg file data sampling: Not affected
  Retbleed:               Mitigation; untrained return thunk; SMT vulnerable
  Spec rstack overflow:   Mitigation; Safe RET
  Spec store bypass:      Mitigation; Speculative Store Bypass disabled via prctl
  Spectre v1:             Mitigation; usercopy/swapgs barriers and __user pointer sanitization
  Spectre v2:             Mitigation; Retpolines; IBPB conditional; STIBP disabled; RSB filling; PBRSB-e
                          IBRS Not affected; BHI Not affected
  Srbds:                  Not affected
  Tsx async abort:        Not affected
` lsblk:
`
NAME                                          MAJ:MIN RM   SIZE RO TYPE  MOUNTPOINTS
sda                                             8:0    0 931.5G  0 disk  
└─sda1                                          8:1    0 931.5G  0 part  
  └─luks-de452dcc-6950-418d-96ea-dc98f511accc 253:2    0 931.5G  0 crypt /home
zram0                                         252:0    0     8G  0 disk  [SWAP]
nvme0n1                                       259:0    0 476.9G  0 disk  
├─nvme0n1p1                                   259:1    0   512M  0 part  /boot/efi
├─nvme0n1p2                                   259:2    0     1G  0 part  /boot
├─nvme0n1p3                                   259:3    0    32G  0 part  
│ └─luks-95e4413b-1083-46f3-8e80-fee9278cddef 253:1    0    32G  0 crypt [SWAP]
└─nvme0n1p4                                   259:4    0 443.4G  0 part  
  └─luks-358e1cf7-3186-49be-89cb-b18b7f353d0c 253:0    0 443.4G  0 crypt /
` lsusb:
`
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 0bda:58e6 Realtek Semiconductor Corp. HP Wide Vision FHD Camera
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 002: ID 05e3:0608 Genesys Logic, Inc. Hub
Bus 003 Device 003: ID 0483:91d1 STMicroelectronics Sensor Hub
Bus 003 Device 004: ID 0bda:b00b Realtek Semiconductor Corp. Realtek Bluetooth 4.2 Adapter
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
` lspci:
`
00:00.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Root Complex
00:00.2 IOMMU: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 IOMMU
00:01.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 00h-1fh) PCIe Dummy Host Bridge
00:01.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 PCIe GPP Bridge [6:0]
00:01.6 PCI bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 PCIe GPP Bridge [6:0]
00:01.7 PCI bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 PCIe GPP Bridge [6:0]
00:08.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 00h-1fh) PCIe Dummy Host Bridge
00:08.1 PCI bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Internal PCIe GPP Bridge 0 to Bus A
00:08.2 PCI bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Internal PCIe GPP Bridge 0 to Bus B
00:14.0 SMBus: Advanced Micro Devices, Inc. [AMD] FCH SMBus Controller (rev 61)
00:14.3 ISA bridge: Advanced Micro Devices, Inc. [AMD] FCH LPC Bridge (rev 51)
00:18.0 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 0
00:18.1 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 1
00:18.2 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 2
00:18.3 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 3
00:18.4 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 4
00:18.5 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 5
00:18.6 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 6
00:18.7 Host bridge: Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 7
01:00.0 Non-Volatile memory controller: Intel Corporation SSD 660P Series (rev 03)
02:00.0 Unassigned class [ff00]: Realtek Semiconductor Co., Ltd. RTS522A PCI Express Card Reader (rev 01)
03:00.0 Network controller: Realtek Semiconductor Co., Ltd. RTL8822BE 802.11a/b/g/n/ac WiFi adapter
04:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Raven Ridge [Radeon Vega Series / Radeon Vega Mobile Series] (rev c4)
04:00.1 Audio device: Advanced Micro Devices, Inc. [AMD/ATI] Raven/Raven2/Fenghuang HDMI/DP Audio Controller
04:00.2 Encryption controller: Advanced Micro Devices, Inc. [AMD] Family 17h (Models 10h-1fh) Platform Security Processor
04:00.3 USB controller: Advanced Micro Devices, Inc. [AMD] Raven USB 3.1
04:00.4 USB controller: Advanced Micro Devices, Inc. [AMD] Raven USB 3.1
04:00.6 Audio device: Advanced Micro Devices, Inc. [AMD] Family 17h/19h HD Audio Controller
05:00.0 SATA controller: Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode] (rev 51)
`
Cornelius Dol (143 rep)
Sep 24, 2024, 05:13 AM • Last activity: Sep 24, 2024, 05:54 AM
2 votes
1 answers
9561 views
How can I use Ubuntu 22.04 on a Samsung Galaxy Book 2 ( NP750XED )?
I installed Ubuntu 22.04 on my Samsung Galaxy Book 2 (NP750XED) by following [the official instructions][1] and it works perfectly until I turn the computer off. After boot, when reaching the login prompt, the system abruptly goes to sleep. I can wake up the system again, but it will quickly go to s...
I installed Ubuntu 22.04 on my Samsung Galaxy Book 2 (NP750XED) by following the official instructions and it works perfectly until I turn the computer off. After boot, when reaching the login prompt, the system abruptly goes to sleep. I can wake up the system again, but it will quickly go to sleep again, stuck in a perpetual loop.
Morten Emmanuel Schiøler (61 rep)
Dec 6, 2022, 10:44 AM • Last activity: Sep 21, 2024, 12:58 PM
2 votes
2 answers
2573 views
Verbose sleep command that displays pending time seconds/minutes?
sleep command can be used to introduce a delay. e.g. `sleep 5` will sleep for 5 seconds. Is there any alternative/way/method that will display the pending seconds on the terminal? output like resuming in 5 sec the numeric values just countdowns on the same line of terminal.
sleep command can be used to introduce a delay. e.g. sleep 5 will sleep for 5 seconds. Is there any alternative/way/method that will display the pending seconds on the terminal? output like resuming in 5 sec the numeric values just countdowns on the same line of terminal.
mtk (28468 rep)
Jul 29, 2020, 09:00 AM • Last activity: Jun 28, 2024, 06:23 AM
12 votes
5 answers
4331 views
shell sleep until next full minute
To execute a script on the next full minute I want to tell the ```sleep``` command to sleep until the next full minute. How can I do this?
To execute a script on the next full minute I want to tell the
command to sleep until the next full minute. How can I do this?
nnn (1281 rep)
Apr 6, 2015, 06:40 PM • Last activity: Jun 22, 2024, 02:59 PM
0 votes
1 answers
425 views
Suspending and Resuming Thinkpad X1 Carbon Gen 10 in Debian 12
S3 suspend used to work on this machine, but then I updated the firmware and now it doesn't. `systemctl suspend` makes the screen go black and print > Allocating and mlocking memory: 1050624 kb > Sleeping ... And that's it. It just hangs there. I updated the firmware to fix a different, but probably...
S3 suspend used to work on this machine, but then I updated the firmware and now it doesn't. systemctl suspend makes the screen go black and print > Allocating and mlocking memory: 1050624 kb > Sleeping ... And that's it. It just hangs there. I updated the firmware to fix a different, but probably worse bug where the system would not boot if a usb device was inserted. What I've done to try to fix it: - Reinstall firmware via gnome-firmware - Upgrade to kernel 6.7 (from bookworm-backports). - Use S0 sleep instead of S3 (which worked before). Help will be much appreciated! I travel a lot and sleep mode is very convenient! Update: I got it working. See answer below.
groceryheist (141 rep)
Jun 16, 2024, 06:37 AM • Last activity: Jun 17, 2024, 05:40 PM
0 votes
0 answers
152 views
Why do the lights of keyboard turn on after standby?
What causes the keyboard to stay turned on (or turn back on a few min later) after standby and how to make it turn off on Debian? There are a few lights on my USB keyboard and for a long time after putting the computer into standby the keyboard lights went out as well. But since a few months ago, th...
What causes the keyboard to stay turned on (or turn back on a few min later) after standby and how to make it turn off on Debian? There are a few lights on my USB keyboard and for a long time after putting the computer into standby the keyboard lights went out as well. But since a few months ago, they often stay turned on or turn back on at night. One of the few bright lights on the keyboard signifies whether the numpad is active. Apparently the lights on can be different from which lights were turned on before standby. The computer is running Debian12 with KDE (this already appeared with Debian11). I don't know if this means that some components of the set-up are still running (such as the whole keyboard...and maybe the mainboard which then could theoretically send/exfiltrate data from RAM but that's another topic). **What could cause the keyboard to not shut off anymore when the computer is in standby and how to prevent this from occurring?** Any logs to check for what, is there anything I could test, or is there already a known cause and/or solution for this problem? ---- Details / full procedure: 1. Two keyboard lights are on: Function key and Numpad active 2. Putting the PC to sleep via Suspend of KDE's Power Management 3. Keyboard lights are all off for a few minutes (I'll test this further) 4. One keyboard light turns back on: Function key and if the room is dark it brightens it up (it also happened both two lights are on but I'll have to test this) 5. (Light(s) stays on for long: I'm not sure if it always stays on for many hours but last time it did stay on until I resumed the PC from sleep many hours afterwards) 6. Resume PC from sleep by pressing power button: the same two keyboard lights are turned on as before sleep Here is a similar question but unlike that user I don't have any sleep or hibernation related setting in my UEFI bios settings (nor a setting for secure boot which I think should be there) and the problem only started to occur since recently. I'll test if this also occurs when the keyboard is connected to another computer with nearly the same setup.
mYnDstrEAm (4708 rep)
Apr 6, 2024, 10:17 PM • Last activity: Jun 14, 2024, 04:49 PM
0 votes
2 answers
108 views
How in convenient and flexible way to input time period for timer and convert it to seconds in Bash?
Like in sleep: `sleep 1h 30m 50s`. But ideally with even more flexibility like in time calculator with support time corrections with minus sign. Examples: - `time2seconds (t2s) 1h30m50s # basic case - result should be: 5450 seconds` - `t2s 1h30m-30s # with correction by minus sign - result should be...
Like in sleep: sleep 1h 30m 50s. But ideally with even more flexibility like in time calculator with support time corrections with minus sign. Examples: - time2seconds (t2s) 1h30m50s # basic case - result should be: 5450 seconds - t2s 1h30m-30s # with correction by minus sign - result should be: 5370 seconds - t2s 1h-5s # result should be 3595 seconds - t2s 15m*3 # it might also be convenient to use multiplication sign - result should be: 2700 seconds Below is my own script with draft solution but it needs to be rewritten to have more performance respect (as [described](https://unix.stackexchange.com/a/776727/585416) by [markp-fuso](https://unix.stackexchange.com/users/234539/markp-fuso) now it creates huge amount of subshells) --- Implementation below in time2seconds function. Usages examples:
time2seconds 1h30m50s debug  # 5450
t2s 1h30m-30s d  # 5370
t2s 1h-5s d  # 3595
t2s 15m*3 d  # 2700
log(){
    msg_content="$1"
    print_to_console=${2:-"print_to_console"}

    msg="date +"%Y-%m-%dT%H:%M:%S" - $msg_content"

    if [ $print_to_console = "print_to_console" ]; then
        echo -e "$msg"
    fi
}

FUNCTION_RESULT=  # global var, used for functions to return values

alias t2s="time2seconds"

# Calculates for entered time amount of seconds
# Supported formats:
# 1d1h1m1s
# hh:mm:ss (for "backwards compatibility", for those who got used to this format)
# Any parts can be omitted. Examples of valid input:
# 1h, 1h30m, 1d5s, 30m, 100h, 200m, 300s, 59 (seconds), 1m30 (1m30s), 1h1h1h (3h)
# 102:30:59, 2:3:59, 3:59, 100:200:300, 500 (seconds)
# For 1d1h1m1s format supports correction of input by means of calculations like:
# 1h-1m (result is 59m), 1d-1h30m (result is 22h30m), 15m*3 (result is 45m)
# To debug time to seconds conversion algorithm (print detailed output to console):
# time2seconds 1d-1h30m+5 debug  # test run
# t2s 1d10h30s-1h1m d  # alternative test run with aliases
function time2seconds() {

    start_time=$(date +%s%3N)

    time="${1}"
    out="${2:-"do_not_print_to_console"}"

    if [ "$out" = "debug" ] || [ "$out" = "d" ] || [ "$out" = "print" ]; then
        out="print_to_console"
    fi

    case "$time" in
        *d*|*h*|*m*|*s*)
            log "handling several cases for d, h, m, s tokens" $out
            time=$(echo "$time" | sed -E 's/([[:digit:]]+)([^[:alnum:]])/\1s\2/g')
            log "time1, added missing s tokens: $time" $out

            time=$(echo "$time" | sed -E 's/([[:digit:]]+)$/\1s/')
            log "time2, added missing s token to the very end: $time" $out

            time=$(echo "$time" | sed -E 's/([[:alnum:]]+)/\(\1\)/g')
            log "time3, added round braces (): $time" $out

            time=$(echo "$time" | sed -E 's/([[:digit:]]+)d/+\1*24*3600;/g')
            log "time4, days to seconds: $time" $out

            time=$(echo "$time" | sed -E 's/([[:digit:]]+)h/+\1*3600;/g')
            log "time5, hours to seconds: $time" $out

            time=$(echo "$time" | sed -E 's/([[:digit:]]+)m/+\1*60;/g')
            log "time6, mins to seconds: $time" $out

            time=$(echo "$time" | sed -E 's/([[:digit:]]+)s/+\1;/g')
            log "time7, seconds to seconds: $time" $out

            time=$(echo "$time" | sed -E 's/;//g')
            log "time8, semicolon ; delimeter removed: $time" $out

            time=$(echo "$time" | sed -E 's/\(\+/(/g')
            log "time9, leading plus signs removed: $time" $out

            calculated_seconds=$(echo "$time" | bc)
            ;;
        *)
            log "handling case with colon (:)" $out
            calculated_seconds=$(echo "$time" | sed -E 's/(.*):(.+):(.+)/\1*3600+\2*60+\3/;s/(.+):(.+)/\1*60+\2/' | bc)
            ;;
        *)
    esac
    
    log "calculated_seconds by bc: $calculated_seconds" $out

    end_time=$(date +%s%3N)
    duration_ms=$((end_time - start_time))

    log "time2seconds execution time in ms: $duration_ms" $out
    
    FUNCTION_RESULT="$calculated_seconds"  # global var is used to return result from function
}
--- Related questions: - [linux - Is there a way to display a countdown or stopwatch timer in a terminal?](https://superuser.com/a/872285/238462) - [shell script - How to modify these bash functions into one?](https://unix.stackexchange.com/a/509724/585416) - [How to make bc handle explicitly positive numbers?](https://unix.stackexchange.com/q/776280/585416)
Anton Samokat (289 rep)
May 18, 2024, 01:15 PM • Last activity: Jun 4, 2024, 03:51 PM
29 votes
11 answers
32401 views
Shell: is it possible to delay a command without using `sleep`?
Are there any substitutes, alternatives or bash tricks for delaying commands without using `sleep`? For example, performing the below command without actually using sleep: $ sleep 10 && echo "This is a test"
Are there any substitutes, alternatives or bash tricks for delaying commands without using sleep? For example, performing the below command without actually using sleep: $ sleep 10 && echo "This is a test"
user321697 (319 rep)
Nov 19, 2018, 10:52 AM • Last activity: May 10, 2024, 02:11 PM
0 votes
1 answers
134 views
start command at given time interactively in terminal
is there similar command to `sleep`, but where I can specify given time, so that my command will start at given time, **INTERACTIVELY** in my current open terminal window? I know about `at` command, but that would not work as it does not run interactively in my current open terminal window. I need t...
is there similar command to sleep, but where I can specify given time, so that my command will start at given time, **INTERACTIVELY** in my current open terminal window? I know about at command, but that would not work as it does not run interactively in my current open terminal window. I need to start my command at 04:00 in my terminal, as if I woke up, typed my command, and pressed enter. The closest solution I can think of, is to calculate before I go to bed, how many seconds remain until 04:00, and use sleep command. But that is so ugly. There must be a better way to do this.
Martin Vegter (586 rep)
Apr 27, 2024, 05:49 AM • Last activity: Apr 27, 2024, 10:18 AM
Showing page 1 of 20 total questions