Stop the annoying usb autosuspend under Ubuntu/Linuxmint

Got a problem that the usb mouse will been poweroff/suspend randomly(or periodically?) on Linuxmint 17 when the notebook is not in ac mode, here is a quick fix.

Disabling auto suspending USB:
for i in /sys/bus/usb/devices//power/autosuspend;
do echo 2 > $i;
done

Disable USB autosuspend:
for foo in /sys/bus/usb/devices/
/power/level;
do echo on > $foo;
done

If it works, also put them in /etc/rc.local to make it reboot-persistent/permanent.

Reference:
How to disable auto power off of usb devices like usb mouse?
http://askubuntu.com/a/301416

在 Linux 底下的 VirtualBox 連接 USB device 設定

透過 apt-get 或是從 virtualbox.org 下載 deb 在 LinuxMint 底下裝的Virtualbox,發現要從 Client 直接存取 Host 的 USB device 的時候發現virtualbox 的 USB 選單裏面什麼都沒有

原來是要把自己的帳戶加入 vboxusers 群阻就OK了:

sudo usermod -a -G vboxusers username

相關的說明可以參考 :

Oracle VM VirtualBox® User Manual / Chapter 2. Installation details / 2.3.4. The vboxusers group

我以為這東西應該要像 apache 一樣打包進去,安裝的時候自動處理就好了… xD