If you would like to know more about the iDevelopment.info Newsletter, please email me.
Erratic Mouse Behavior with Mouse on Linux and Belkin KVM Switch (12-March-2007)
When using a Belkin KVM switch (and several others), you may notice erratic behavior with the PS/2 mouse when switching back and forth to a Linux machine running Red Hat Linux (and Mandrake 10). The PS/2 mouse will simply go nuts; jumping all around the screen with random button clicks when you try to move it anywhere! Often times, switching to a USB mouse will resolve the problem. The root cause for this erratic behavior with the mouse rests in the fact that the PS/2 specification was not designed to be hot-pluggable. So, why is this a problem? Read on. All PS/2 mice can work in what we will call "Basic PS/2 Mouse Mode" — no scroll wheel and only 2 or three buttons work. This is the default mode when the mouse initially gets power. To activate the scroll wheel and/or any extra buttons, the mouse must receive a special reset code. This switches the mouse to "Advanced Mouse Mode" and changes the mouse data protocol a little. Many KVM switches may stop feeding power to the mouse when switching from one system to another. This causes the mouse to reset to "Basic PS/2 Mouse Mode". The system has no way of detecting that the mouse was reverted back to the basic mode. If the system was in a state where it had detected the mouse with "Advanced" capabilities and had sent it the appropriate reset code, it will expect the mouse to still be in "Advanced" mode and will misinterpret the mouse data (remember the mouse data protocol is different between Advanced and Basic mouse mode). The following article provides several solutions that I have used to resolve this problem. Erratic Mouse Behavior with Mouse on Linux and Belkin KVM Switch ---------------------------- Jeffrey M. Hunter Sr. Database Administrator email@example.com http://www.idevelopment.info ----------------------------