Disable USB power in ubuntu

  • find list of usb
lsusb

ls /sys/bus/usb/devices
  • disable USB on startup
echo disabled | sudo tee /sys/bus/usb/devices/usb2/power/wakeup
  • Remove power from port
echo suspend | sudo tee /sys/bus/usb/devices/usb2/power/level
  • add power to port again
echo auto | sudo tee /sys/bus/usb/devices/usb2/power/level

https://askubuntu.com/questions/1338682/is-it-possible-to-disable-usb-port-with-known-physical-location

Let me recap for Linux >= 2.6.38: The file power/level is deprecated now; use power/control instead. (power/wakeup is ok.)

https://stackoverflow.com/questions/4702216/controlling-a-usb-power-supply-on-off-with-linux

apt install powertop
powertop

Published by

Leave a Reply

Your email address will not be published. Required fields are marked *