# help with setting up a udev rule for keyborad and mouse

## nivw

hi all,

according to http://blog.interlinked.org/tutorials/linux.html

these lines are used to make the keyboard events permanent:

/etc/udev/rules.d/10-nek4k.rules

```
KERNEL=="event*",SYSFS{modalias}=="usb:v045Ep00DBd0173dc00dsc00dp00ic03isc01ip01", MODE="0644", NAME="input/event1"

KERNEL=="event*",SYSFS{modalias}=="usb:v045Ep00DBd0173dc00dsc00dp00ic03isc00ip00", MODE="0644", NAME="input/event2"

```

how ever even after adding these lines and restarting the pc, I still get these at event4 and event5

```
# udevadm info --path=/sys/class/input/event4 --query=allP: /devices/pci0000:00/0000:00:1d.2/usb4/4-2/4-2:1.0/input/input4/event4

N: input/event4

S: char/13:68

S: input/by-id/usb-Microsoft_Natural®_Ergonomic_Keyboard_4000-event-kbd

S: input/by-path/pci-0000:00:1d.2-usb-0:2:1.0-event-kbd

E: UDEV_LOG=3

E: DEVPATH=/devices/pci0000:00/0000:00:1d.2/usb4/4-2/4-2:1.0/input/input4/event4

E: MAJOR=13

E: MINOR=68

E: DEVNAME=/dev/input/event4

E: SUBSYSTEM=input

E: ID_INPUT=1

E: ID_INPUT_KEY=1

E: ID_INPUT_KEYBOARD=1

E: ID_VENDOR=Microsoft

E: ID_VENDOR_ENC=Microsoft

E: ID_VENDOR_ID=045e

E: ID_MODEL=Natural®_Ergonomic_Keyboard_4000

E: ID_MODEL_ENC=Natural®\x20Ergonomic\x20Keyboard\x204000

E: ID_MODEL_ID=00db

E: ID_REVISION=0173

E: ID_SERIAL=Microsoft_Natural®_Ergonomic_Keyboard_4000

E: ID_TYPE=hid

E: ID_BUS=usb

E: ID_USB_INTERFACES=:030101:030000:

E: ID_USB_INTERFACE_NUM=00

E: ID_USB_DRIVER=usbhid

E: ID_PATH=pci-0000:00:1d.2-usb-0:2:1.0

E: DEVLINKS=/dev/char/13:68 /dev/input/by-id/usb-Microsoft_Natural®_Ergonomic_Keyboard_4000-event-kbd /dev/input/by-path/pci-0000:00:1d.2-usb-0:2:1.0-event-kbd

# udevadm info --path=/sys/class/input/event5 --query=all

P: /devices/pci0000:00/0000:00:1d.2/usb4/4-2/4-2:1.1/input/input5/event5

N: input/event5

S: char/13:69

S: input/by-id/usb-Microsoft_Natural®_Ergonomic_Keyboard_4000-event-kbd

S: input/by-path/pci-0000:00:1d.2-usb-0:2:1.1-event-kbd

E: UDEV_LOG=3

E: DEVPATH=/devices/pci0000:00/0000:00:1d.2/usb4/4-2/4-2:1.1/input/input5/event5

E: MAJOR=13

E: MINOR=69

E: DEVNAME=/dev/input/event5

E: SUBSYSTEM=input

E: ID_INPUT=1

E: ID_INPUT_KEY=1

E: ID_INPUT_KEYBOARD=1

E: ID_VENDOR=Microsoft

E: ID_VENDOR_ENC=Microsoft

E: ID_VENDOR_ID=045e

E: ID_MODEL=Natural®_Ergonomic_Keyboard_4000

E: ID_MODEL_ENC=Natural®\x20Ergonomic\x20Keyboard\x204000

E: ID_MODEL_ID=00db

E: ID_REVISION=0173

E: ID_SERIAL=Microsoft_Natural®_Ergonomic_Keyboard_4000

E: ID_TYPE=hid

E: ID_BUS=usb

E: ID_USB_INTERFACES=:030101:030000:

E: ID_USB_INTERFACE_NUM=01

E: ID_USB_DRIVER=usbhid

E: ID_PATH=pci-0000:00:1d.2-usb-0:2:1.1

E: DEVLINKS=/dev/char/13:69 /dev/input/by-id/usb-Microsoft_Natural®_Ergonomic_Keyboard_4000-event-kbd /dev/input/by-path/pci-0000:00:1d.2-usb-0:2:1.1-event-kbd

```

How can I fix that?

----------

