You are not logged in.
i was do
sudo nano /etc/systemd/system/disable-usb-wakeup.service
and put your script
[Unit]
Description=Disable USB controllers in /proc/acpi/wakeup
[Service]
Type=oneshot
ExecStart=bash -c '\
while read -r device _ status _; do \
[[ $device == +([EX]HC*|USB*|PS2*) && $status == "*enabled" ]] && \
echo $device > /proc/acpi/wakeup; \
done < /proc/acpi/wakeup; \
true \
'
[Install]
WantedBy=multi-user.target
then i save it and do
sudo systemctl start disable-usb-wakeup.service
and get error from above
Offline
What is the actual text of the service file you are trying to use? If you can not cut and paste it see the tip box from https://wiki.archlinux.org/index.php/Li … in_clients.
The screenshots looks suspiciously newline-loaded…
Upload the exact actual resulting file. Copy and paste, especially w/ terminal editors - and more especially with some of them - can be a less than reliable process…
Online
you mean like this output
[samson@archPC system]$ ls -l
total 28
lrwxrwxrwx 1 root root 57 Sep 15 17:11 dbus-org.freedesktop.nm-dispatcher.service -> /usr/lib/systemd/system/NetworkManager-dispatcher.service
lrwxrwxrwx 1 root root 49 Sep 16 15:31 dbus-org.freedesktop.timesync1.service -> /usr/lib/systemd/system/systemd-timesyncd.service
lrwxrwxrwx 1 root root 40 Jan 16 00:10 default.target -> /usr/lib/systemd/system/graphical.target
-rwxr-xr-x 1 root root 360 Jan 24 23:48 disable-usb-wakeup.service
lrwxrwxrwx 1 root root 36 Jan 24 23:28 display-manager.service -> /usr/lib/systemd/system/sddm.service
drwxr-xr-x 2 root root 4096 Sep 15 16:13 getty.target.wants
drwxr-xr-x 2 root root 4096 Jan 5 17:49 multi-user.target.requires
drwxr-xr-x 2 root root 4096 Sep 27 22:18 multi-user.target.wants
drwxr-xr-x 2 root root 4096 Sep 15 17:11 network-online.target.wants
-rw-r--r-- 1 root root 280 Sep 18 13:24 reflector.service
drwxr-xr-x 2 root root 4096 Sep 16 15:31 sysinit.target.wants
[samson@archPC system]$ sudo systemctl start disable-usb-wakeup.service
Failed to start disable-usb-wakeup.service: Unit disable-usb-wakeup.service not found.
[samson@archPC system]$ sudo systemctl status disable-usb-wakeup.service
Unit disable-usb-wakeup.service could not be found.
[samson@archPC system]$ cat dis
disable-usb-wakeup.service display-manager.service
[samson@archPC system]$ cat disable-usb-wakeup.service
[Unit]
Description=Disable USB controllers in /proc/acpi/wakeup
[Service]
Type=oneshot
ExecStart=bash -c '\
while read -r device _ status _; do \
[[ $device == +([EX]HC*|USB*|PS2*) && $status == "*enabled" ]] && \
echo $device > /proc/acpi/wakeup; \
done < /proc/acpi/wakeup; \
true \
'
[Install]
WantedBy=multi-user.target
[samson@archPC system]$
also i notice that before dint make executable so was do
sudo chmod +x disable-usb-wakeup.service
but dint help neither
Offline
No, I meant to upload the file. Chances are there're CRLF terminations.
Online
here is file i dont know what is CRLF never hear about that
Offline
The file should work. The only differences you have to my file is: (1) you have a space character on the first line in front of "[Unit]", (2) you have a space character at the end of the last line after "multi-user.target". Everything else about the file is correct, and I think the spaces shouldn't break it.
Offline
i removed spaces and works now thanks also agine i ask whats mean when is disable or enabled i want to know what i do it to my system i want to LEARN no just fix it if i wanted to everything work and dont learning what doing then i will use ubuntu or mint not arch
Offline
The system only wakes up for acpi events from enabled devices, since apparently something™ on the usb hub at pci:0000:00:02.0 generates spurious events on suspends, you disabled that.
what this do will block mi to use that usb when i connect some usb on that port or what im confused about how you fix i want to learn
If you want to know whether this means the USB hub is now completely disabled, the answer is: no. This is only relevant for wake-ups, https://wiki.archlinux.org/index.php/Po … om_suspend
I will point out that this article says that the Bosnian "punctuation is similar to English" - so please start using it to structure your sentences, highlight questions and all the stuff we invented punctuation for in the first place. Thanks.
Online