Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

(SOLVED) Odd sleep/ACPI behaviour

If none of the specific sub-forums seem right for your thread, ask here.
Message
Author
Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

(SOLVED) Odd sleep/ACPI behaviour

#1 Post by Mr. Lumbergh »

I'm having an issue on Buster with KDE where following updates a couple of days ago, sleeping instead of fully shutting down results in USB 3 and HDMI audio failing upon restart. The mobo in this box has 1 USB-C and 4 USB 3 ports, and I have a camera card reader mounted in a 2.5" drive bay that has a USB 2 port. Upon restarting I can't log in or use the mouse plugged into the 3 ports; they're completely dead. The mouse has a few LED's to indicate settings that won't even light when it's doing this. I have to pull the keyboard dongle out of the 3 port on the back of the box and insert into the reader port on the front in order to log in, and after restarting there's still no power to any of the 3 ports. The C port comes back to life though.
A similar thing is happening with HDMI audio, if I start up from sleep mode it no longer recognizes the video card (Radeon RX580) as a sound device unless I walk over to the TV and unplug/replug the HDMI cable back in; this is again only happening in the last few days after recent updates. I frequently stream over to my TV so I know it works otherwise. System is Buster/KDE fully updated with an Asus X570 board.
If anyone can offer some advice on how to start tracking this down it would be appreciated.
EDIT: I may have gotten the HDMI audio issue figured out, if I change the volume on my TV it'll often bring the audio back even if the TV wasn't muted. I'm still having the issue with USB3 not restarting along with the rest of the system though so would still welcome some pointers on how to resolve.


Thanks
Last edited by Mr. Lumbergh on 2020-07-29 19:02, edited 1 time in total.

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#2 Post by Mr. Lumbergh »

Nobody has any ideas what might be causing this?

User avatar
sickpig
Posts: 589
Joined: 2019-01-23 10:34

Re: Odd sleep/ACPI behaviour

#3 Post by sickpig »

Code: Select all

jourcalctl -S hh:mm:ss
the time would be since you last woke system
the log should list errors for further insight

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Odd sleep/ACPI behaviour

#4 Post by Deb-fan »

Wasn't happening until upgrades, upgrades of what, from where? Do you have any non-standard software repositories or things like PPA's in your os's sources.list file? Could check things like /var/log/dpkg.log(s) for what was upgraded, installed, removed. Think that's supposed to cover it regardless of which pkg management tool is used, apt, aptitude or synaptic but all of them also have logs in that location too. At least apt/itude do and synaptic does log also. May not be so helpful now but if not already doing so, using a proven incremental backup/restore method is good juju and bunch of good ways in gnu/Linux, I like rsync. :)
Most powerful FREE tech-support tool on the planet * HERE. *

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#5 Post by Mr. Lumbergh »

Deb-fan wrote:Wasn't happening until upgrades, upgrades of what, from where? Do you have any non-standard software repositories or things like PPA's in your os's sources.list file? Could check things like /var/log/dpkg.log(s) for what was upgraded, installed, removed. Think that's supposed to cover it regardless of which pkg management tool is used, apt, aptitude or synaptic but all of them also have logs in that location too. At least apt/itude do and synaptic does log also. May not be so helpful now but if not already doing so, using a proven incremental backup/restore method is good juju and bunch of good ways in gnu/Linux, I like rsync. :)
Here's the set of dpkg logs from around the time it first started:
https://pastebin.com/CQzzNhFC
I have a couple of additional repos added, my VPN client and some music production packages, but nothing that I could see controlling USB3 state that didn't come from the official repos.

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#6 Post by Mr. Lumbergh »

sickpig wrote:

Code: Select all

jourcalctl -S hh:mm:ss
the time would be since you last woke system
the log should list errors for further insight
I've left my system up for the last three or four days instead of sleeping to try to get around this issue, so I don't have any logs pointing to this directly; I'll give it a try tonight.

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Odd sleep/ACPI behaviour

