Laptop USB ports stop working: how to restart them without restarting the PC? [duplicate]
Solution 1:
Make sure that all USB devices are unplugged/safely removed and then try:
sudo modprobe -r usbhid && sleep 5 && sudo modprobe usbhid
and
sudo modprobe -r usb-storage
sudo modprobe usb-storage
This will reload the kernel modules for USB keyboards/mice and usb hdd's, and might emulate whatever it is about restarting that is fixing your problem. Good luck.
Solution 2:
Another thing worth trying: restart the udev subsystem:
sudo restart udev
Tell us whether that one worked.
As for finding out what happens, I would start by going through the system logs. For example, when something like that happens, try
dmesg | tail
Otherwise, record the exact time, and later see in
/var/log/syslog
for example by
gksudo gedit /var/log/syslog