# xdm keyboard unresponsive after 2nd keyboard unplugged



## lclee (Feb 2, 2011)

I am using FreeBSD 8.1 with xdm on the console. I have a primary keyboard and mouse, and I also have secondary keyboards devices. One secondary device is a credit card mag stripe reader and the other is a YubiKey security device.

The CC reader and the YubiKey present themselves as USB keyboards to the system, and both devices work as expected when they are plugged in.

When the secondary devices are unplugged, the primary keyboard becomes unresponsive. And no keyboard input can be entered into any window or program.  The NumLock and CapsLock LED's still work when the corresponding keys are pressed on the keyboard. The mouse still works so I am able to access drop down menus. If the YubiKey or CC reader is plugged back in, then the primary keyboard will also work. If the YubiKey or CC reader is not plugged back in then the only way to recover the system is to logout and log back in. I do not have to reboot.

For the security device to be effective, it's kinda critical that they not be left in the USB hub.

Any suggestions would be appreciated.

Larry


----------



## plamaiziere (Feb 8, 2011)

lclee said:
			
		

> I am using FreeBSD 8.1 with xdm on the console. I have a primary keyboard and mouse, and I also have secondary keyboards devices. One secondary device is a credit card mag stripe reader and the other is a YubiKey security device.
> 
> The CC reader and the YubiKey present themselves as USB keyboards to the system, and both devices work as expected when they are plugged in.
> 
> ...



You can try to use devd(8) and kbdcontrol(1) to manage the keyboards.
The idea is to detect devices attachement via devd, and kbdcontrol to add or remove devices in the kbdmux driver. 

This is just a suggestion. OTH.


----------