#7 Post by Deb-fan »

Majority of people(self included)are highly unlikely to click over or download anything to scroll through logs for somebody. You no doubt know this already. Would say clean them- the logs up and post them here or any other help threads you may start. Was also just pointing out the obvious connection between upgrades you did and resolving these issues. Also post your sources.list when seeking help like this and someone asks about it. I've got a couple things, this and that added to repositories isn't helpful and doesn't encourage anyone to try. From what you said, agree doesn't sound like a likely suspect involved is the issues you're having but others might see something or know something we don't there.
Most powerful FREE tech-support tool on the planet * HERE. *

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Odd sleep/ACPI behaviour

#8 Post by Deb-fan »

Curiosity got the better of me and yep, as expected you'd apparently upgraded the kernel. Done correctly I strongly encourage people to try different kernels and/or custom compile some. It's really interesting and cool stuff. Plus overall a no harm or foul proposition. Though whenever screwing around with the kernel or other core pkgs a higher level of care should be taken. Depending upon what someone is doing and why, upgrading the nix kernel and others is not something which should be done for the sake of a higher version number.

Only sayin.

Hey guys, I just upgraded my kernel (for no valid reason)and/other critical stuff and am getting all manner of power management weirdnesses and Os performance quirks! What oh ever could be my problem ya's thinks?! Errrr no kidding? No idea that something like that could happen, head scratcher, TotAlLy dude! :P

Also this is coming off more aholish than truly intended. Not meant as such but still stupid PSA type of thing. :) No insult intended OP only saying sometimes the everything's running smoothly or isn't broken don't fix thing is valid. Done right folks can play with the kernel or everything else to heart content, safely and w/o even the slightest chance of harm. Again common sense precautions we should all be doing anyway. Whenever you see a proposed upgrade of a kernel on an Os you use for stuff you care about, that should be a BIG reminder prompting a person to say, hmm when's the last time I did-made a backup? Before proceeding.
Most powerful FREE tech-support tool on the planet * HERE. *

pendrachken
Posts: 1394
Joined: 2007-03-04 21:10
Location: U.S.A. - WI.

Re: Odd sleep/ACPI behaviour

#9 Post by pendrachken »

Just glancing through the upgrade logs I see two possibilities - the kernel was upgraded, and Xen was also upgraded.

Hopefully you didn't delete your old, working, kernel ( always keep a know working spare kernel - ALWAYS). Fist thing first - reboot the machine, and choose the older known working kernel from the GRUB menu. If that kernel works you know there was a kernel regression. File a bug report with Debian against the kernel package in backports. Let them figure it out if it is security patches they applied that caused the regression, or if there is a bug in the kernel code. They can then file any bugs against the kernel code if needed.

It's also remotely possible that xen is grabbing the USB connection when waking from sleep for some reason. Personally, I think a kernel regression is way more likely, but this is also a possibility.

Hey guys, I just upgraded my kernel (for no valid reason)and/other critical stuff and am getting all manner of power management weirdnesses and Os performance quirks! What oh ever could be my problem ya's thinks?! Errrr no kidding? No idea that something like that could happen, head scratcher, TotAlLy dude! :P
Yeah totally! I mean it's not like the new kernel image came in with a standard system upgrade from the official backports repository, and newer kernels are needed from backports for more recent hardware.... oh wait.
fortune -o
Your love life will be... interesting.
:twisted: How did it know?

The U.S. uses the metric system too, we have tenths, hundredths and thousandths of inches :-P

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#10 Post by Mr. Lumbergh »

pendrachken wrote:Just glancing through the upgrade logs I see two possibilities - the kernel was upgraded, and Xen was also upgraded.

