How to fix USB mouse freeze in Ubuntu 10.04 or Fedora 13?

6

3

I'm just starting out using linux and so I installed Ubuntu to a hard disk.
I noticed that after 30 minutes or so, the mouse pointer would simply stop moving while the keyboard was o.k.
Exact same problem with Fedora as well. (The mouse works fine in Vista (it's a MS Comfort mouse 1000))

I searched and found a suggestion that I should disable the sleep settings, so I did that but no luck.

Interestingly, there is no freezing of the mouse when I use the Ubuntu Live CD - it's only the hard-disk-installed Ubuntu that's having the problem.

Update Found some old links from 2009 that say I should remove the "mouseemu" package. How to remove that package?

Update Unfortunately, that did not help - there is no mouseemu pkg installed. I tried setting kernel boot options noapic, irqpoll etc. - no luck. This is so annoying.

Zabba

Posted 2010-07-30T01:14:33.403

Reputation: 789

This problem still persists with a Microsoft Wheel Mouse Optical USB and PS/2 Compatible on Xubuntu LTS 14.04. Even, if you no longer use Windows™, the curse of Microsoft still comes to get ya... – Serge Stroobandt – 2014-12-29T11:33:48.283

1

I wonder if this has anything to do with it: https://plus.google.com/116960357493251979546/posts/RZpndv4BCCD

– Zabba – 2013-08-22T16:27:46.690

Answers

5

If you are using ArchLinux (could be applicable for other distros too), you need to find your device ID by lsusb and then add it to the blacklist in USB autosuspend by editing:

/etc/laptop-mode/conf.d/usb-autosuspend.conf

Example of the line to add:

AUTOSUSPEND_USBID_BLACKLIST="046d:c025"

USB autosuspend ref: Usb Autosuspend

Don't forget to restart the laptop-mode service afterwards, for the changes to become effective, e.g. by running sudo systemctl restart laptop-mode.service resp. sudo service laptop-mode restart.

jadelord

Posted 2010-07-30T01:14:33.403

Reputation: 177

Unfortunately, I cannot find that or any similar configuration file on Xubuntu LTS 14.04. – Serge Stroobandt – 2014-12-29T12:14:17.170

1

@SergeStroobandt Try installing this package: http://packages.ubuntu.com/lucid/utils/laptop-mode-tools Hope it helps

– jadelord – 2015-01-09T15:40:15.513

On debian I had to create this file on my own. Do I have to restart anything to let those changes become effective? – white_gecko – 2015-11-27T12:19:51.843

1Ah ok, one has to restart "laptop-mode" (e.g. by running sudo systemctl restart laptop-mode.service). I just didn't find it because the keyboard was suspended during tab-completion ;-) – white_gecko – 2015-11-27T12:23:34.390

Sometimes unplug/plug usb cable also necessary. – Vlad – 2015-12-02T16:23:10.743

@Vlad: unplugging and plugging is not a permanent solution, but it works if one is lazy :) Note: this solution would only work for systems using laptop-mode-tools as the power management service, which is the most common one. There are other alternatives such as powertop and tlp etc., which require similar configurations. – jadelord – 2015-12-03T15:36:08.180

@jadelord I mean unpluging/pluging needed with BLACKLISTing too. – Vlad – 2015-12-04T19:54:02.027

2

Sounds like it might be an issue with usb autosuspend.

Try adding usbcore.autosuspend=0 to your boot command to disable autosuspend completely (in Ubuntu 10.04 this works, not sure about Fedora - they may load usbcore as a module).

Alternatively, you may be able to disable autosuspend on a more fine-grained level by doing:

echo on > /sys/bus/usb/devices/usb2/power/level

^ this is the path on my machine, yours is probably slightly different. Currently this should be set to auto; setting it to on will disable autosuspend on that interface.

sml

Posted 2010-07-30T01:14:33.403

Reputation: 1 582

I did that change (in /boot/grub/menu.lst), and the mouse didn't freeze for about 2 hours - and then it froze again :( – Zabba – 2010-07-30T07:30:24.470

1

to remove package mouseemu, do:

sudo apt-get remove mouseemu

I don't know if that will solve your problem.

Marnix A. van Ammers

Posted 2010-07-30T01:14:33.403

Reputation: 1 978

Unfortunately, that did not help - there is no mouseemu pkg installed. I tried setting kernel boot options noapic, irqpoll etc. nothing works. This is so annoying! – Zabba – 2010-07-30T03:42:25.740

If the mouse really works OK when booted from the Ubuntu live CD, then it sure sounds like a bad installation. Perhaps you could try installing the OS again. – Marnix A. van Ammers – 2010-08-01T14:09:48.807

1

I had the same problem. The mouse suddenly freezes and in /var/log/messages:

USB disconnect, address XX

I had to reinstall compiz:

sudo apt-get purge compiz*
cd $HOME && rm -rf .compiz/ .config/compiz/

named

Posted 2010-07-30T01:14:33.403

Reputation: 11

0

I had the same problem on my Fedora 15.

Mouse was constantly hang for couple milliseconds and then everything was ok again. 10-40 seconds and the same thing was happening again.

I stumbled on this link https://wiki.archlinux.org/index.php/Touchpad_Synaptics#Touchpad_synchronization_issues in /var/log/messages-* , I found that USB mouse was constantly found and lost.

After that I plugged my mouse in different USB and now computer is super fast and no glitches experienced so far. :)

wormhit

Posted 2010-07-30T01:14:33.403

Reputation: 163

Yeah, even plugging the mouse in and out of the same USB socket unfreezes the mouse, but a little while later it happens again. – Serge Stroobandt – 2014-12-29T11:37:05.060