Jump to content

Arch Linux Suspend Device Problem

DarkEnergy
Go to solution Solved by RONOTHAN##,
27 minutes ago, DarkEnergy said:

My current working solution that is temporary is to run "echo UHC1 > /proc/acpi/wakeup" but that resets on restart.

I mean, there's probably a better solution than this, but if that temp fix works, why don't you just make a cronjob that does that for you?

 

Create a .sh file somewhere (preferably in your home directory, but if it needs to be run as sudo then place it somewhere else). Make the contents of that file

#!/bin/bash

echo UHC1 > /proc/acpi/wakeup

 

Make the file executable using this command.

chmod +x filename.sh # replace "filename.sh" with the correct path to the file. You might also have to run this as sudo to get it to work, it's been a while since I've made a script

 

Run the following command

crontab -e # run as sudo if the script needs to be run as root

 

Add the following line to the crontab

@reboot /path/to/filename.sh

Save the file. If it opened in Vi/Vim, edit by pressing "i", then to exit and save, press escape and type ":wq". If it opened in Nano, follow the prompts for how to save and exit.

I'm fairly new to linux in general and I've never been able to get very far with it because every time I test it out, some core functionality ends up not working and I can't find a solution.

I'm running EndeavourOS (arch) "Linux Endeavour 5.15.4-arch1-1" and everything is up to date.

 

Currently every time I suspend the computer, the computer wakes back up instantly but the monitor doesn't receive the signal to turn on. This leads me having to force shutdown every time my computer goes to sleep. On first boot, it usually goes to sleep all right but the second time I put it to sleep it has these issues.

I've attached a screenshot of the output from "journalctl -b -1 -p err."

From what I can tell, it looks like pci device "0000:00:12.0" is causing this suspend issue. I've identified which device it is (UHC1) and from this tutorial I created a service file in "/etc/systemd/system" replacing the "XHC" with my device "UHC1" in order for the fix to be permanent every time I boot the pc. Unfortunately it looks like it's not working because when I view devices that can wake up the computer

"grep enabled cat /proc/acpi/wakeup" UHC1 is still listed there.

 

 

This is the output of systemctl status for the service file I created:

 

○ sspnd_dv_fix.service - Disables wake-up from device UHC
     Loaded: loaded (/etc/systemd/system/sspnd_dv_fix.service; enabled; vendor preset: disabled)
     Active: inactive (dead)
 

Any ideas to get this working? My current working solution that is temporary is to run "echo UHC1 > /proc/acpi/wakeup" but that resets on restart.

 

screenshot.png

 

CPU - FX 8350 @ 4.5GHZ GPU - Radeon 5700  Mobo - M5A99FX Pro R2.0 RAM - Crucial Ballistix 16GB @ 1600 PSU - Corsair CX600M CPU Cooler - Hyper 212 EVO Storage - Samsung EVO 250GB, WD Blue 1TB

Link to comment
Share on other sites

Link to post
Share on other sites

27 minutes ago, DarkEnergy said:

My current working solution that is temporary is to run "echo UHC1 > /proc/acpi/wakeup" but that resets on restart.

I mean, there's probably a better solution than this, but if that temp fix works, why don't you just make a cronjob that does that for you?

 

Create a .sh file somewhere (preferably in your home directory, but if it needs to be run as sudo then place it somewhere else). Make the contents of that file

#!/bin/bash

echo UHC1 > /proc/acpi/wakeup

 

Make the file executable using this command.

chmod +x filename.sh # replace "filename.sh" with the correct path to the file. You might also have to run this as sudo to get it to work, it's been a while since I've made a script

 

Run the following command

crontab -e # run as sudo if the script needs to be run as root

 

Add the following line to the crontab

@reboot /path/to/filename.sh

Save the file. If it opened in Vi/Vim, edit by pressing "i", then to exit and save, press escape and type ":wq". If it opened in Nano, follow the prompts for how to save and exit.

Link to comment
Share on other sites

Link to post
Share on other sites

29 minutes ago, RONOTHAN## said:

I mean, there's probably a better solution than this, but if that temp fix works, why don't you just make a cronjob that does that for you?

 

Create a .sh file somewhere (preferably in your home directory, but if it needs to be run as sudo then place it somewhere else). Make the contents of that file

#!/bin/bash

echo UHC1 > /proc/acpi/wakeup

 

Make the file executable using this command.

chmod +x filename.sh # replace "filename.sh" with the correct path to the file. You might also have to run this as sudo to get it to work, it's been a while since I've made a script

 

Run the following command

crontab -e # run as sudo if the script needs to be run as root

 

Add the following line to the crontab

@reboot /path/to/filename.sh

Save the file. If it opened in Vi/Vim, edit by pressing "i", then to exit and save, press escape and type ":wq". If it opened in Nano, follow the prompts for how to save and exit.

 

I tried that but UHC1 is still listed as enabled after reboot. I noticed Arch doesn't use Cron by default so I had to install Cron first. I created the script and put it in /etc for now.

After reading a little about Cron, I enabled the service "sudo systemctl enable cronie.service".

After reboot I did confirm that cronie.service is running. However I also noticed this:

 

"Nov 24 17:57:56 Endeavour CROND[577]: (myusername) CMDOUT (/etc/suspendfix.sh: line 3: /proc/acpi/wakeup: Permission denied)".

 

Is this because I put it in the /etc folder?

 

Permissions for that file are:

rwxr-xr-x 1 root root 43 Nov 24 17:48 /etc/suspendfix.sh

 

 

 

CPU - FX 8350 @ 4.5GHZ GPU - Radeon 5700  Mobo - M5A99FX Pro R2.0 RAM - Crucial Ballistix 16GB @ 1600 PSU - Corsair CX600M CPU Cooler - Hyper 212 EVO Storage - Samsung EVO 250GB, WD Blue 1TB

Link to comment
Share on other sites

Link to post
Share on other sites

Looks live I've fixed the problem with permissions. TBH I don't know what the solution was because I forgot to check if UHC1 was running or not between each fix. I think the solution involved changing owner of "/usr/bin/crontab" and "/etc/suspendfix.sh" to my username. I also set chmod for the "/etc/suspendfix.sh" file to 775. So far so good, I've rebooted and UHC1 is now gone.

 

CPU - FX 8350 @ 4.5GHZ GPU - Radeon 5700  Mobo - M5A99FX Pro R2.0 RAM - Crucial Ballistix 16GB @ 1600 PSU - Corsair CX600M CPU Cooler - Hyper 212 EVO Storage - Samsung EVO 250GB, WD Blue 1TB

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×