Hopefully you didn't delete your old, working, kernel ( always keep a know working spare kernel - ALWAYS). Fist thing first - reboot the machine, and choose the older known working kernel from the GRUB menu. If that kernel works you know there was a kernel regression. File a bug report with Debian against the kernel package in backports. Let them figure it out if it is security patches they applied that caused the regression, or if there is a bug in the kernel code. They can then file any bugs against the kernel code if needed.

It's also remotely possible that xen is grabbing the USB connection when waking from sleep for some reason. Personally, I think a kernel regression is way more likely, but this is also a possibility.
The kernel is looking more like the culprit; I started it up this morning with the 5.4 that's still installed. The keyboard shortcut not only put it to sleep but also woke it back up without trouble.
Now to file the bug report...
Thank you for helping me out on this one.
pendrachken wrote:
Hey guys, I just upgraded my kernel (for no valid reason)and/other critical stuff and am getting all manner of power management weirdnesses and Os performance quirks! What oh ever could be my problem ya's thinks?! Errrr no kidding? No idea that something like that could happen, head scratcher, TotAlLy dude! :P
Yeah totally! I mean it's not like the new kernel image came in with a standard system upgrade from the official backports repository, and newer kernels are needed from backports for more recent hardware.... oh wait.
Right? Silly me wanting security updates and current features. :roll:

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Odd sleep/ACPI behaviour

#11 Post by Head_on_a_Stick »

Mr. Lumbergh wrote:Silly me wanting security updates and current features
The stable kernel is an LTS branch and so receives security fixes and the new features added to the non-LTS kernels always carry the risk of introducing new bugs and vulnerabilities.
deadbang

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#12 Post by Mr. Lumbergh »

Head_on_a_Stick wrote:
Mr. Lumbergh wrote:Silly me wanting security updates and current features
The stable kernel is an LTS branch and so receives security fixes and the new features added to the non-LTS kernels always carry the risk of introducing new bugs and vulnerabilities.
I use this rig as a music production platform though so I need the realtime kernel; the latency is noticeably better with my MIDI controller.

User avatar
Head_on_a_Stick
Posts: 14114
Joined: 2014-06-01 17:46
Location: London, England
Has thanked: 81 times
Been thanked: 132 times

Re: Odd sleep/ACPI behaviour

#13 Post by Head_on_a_Stick »

Mr. Lumbergh wrote:I need the realtime kernel
https://packages.debian.org/buster/linux-image-rt-amd64
deadbang

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Odd sleep/ACPI behaviour

#14 Post by Deb-fan »

Ignorantly upgrading and fiddling with things like an Os's kernel, very often isn't going to provide you with security and other enhancements or benefits. Absent putting in the effort or working up the knowledge to understand and handle what's involved competently, clearly can cause problems, as in your situation here. Though any risks involved can be easily mitigated to the point of making them non-issues ie: keeping backups etc.
Most powerful FREE tech-support tool on the planet * HERE. *

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#15 Post by Mr. Lumbergh »

Deb-fan wrote:Ignorantly upgrading and fiddling with things like an Os's kernel, very often isn't going to provide you with security and other enhancements or benefits. Absent putting in the effort or working up the knowledge to understand and handle what's involved competently, clearly can cause problems, as in your situation here. Though any risks involved can be easily mitigated to the point of making them non-issues ie: keeping backups etc.
Hmm. I'm not sure how it's "ignorant" to use the latest packages from the stable repos, but I do always keep a known-good kernel available as a fallback; currently I'm on the 5.4RT and it's behaving as expected. These days I only keep one or two fallbacks that I'm satisfied with as I recently had to remove a couple mainline kernels that were filling up the boot partition and preventing updates.
In any event, this does look like a regression and I've filed a bug report.

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Odd sleep/ACPI behaviour

#16 Post by Deb-fan »

Not even going to try outlining all the many ways it's ignorant, too damn many. Using release candidate kernels, gazillion other things. The kernel is not just another pkg, not the same as others on a gnu/nix Os, shouldn't be handled as if it is. Really no biggie, as it's harmless overall and noted above actually totally encourage people to try different kernels and/or tweak the things. When discussing something like getting best audio, real-time and etc, there are kernel configs(oops, edit: and/or patches) which could make a world of difference, are distro's for audiophiles around, could be a good resource for someone with a big interest in the subject.

No worries, not meaning to argue or insult here. Ignorance means not knowing, when it comes to gnu/nix and the kernel also I'll remain extremely ignorant to a huge degree for life. Imo there's simply too much involved for anyone not to stay ignorant to some (great) extent. :)
Last edited by Deb-fan on 2020-07-29 03:53, edited 1 time in total.
Most powerful FREE tech-support tool on the planet * HERE. *

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#17 Post by Mr. Lumbergh »

Deb-fan wrote:When discussing something like getting best audio, real-time and etc, there are kernel configs which could make a world of difference, are distro's for audiophiles around, could be a good resource for someone with a big interest in the subject.
That's exactly what I'm after. I gravitated to the RT kernel because with it I can't hear a delay between a keypress on my MIDI controller and when the sound is generated in the DAW, but I could on the mainline. Going from the 4.19RT to the 5.4RT played even nicer with my particular setup, so I didn't have reason to think that the 5.6 would be a regression, I s'pose. I also came to Debian from a rolling-release distro so it became habitual for me to install the latest, at least after giving it a week or so. Live and learn. If no other good comes from it I filed a bug report on the 5.6RT so hopefully it gets fixed.
I'll probably just stick with the 5.4 for the time being; it and 4.19 will both be getting 6 years of LTS: https://fossbytes.com/linux-lts-kernel- ... tead-of-2/, so that's cool.
I know there are a couple of distros out there with the kind of stuff that I like to do in mind such as KXStudio and Ubuntu Studio, and I actually do get some things from KX but I won't use Ubuntu Studio, because Ubuntu. I figured on this box I'd start with a barebones Debian and add some of those same tweaks myself that make it better for music work because Debian is so tweakable and there are so many packages available for it. Work in progress but it's been fun. Anywho, I've noticed I'm rambling a bit.
Deb-fan wrote: No worries, not meaning to argue or insult here. Ignorance means not knowing, when it comes to gnu/nix and the kernel also I'll remain extremely ignorant to a huge degree for life. Imo there's simply too much involved for anyone not to stay ignorant to some (great) extent. :)
OK, no worries and pardon the way I interpreted it.

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Odd sleep/ACPI behaviour

#18 Post by Deb-fan »

Totally understandable, lately been mega-dosing caffeine, guzzling coffee and staying awake long periods, 36-48hrs at a time, sleep 10-12hrs, rinse/repeat, get to the point where I become a highly impatient/irritable azzhat. Not that the crazy sleep schedule I've been doing is much of an excuse to justify being an ahole(isn't). Sounds like you're making some good progress and a real effort to study gnu/nix for what you're interested in. Which of course is really cool. Haven't devoted a huge amount of effort in studying audio or gaming or etc on gnu/nix yet. Only bits n pieces.

The kernel someone is using surely has to be a big factor there. Though kernel has to be a huge consideration while discussing anything nix. It's the friggin Linux kernel after all. The Linux part of errr gnu/Linux. :)
Most powerful FREE tech-support tool on the planet * HERE. *

Mr. Lumbergh
Posts: 102
Joined: 2019-08-02 04:28

Re: Odd sleep/ACPI behaviour

#19 Post by Mr. Lumbergh »

Deb-fan wrote:Totally understandable, lately been mega-dosing caffeine, guzzling coffee and staying awake long periods, 36-48hrs at a time, sleep 10-12hrs, rinse/repeat, get to the point where I become a highly impatient/irritable azzhat. Not that the crazy sleep schedule I've been doing is much of an excuse to justify being an ahole(isn't). Sounds like you're making some good progress and a real effort to study gnu/nix for what you're interested in. Which of course is really cool. Haven't devoted a huge amount of effort in studying audio or gaming or etc on gnu/nix yet. Only bits n pieces.

The kernel someone is using surely has to be a big factor there. Though kernel has to be a huge consideration while discussing anything nix. It's the friggin Linux kernel after all. The Linux part of errr gnu/Linux. :)
It isn't you, just the way things don't come across as intended online sometimes. Really no worries now that we've had a real convo about it. But get some sleep man!
I'm still drilling down to find what tweaks I can do that will make this a better music platform, but so far the RT kernel and some massaging of JACK Audio have had the biggest impact. This Debian install has become not only my main music production rig but has become my everyday driver over that other distro I mentioned. I occasionally have to restart my DAW, but I don't think it's Debian that's the issue so much have having to use WINE when there isn't a native Linux plugin for virtual instruments.

Deb-fan
Posts: 1047
Joined: 2012-08-14 12:27
Been thanked: 4 times

Re: Odd sleep/ACPI behaviour

#20 Post by Deb-fan »

Can be and sometimes am a butthole. Whenever a person calls another person ignorant, they can rest assured it's going to be somewhat offensive and taken that way, sorry. One thing about spending too much time in gnu/Linux forums a person gets burnt out and it's easy to start considering people simply too lazy and/or stupid to competently admin their systems or show the common sense, in taking steps to learn for themselves. That isn't aimed at you, only when I'm already in that azzhat state of mind, have a tendency to act like a jerk even in cases where it's unwarranted. Some posts in thread for example. :)

Have studied things which parallel what would (or some things which could) be involved in getting best audio recording, sound quality etc in gnu/Linux. Might try looking into a Windows install on a real hypervisor ie: Kvm vs use of an emulator like WINE. I've looked it over but could never bring myself to install it. The idea of mixing a bunch of windows software into a gnu/Linux OS, has always somewhat disgusted me on some level. So I've read but could never commit to actually using it/WINE. Might give you some joy(a Windows guest os installed on a virtual machine) on software not natively supported on Nix and may even impart some degree of better performance of such software vs what can be done with WINE. That's pure speculation on my part though, I honestly don't know for sure.

Another poss place to look is what your system is using as the power governor. On new Intel (they have this pstate thing) on older Intel and on AMD generally default to the ondemand governor. One of the kernel config's jacked up on RT kernels and many desktop "performance" kernels is the timer interrupt freq, how often the kernel checks for tasks it should be doing, on RT and performance kerns often you'll find it set at 1000hz vs 250hz that many-most distro's kernels come with. Reason I bring up power governor selected on an OS, it plays a big role in how high, how quickly your cpu(s) step up their clock speeds. This can have an impact on how live time apps etc perform. If the clock speeds are capped too low(by power governor), even though the kernel is RT and has preemption and timer interrupt set to 1000hz, such a setup could still clash and come up lacking in performance potential. You've likely already covered this to whatever extent too, if not am just noting it. Are you already using the performance governor ? I like the ondemand governor but have tweaked it from what's generally found set default.

On my Os's it's set to step up the cpu-cores clock speeds(cycles)more quickly and keep it raised a bit longer whenever the cores get put under load. Most the time, if not needed I want my cores to stay running at the lowest clock speeds. Conserves power, reduces heat and other wear n tear on the proc's. Anyway don't doubt getting best audio out of gnu/Linux is a fairly wide subject itself, so am going to shut it as I've never focused on it and don't doubt there's a TON of good resources available with which people could learn much on the subject. You can find which config options are set/used in whichever of your kernels looking at their files kept in /boot ie: config-4.19 etc in that location.


Lol ... thanks, will have to sleep eventually, earliest est crash-time, approx 10-11pm tonight. My kernel(brain) is still running pretty smoothy at this point. Once my uptime hits around the 20hrs mark, errrrr, not so much. :)
Most powerful FREE tech-support tool on the planet * HERE. *

Post Reply