Udev rule to disable touchpad when usbmouse is used [solved]

Hello guys,
I tried the udev-rule from the wiki to disable/enable touchpad when my usbmouse is plugged/unplugged.
Here is the rule:
#/etc/udev/rules.d/01-touchpad.rules
ACTION=="add", SUBSYSTEM=="input", ENV{ID_CLASS}="mouse", RUN+="/usr/bin/synclient TouchpadOff=1"
ACTION=="remove", SUBSYSTEM=="input", ENV{ID_CLASS}="mouse", RUN+="/usr/bin/synclient TouchpadOff=0"
The problem is that the status of my touchpad won't change when I plug/unplug my mouse. It has to be a problem with the rule because manually the synclient command works without any problem.
Here is the relevant output of lsusb:
Bus 007 Device 012: ID 046d:c00c Logitech, Inc. Optical Wheel Mouse
Thank you.
Last edited by orschiro (2010-03-18 15:15:10)

Hello Coacher,
I did what you said but have no idea what to do with that logfile. I'll better post it here. Perhaps you could help me again.
monitor will print the received events for:
UDEV - the event which udev sends out after rule processing
KERNEL - the kernel uevent
KERNEL[1268568009.445312] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/mouse2 (input)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/mouse2
SUBSYSTEM=input
DEVNAME=input/mouse2
SEQNUM=48167
MAJOR=13
MINOR=34
KERNEL[1268568009.461185] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/event14 (input)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/event14
SUBSYSTEM=input
DEVNAME=input/event14
SEQNUM=48168
MAJOR=13
MINOR=78
KERNEL[1268568009.471273] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14 (input)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14
SUBSYSTEM=input
PRODUCT=3/46d/c00c/110
NAME="Logitech USB Mouse"
PHYS="usb-0000:00:1d.1-2/input0"
UNIQ=""
EV==17
KEY==70000 0 0 0 0
REL==103
MSC==10
MODALIAS=input:b0003v046DpC00Ce0110-e0,1,2,4,k110,111,112,r0,1,8,am4,lsfw
SEQNUM=48169
KERNEL[1268568009.471331] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001/hidraw/hidraw0 (hidraw)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001/hidraw/hidraw0
SUBSYSTEM=hidraw
DEVNAME=hidraw0
SEQNUM=48170
MAJOR=251
MINOR=0
KERNEL[1268568009.472063] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001 (hid)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001
SUBSYSTEM=hid
HID_ID=0003:0000046D:0000C00C
HID_NAME=Logitech USB Mouse
HID_PHYS=usb-0000:00:1d.1-2/input0
MODALIAS=hid:b0003v0000046Dp0000C00C
SEQNUM=48171
KERNEL[1268568009.472116] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0 (usb)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0
SUBSYSTEM=usb
DEVTYPE=usb_interface
DEVICE=/proc/bus/usb/007/002
PRODUCT=46d/c00c/610
TYPE=0/0/0
INTERFACE=3/1/2
MODALIAS=usb:v046DpC00Cd0610dc00dsc00dp00ic03isc01ip02
SEQNUM=48172
KERNEL[1268568009.473105] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2 (usb)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2
SUBSYSTEM=usb
DEVNAME=bus/usb/007/002
DEVTYPE=usb_device
DEVICE=/proc/bus/usb/007/002
PRODUCT=46d/c00c/610
TYPE=0/0/0
BUSNUM=007
DEVNUM=002
SEQNUM=48173
MAJOR=189
MINOR=769
UDEV [1268568009.596460] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/event14 (input)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/event14
SUBSYSTEM=input
DEVNAME=/dev/input/event14
SEQNUM=48168
ID_INPUT=1
ID_INPUT_MOUSE=1
ID_VENDOR=Logitech
ID_VENDOR_ENC=Logitech
ID_VENDOR_ID=046d
ID_MODEL=USB_Mouse
ID_MODEL_ENC=USB\x20Mouse
ID_MODEL_ID=c00c
ID_REVISION=0610
ID_SERIAL=Logitech_USB_Mouse
ID_TYPE=hid
ID_BUS=usb
ID_USB_INTERFACES=:030102:
ID_USB_INTERFACE_NUM=00
ID_USB_DRIVER=usbhid
ID_PATH=pci-0000:00:1d.1-usb-0:2:1.0
MAJOR=13
MINOR=78
DEVLINKS=/dev/char/13:78 /dev/input/by-id/usb-Logitech_USB_Mouse-event-mouse /dev/input/by-path/pci-0000:00:1d.1-usb-0:2:1.0-event-mouse
UDEV [1268568009.605422] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001/hidraw/hidraw0 (hidraw)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001/hidraw/hidraw0
SUBSYSTEM=hidraw
DEVNAME=/dev/hidraw0
SEQNUM=48170
MAJOR=251
MINOR=0
DEVLINKS=/dev/char/251:0
UDEV [1268568009.606695] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/mouse2 (input)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14/mouse2
SUBSYSTEM=input
DEVNAME=/dev/input/mouse2
SEQNUM=48167
ID_INPUT=1
ID_INPUT_MOUSE=1
ID_VENDOR=Logitech
ID_VENDOR_ENC=Logitech
ID_VENDOR_ID=046d
ID_MODEL=USB_Mouse
ID_MODEL_ENC=USB\x20Mouse
ID_MODEL_ID=c00c
ID_REVISION=0610
ID_SERIAL=Logitech_USB_Mouse
ID_TYPE=hid
ID_BUS=usb
ID_USB_INTERFACES=:030102:
ID_USB_INTERFACE_NUM=00
ID_USB_DRIVER=usbhid
ID_PATH=pci-0000:00:1d.1-usb-0:2:1.0
MAJOR=13
MINOR=34
DEVLINKS=/dev/char/13:34 /dev/input/by-id/usb-Logitech_USB_Mouse-mouse /dev/input/by-path/pci-0000:00:1d.1-usb-0:2:1.0-mouse
UDEV [1268568009.608264] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001 (hid)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0001
SUBSYSTEM=hid
HID_ID=0003:0000046D:0000C00C
HID_NAME=Logitech USB Mouse
HID_PHYS=usb-0000:00:1d.1-2/input0
MODALIAS=hid:b0003v0000046Dp0000C00C
SEQNUM=48171
UDEV [1268568009.609657] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14 (input)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input14
SUBSYSTEM=input
PRODUCT=3/46d/c00c/110
NAME="Logitech USB Mouse"
PHYS="usb-0000:00:1d.1-2/input0"
UNIQ=""
EV==17
KEY==70000 0 0 0 0
REL==103
MSC==10
MODALIAS=input:b0003v046DpC00Ce0110-e0,1,2,4,k110,111,112,r0,1,8,am4,lsfw
SEQNUM=48169
UDEV [1268568009.611650] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0 (usb)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0
SUBSYSTEM=usb
DEVTYPE=usb_interface
DEVICE=/proc/bus/usb/007/002
PRODUCT=46d/c00c/610
TYPE=0/0/0
INTERFACE=3/1/2
MODALIAS=usb:v046DpC00Cd0610dc00dsc00dp00ic03isc01ip02
SEQNUM=48172
UDEV [1268568009.614119] remove /devices/pci0000:00/0000:00:1d.1/usb7/7-2 (usb)
UDEV_LOG=0
ACTION=remove
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2
SUBSYSTEM=usb
DEVNAME=/dev/bus/usb/007/002
DEVTYPE=usb_device
DEVICE=/proc/bus/usb/007/002
PRODUCT=46d/c00c/610
TYPE=0/0/0
BUSNUM=007
DEVNUM=002
SEQNUM=48173
ID_VENDOR=Logitech
ID_VENDOR_ENC=Logitech
ID_VENDOR_ID=046d
ID_MODEL=USB_Mouse
ID_MODEL_ENC=USB\x20Mouse
ID_MODEL_ID=c00c
ID_REVISION=0610
ID_SERIAL=Logitech_USB_Mouse
ID_BUS=usb
ID_USB_INTERFACES=:030102:
MAJOR=189
MINOR=769
DEVLINKS=/dev/char/189:769
KERNEL[1268568012.396622] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2 (usb)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2
SUBSYSTEM=usb
DEVNAME=bus/usb/007/003
DEVTYPE=usb_device
DEVICE=/proc/bus/usb/007/003
PRODUCT=46d/c00c/610
TYPE=0/0/0
BUSNUM=007
DEVNUM=003
SEQNUM=48174
MAJOR=189
MINOR=770
KERNEL[1268568012.399460] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0 (usb)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0
SUBSYSTEM=usb
DEVTYPE=usb_interface
DEVICE=/proc/bus/usb/007/003
PRODUCT=46d/c00c/610
TYPE=0/0/0
INTERFACE=3/1/2
MODALIAS=usb:v046DpC00Cd0610dc00dsc00dp00ic03isc01ip02
SEQNUM=48175
KERNEL[1268568012.399649] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002 (hid)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002
SUBSYSTEM=hid
HID_ID=0003:0000046D:0000C00C
HID_NAME=Logitech USB Mouse
HID_PHYS=usb-0000:00:1d.1-2/input0
DRIVER=generic-usb
MODALIAS=hid:b0003v0000046Dp0000C00C
SEQNUM=48176
KERNEL[1268568012.415310] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16 (input)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16
SUBSYSTEM=input
PRODUCT=3/46d/c00c/110
NAME="Logitech USB Mouse"
PHYS="usb-0000:00:1d.1-2/input0"
UNIQ=""
EV==17
KEY==70000 0 0 0 0
REL==103
MSC==10
MODALIAS=input:b0003v046DpC00Ce0110-e0,1,2,4,k110,111,112,r0,1,8,am4,lsfw
SEQNUM=48177
KERNEL[1268568012.415530] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/mouse2 (input)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/mouse2
SUBSYSTEM=input
DEVNAME=input/mouse2
SEQNUM=48178
MAJOR=13
MINOR=34
KERNEL[1268568012.415645] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/event14 (input)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/event14
SUBSYSTEM=input
DEVNAME=input/event14
SEQNUM=48179
MAJOR=13
MINOR=78
KERNEL[1268568012.415763] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002/hidraw/hidraw0 (hidraw)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002/hidraw/hidraw0
SUBSYSTEM=hidraw
DEVNAME=hidraw0
SEQNUM=48180
MAJOR=251
MINOR=0
UDEV [1268568012.419223] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2 (usb)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2
SUBSYSTEM=usb
DEVNAME=/dev/bus/usb/007/003
DEVTYPE=usb_device
DEVICE=/proc/bus/usb/007/003
PRODUCT=46d/c00c/610
TYPE=0/0/0
BUSNUM=007
DEVNUM=003
SEQNUM=48174
ID_VENDOR=Logitech
ID_VENDOR_ENC=Logitech
ID_VENDOR_ID=046d
ID_MODEL=USB_Mouse
ID_MODEL_ENC=USB\x20Mouse
ID_MODEL_ID=c00c
ID_REVISION=0610
ID_SERIAL=Logitech_USB_Mouse
ID_BUS=usb
ID_USB_INTERFACES=:030102:
MAJOR=189
MINOR=770
DEVLINKS=/dev/char/189:770
UDEV [1268568012.420120] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0 (usb)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0
SUBSYSTEM=usb
DEVTYPE=usb_interface
DEVICE=/proc/bus/usb/007/003
PRODUCT=46d/c00c/610
TYPE=0/0/0
INTERFACE=3/1/2
MODALIAS=usb:v046DpC00Cd0610dc00dsc00dp00ic03isc01ip02
SEQNUM=48175
UDEV [1268568012.420621] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002 (hid)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002
SUBSYSTEM=hid
HID_ID=0003:0000046D:0000C00C
HID_NAME=Logitech USB Mouse
HID_PHYS=usb-0000:00:1d.1-2/input0
DRIVER=generic-usb
MODALIAS=hid:b0003v0000046Dp0000C00C
SEQNUM=48176
UDEV [1268568012.421369] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002/hidraw/hidraw0 (hidraw)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/0003:046D:C00C.0002/hidraw/hidraw0
SUBSYSTEM=hidraw
DEVNAME=/dev/hidraw0
SEQNUM=48180
MAJOR=251
MINOR=0
DEVLINKS=/dev/char/251:0
UDEV [1268568012.453075] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16 (input)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16
SUBSYSTEM=input
PRODUCT=3/46d/c00c/110
NAME="Logitech USB Mouse"
PHYS="usb-0000:00:1d.1-2/input0"
UNIQ=""
EV==17
KEY==70000 0 0 0 0
REL==103
MSC==10
MODALIAS=input:b0003v046DpC00Ce0110-e0,1,2,4,k110,111,112,r0,1,8,am4,lsfw
SEQNUM=48177
UDEV [1268568012.457340] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/mouse2 (input)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/mouse2
SUBSYSTEM=input
DEVNAME=/dev/input/mouse2
SEQNUM=48178
ID_INPUT=1
ID_INPUT_MOUSE=1
ID_VENDOR=Logitech
ID_VENDOR_ENC=Logitech
ID_VENDOR_ID=046d
ID_MODEL=USB_Mouse
ID_MODEL_ENC=USB\x20Mouse
ID_MODEL_ID=c00c
ID_REVISION=0610
ID_SERIAL=Logitech_USB_Mouse
ID_TYPE=hid
ID_BUS=usb
ID_USB_INTERFACES=:030102:
ID_USB_INTERFACE_NUM=00
ID_USB_DRIVER=usbhid
ID_PATH=pci-0000:00:1d.1-usb-0:2:1.0
MAJOR=13
MINOR=34
DEVLINKS=/dev/char/13:34 /dev/input/by-id/usb-Logitech_USB_Mouse-mouse /dev/input/by-path/pci-0000:00:1d.1-usb-0:2:1.0-mouse
UDEV [1268568012.457383] add /devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/event14 (input)
UDEV_LOG=0
ACTION=add
DEVPATH=/devices/pci0000:00/0000:00:1d.1/usb7/7-2/7-2:1.0/input/input16/event14
SUBSYSTEM=input
DEVNAME=/dev/input/event14
SEQNUM=48179
ID_INPUT=1
ID_INPUT_MOUSE=1
ID_VENDOR=Logitech
ID_VENDOR_ENC=Logitech
ID_VENDOR_ID=046d
ID_MODEL=USB_Mouse
ID_MODEL_ENC=USB\x20Mouse
ID_MODEL_ID=c00c
ID_REVISION=0610
ID_SERIAL=Logitech_USB_Mouse
ID_TYPE=hid
ID_BUS=usb
ID_USB_INTERFACES=:030102:
ID_USB_INTERFACE_NUM=00
ID_USB_DRIVER=usbhid
ID_PATH=pci-0000:00:1d.1-usb-0:2:1.0
MAJOR=13
MINOR=78
DEVLINKS=/dev/char/13:78 /dev/input/by-id/usb-Logitech_USB_Mouse-event-mouse /dev/input/by-path/pci-0000:00:1d.1-usb-0:2:1.0-event-mouse
Thank you.

Similar Messages

  • Problem with udev rule to disable touchpad when USB mouse connects

    Hi, I've been running Arch on this laptop, but I can't get this udev rule to work properly.
    What I want to happen is: when I plug in my usb mouse, the laptop touchpad is disabled, and the left and right buttons are reversed (I'm left handed)
    After following several tutorials, both from the arch wiki and other sites, I've come up with this udev rule:
    ACTION=="add", SUBSYSTEM=="input", RUN+="/usr/local/bin/USBMouse.sh"
    ACTION=="remove", SUBSYSTEM=="input", RUN+="/usr/local/bin/USBMouse.sh"
    And here's the script it links to (USBMouse.sh):
    #!/bin/bash
    export DISPLAY=:0.0
    synclient TouchPadOff=$(/usr/bin/lsusb | grep "Microsoft Corp.\
    Nano Transceiver v1.0 for Bluetooth" | wc -l)
    if [[ $(/usr/bin/lsusb | grep "Microsoft Corp.\
    Nano Transceiver v1.0 for Bluetooth" | wc -l) == 1 ]]
    then
    xmodmap -e 'pointer = 3 2 1'
    fi
    if [[ $(/usr/bin/lsusb | grep "Microsoft Corp.\
    Nano Transceiver v1.0 for Bluetooth" | wc -l) == 0 ]]
    then
    xmodmap -e 'pointer = 1 2 3'
    fi
    Running the script from a terminal returns no errors and works as expected. The problem is when I plug/unplug the mouse from the usb port, nothing happens.
    I appreciate any insight you might have about how to fix this, and thank you in advance

    This has already been done. And another relevant thread.

  • Problem disabling touchpad when mouse present

    Hi,
    I looked on the wiki to find out how to disable the touchpad on my laptop when a USB mouse is present. I configured xorg.conf in the correct way, then I added the following udev rules as instructed:
    ACTION=="add", SUBSYSTEM=="input", ID_CLASS="mouse", RUN+="/usr/bin/synclient TouchpadOff=1"
    ACTION=="remove", SUBSYSTEM=="input", ID_CLASS="mouse", RUN+="/usr/bin/synclient TouchpadOff=0"
    This works to an extent, insofar as when I have a running system with X working the touchpad is disabled and enabled when the mouse is plugged in or removed respectively. However, when I boot the machine with a mouse attached, X starts up and both devices are enabled. The reason for this is twofold:
    1. synclient will not work properly when the X server is not running
    2. An "add" action is not generated for the device unless you actually plug it in on a running system
    Is there any way to detect the presence of the USB mouse on boot and disable the touchpad? It would be much cooler if this could be done without looking for specific device names like /dev/input/mouse0, mouse1 etc. because then we will have a solution that works for everyone that we can put on the wiki.

    OK, so this is just a skeleton of a possible solution...  Assuming that it is a USB mouse that we're talking about...  Run "lsusb and check the ID number of the mouse (it should look something like "07aa:2501", for example).  Write a little script which looks something like this:
    #!/bin/sh
    lsusb | grep -q 07aa:2501
    if [ "$?" -eq "0" ]
    then
    /usr/bin/synclient TouchpadOff=1
    fi
    Change "07aa:2501" to the ID of your mouse, of course.  The script checks if the mouse is connected and if it is it disables the touchpad; if mouse is not connected then nothing happens.  I haven't checked if it works (I have no mouse to try it with here) but it should work.  Once you save the script and make it executable add it to /etc/rc.local so that it gets executed on every boot.
    EDIT: You're right -- synclient is not going to work if X server is not running, so the rc.local is not a good place to execute that script...  It's not a huge problem -- you should be able to execute it during the start up routine of X (add it to xinitrc, possibly with sleep to make sure that X is actually started when the script is executed) or to autostart in gnome/kde (depending on what WM/DE you're using).
    Last edited by fwojciec (2008-02-20 22:46:00)

  • L3000-N100 - Disable touchpad when typing?

    I have a Lenovo 3000 N100 with Windows Vista.  I want to disable the touchpad when using a USB mouse. The touchpad does not show up in the control panel under 'mouse'.  There is no button anywhere near the touchpad.  There is no function key with a mouse or touchpad symbol visible on it.  There are 4 buttons on the top right, 3 control volume, and the 4th one looks like an orange suitcase with a wrench, but it doesn't appear to do anything.  I've searched forums,  but can't find a solution.  Can anybody tell me how I can disable the touchpad to stop the cursor from jumping all over when I'm typing?  Thanks!!!
    Solved!
    Go to Solution.

    Hi griffraser,
    You should have a Synaptics touchpad.  Try going into Control Panel, Device Manager and at the top of the window, click view.  Then click "Show hidden devices".  Then click Mice and other pointing devices and see if the touchpad shows up in there. If it does, right click it and then click disable.
    Do you not have an icon for the touchpad in your taskbar on the right side?
    Edit:  If you don't, you should be able to go back into Control Panel and click Taskbar and Start Menu and then click Customize in the Notification area window. I always have the "Always show all icons and notifications on the taskbar" checked, but if you don't, you can click on the "Show icon and notifications' to the right of the touchpad and the icon for the touchpad should show up in the taskbar.  It's easy  to disable it from the taskbar then. 
    Regards,
    Dave
    T430u, x301, x200T, x61T, x61, x32, x41T, x40, U160, ThinkPad Tablet 1838-22R, Z500 touch, Yoga Tab 2 Windows 8.1, Yoga Tablet 3 Pro
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution"!
    If someone helped you today, pay it forward. Help Someone Else!
    English Community   Deutsche Community   Comunidad en Español   Русскоязычное Сообщество

  • Udev rule to symlink touchpad redirects to mouse0

    Hi,
    I'm trying to write some udev rules to create symlinks to the keyboard, lid switch, touchpad and nub on my HP Compaq NC8000 laptop. These are the rules I have:
    SUBSYSTEMS=="input", ATTRS{name}=="AT Translated Set 2 keyboard", SYMLINK+="input/keyboard", MODE:="660", GROUP="input"
    SUBSYSTEMS=="input", ATTRS{name}=="Lid Switch", SYMLINK+="input/lid-switch", MODE:="660", GROUP="input"
    SUBSYSTEMS=="input", ATTRS{phys}=="isa0060/serio4/input0", SYMLINK+="input/touchpad", MODE:="660", GROUP="input"
    SUBSYSTEMS=="input", ATTRS{phys}=="synaptics-pt/serio0/input0", SYMLINK+="input/nub", MODE:="660", GROUP="input"
    The keyboard and lid switch work fine, but the touchpad and nub links point to mouse0 and mouse1 respectively. I need them to point to event6 and event7. Is this possible?
    I've tried specifically stating all the symlinks as follows:
    SUBSYSTEMS=="input", ATTRS{phys}=="isa0060/serio4/input0", SYMLINK+="input/touchpad input/mouse0", MODE:="660", GROUP="input"
    but this doesn't work either. I've also tried to match different criteria, for example:
    ATTRS{phys}=="isa0060/serio4/input0"
    and
    ATTRS{name}=="SynPS/2 Synaptics TouchPad"
    but this also doesn't work.
    any ideas?
    thanks
    James

    Hi,
    I'm trying to write some udev rules to create symlinks to the keyboard, lid switch, touchpad and nub on my HP Compaq NC8000 laptop. These are the rules I have:
    SUBSYSTEMS=="input", ATTRS{name}=="AT Translated Set 2 keyboard", SYMLINK+="input/keyboard", MODE:="660", GROUP="input"
    SUBSYSTEMS=="input", ATTRS{name}=="Lid Switch", SYMLINK+="input/lid-switch", MODE:="660", GROUP="input"
    SUBSYSTEMS=="input", ATTRS{phys}=="isa0060/serio4/input0", SYMLINK+="input/touchpad", MODE:="660", GROUP="input"
    SUBSYSTEMS=="input", ATTRS{phys}=="synaptics-pt/serio0/input0", SYMLINK+="input/nub", MODE:="660", GROUP="input"
    The keyboard and lid switch work fine, but the touchpad and nub links point to mouse0 and mouse1 respectively. I need them to point to event6 and event7. Is this possible?
    I've tried specifically stating all the symlinks as follows:
    SUBSYSTEMS=="input", ATTRS{phys}=="isa0060/serio4/input0", SYMLINK+="input/touchpad input/mouse0", MODE:="660", GROUP="input"
    but this doesn't work either. I've also tried to match different criteria, for example:
    ATTRS{phys}=="isa0060/serio4/input0"
    and
    ATTRS{name}=="SynPS/2 Synaptics TouchPad"
    but this also doesn't work.
    any ideas?
    thanks
    James

  • Automatically disabling touchpad when mouse plugged in

    Is there some way for me to configure udev so that, when I plug a USB mouse into my laptop, the laptop's touchpad gets disabled? And reenabled if I pull the mouse? The touchpadd can be a PITA when I am typing ... a slight brush of the thumb can cause a "mouse click" often moving my cursor location.
    Mark

    See the manpage of udev, quote:
    After device node creation, removal, or network device  renaming,  udev
           executes  the programs located in the directory tree under /etc/dev.d/.
           The name of a program must have the suffix .dev to be recognized.
           In addition to the hotplug environment variables, UDEV_LOG  is  set  if
           udev  is  configured  to use the syslog facility. Executed programs may
           want to follow that setting.  DEVNAME is exported to make the  name  of
           the  created node, or the name the network device is renamed to, avail-
           able to the executed program.  The  programs  in  every  directory  are
           sorted in lexical order, while the directories are searched in the fol-
           lowing order:
           /etc/dev.d/$(DEVNAME)/*.dev
           /etc/dev.d/$(SUBSYSTEM)/*.dev
           /etc/dev.d/default/*.dev

  • Can't disable touchpad when external mouse connected

    Hey guys,
    OS: Win7 64Bit
    Product : b0p18pa#ab4
    Model: dv6-7007tx
    The only way i've figured out a way to disable the touchpad is to uninstall the PS/2 compatible mouse in device manager. (which requires a restart) to come into effect and is reinstalled after the next restart afterwards.
    the touchpad is SO sensitive it makes it extremely aggrivating to type as i keep tapping  the pad with my palms.
    any insight would be fantastic.
    cheers guys.

    Hi,
    Please try:
       Control panel > Mouse > ClickPad Settings
       Tick Disable internal pointing device when .....
       Click Apply
    Regards. 
    BH
    **Click the KUDOS thumb up on the left to say 'Thanks'**
    Make it easier for other people to find solutions by marking a Reply 'Accept as Solution' if it solves your problem.

  • How to disable touchpad when usb mouse in on HP ENVY dv7-7259nr Notebook PC‏ using Windows 7

    I would like to have my touch pad disabled when using my USB mouse or otherwise be able to manually disable it.  It is a pain to use when typing with the touch pad enabled but I would like to use the touch pad on occasions such as when I am traveling or if my mouse goes out. Not to mention, I would need to re-enable the touh pad if for some reason I have no mouse (keyboard shortcut?)
    I am using windows 7 on my HP ENVY dv7-7259nr Notebook PC‏

    This is what it looks like. 
    You should consider returning you notebook to the Windows 8 OS. There are many new features that it has that Windows 7 never did. Download use the free open source software called classic shell to give yourself a start button in Windows 8 that even has more features than Windows 7 start buton does. Once you use Windows 8 for a while you will enjoy it, especially the refresh feature and lower memory use. 
    I wouldn't hold my breath waiting for Windows 7 drivers.
    regards,
    erico
    ****Please click on Accept As Solution if a suggestion solves your problem. It helps others facing the same problem to find a solution easily****
    2015 Microsoft MVP - Windows Experience Consumer

  • Disable touchpad when you connect usb mouse

    Hi I used to do this in windows 7 in driver of laptop but seems like its not installed right ow is there a way to do it throught windows?

    Visit your PC manufacturer's website and install the latest driver related to mouse (it is okay if you install the driver for Windows 7 too).
    If you received any error, try run it in compatibility mode.
    Report this issue using Feedback App.

  • Trying to disable a Udev rule. Deleting it is not working.

    I am trying to configure my sound. I have a usb sound card I want it to be default.
    I followed the procedure as described here .
    So, my default soundcard was my usb soundcard!
    But, did this,
    Hot-plugging a USB sound card
    The following udev rule can be used to automatically make a USB sound card the primary output device when the card is plugged in. To do so, create the following file with the specified contents and.
    /etc/udev/rules.d/00-local.rules
    KERNEL=="pcmC[D0-9cp]*", ACTION=="add", PROGRAM="/usr/bin/sh -c 'K=%k; K=$${K#pcmC}; K=$${K%%D*}; echo defaults.ctl.card $$K > /etc/asound.conf; echo defaults.pcm.card $$K >>/etc/asound.conf'"
    KERNEL=="pcmC[D0-9cp]*", ACTION=="remove", PROGRAM="/usr/bin/sh -c 'echo defaults.ctl.card 0 > /etc/asound.conf; echo defaults.pcm.card 0 >>/etc/asound.conf'"
    For information regarding loading udev rules see the following: Udev#Loading_new_rules
    But it was a mistake.. So, I wanted to correct this. I deleted this file.
    rm -rf /etc/udev/rules.d/00-local.rules
    after that, as mentioned here
    udevadm control --reload
    udevadm trigger
    After reboot, I was having again the file
    /etc/asound.conf
    which is created after the rule is triggered.
    So, what can i Do ?

    MoonSwan wrote:
    I may be mis-understanding your problem, zabrielza, so please correct me if I am off base here.
    You have 2 soundcards, yes?  One is a HDA Intel on-board and the other is your USB card.  You want the USB card to be the default all the time, correct?  If that is true then I suggest using this little part of the Alsa Wiki article to set your default card: https://wiki.archlinux.org/index.php/Ad … sound_card  I have used that part of the wiki successfully to set my default card, as I also have two sound cards, and I've had few issues since then. 
    As I said when I began this post, I may be wrong here so please say so if I am.  You might also want to start over and re-state exactly what your goal is because I see some posters are confused about what it is you're trying to accomplish.
    Yes you are right. You described my situation perfectly.  Firstly I started this topic to learn/know How should i disable correctly udev rules. It turns out that my udev rule is disabled. I have this file
    /etc/modprobe.d/alsa-base.conf
    configured correctly. Before I create the rule I had sound correctly but I never followed this.
    Select the default PCM via environment variable
    In your configuration file, preferably global, add:
    pcm.!default {
        type plug
        slave.pcm {
            @func getenv
            vars [ ALSAPCM ]
            default "hw:Audigy2"
    You need to replace the default line with the name of your card (in the example is Audigy2). You can get the names with aplay -l or you can also use PCMs like surround51. But if you need to use the microphone it is a good idea to select full-duplex PCM as default.
    Now you can start programs selecting the sound card just changing the environment variable ALSAPCM. It works fine for all program that do not allow to select the card, for the others ensure you keep the default card. For example, assuming you wrote a downmix PCM called mix51to20 you can use it with mplayer using the commandline ALSAPCM=mix51to20 mplayer example_6_channel.wav
    Instead of using new variables, you could set one of those mentioned in default global configuration.
    /usr/share/alsa/alsa.conf
    Variable name # Definition
    ALSA_CARD # pcm.default pcm.hw pcm.plughw ctl.sysdefault ctl.hw rawmidi.default rawmidi.hw hwdep.hw
    ALSA_CTL_CARD # ctl.sysdefault ctl.hw
    ALSA_HWDEP_CARD # hwdep.default hwdep.hw
    ALSA_HWDEP_DEVICE # hwdep.default hwdep.hw
    ALSA_PCM_CARD # pcm.default pcm.hw pcm.plughw
    ALSA_PCM_DEVICE # pcm.hw pcm.plughw
    ALSA_RAWMIDI_CARD # rawmidi.default rawmidi.hw
    ALSA_RAWMIDI_DEVICE # rawmidi.default rawmidi.hw
    Note: Pay attention to default addressing type.
    So, Should I try it now? Do I have to reset alsa-installation first ( I do not know how to do this ) or not?

  • Better solution to disabling touchpad on external mouse connection??

    Hi all,
    I've been playing around with a "clean" solution to disabling the Synaptics touchpad on my laptop - when I connected a USB external mouse OR when the USB mouse is already connected at boot...
    I have a very hacked together solution... First for info the stock "mouse" devices on laptop...
    lrwxrwxrwx 1 root root 0 26.09.2013 12:38 mouse0 -> ../../devices/virtual/input/input6/mouse0/
    lrwxrwxrwx 1 root root 0 26.09.2013 12:38 mouse1 -> ../../devices/platform/i8042/serio4/input/input14/mouse1/
    FYI MCE IR Keyboard/Mouse (ite-cir) and Synaptics touchpad respectively.
    So I have a simple script...
    #! /bin/bash
    username=$(users | gawk '{print $1}')
    export DISPLAY=":0"
    export XAUTHORITY="/home/${username}/.Xauthority"
    if $(lsusb -v | grep -q Mouse); then
    synclient TouchpadOff=1
    else
    synclient TouchpadOff=0
    fi
    exit 0
    that is called by a udev (/etc/udev/rules.d/01-touchpad.rules ) rule...
    ACTION=="add", SUBSYSTEM=="input", KERNEL=="mouse[0-9]", ENV{ID_CLASS}="mouse", PROGRAM="/root/Scripts/mouse_detect.sh"
    ACTION=="remove", SUBSYSTEM=="input", KERNEL=="mouse[0-9]", ENV{ID_CLASS}="mouse", PROGRAM="/root/Scripts/mouse_detect.sh"
    Problem is that solution does not fire when I logout and login again, or boot from cold, into KDM/KDE... My hack to solve this problem was the following (awful!!) systemd unit...
    [Unit]
    Description=Mouse Detect (on Desktop Environment startup)
    After=display-manager.service
    Requires=display-manager.service
    [Service]
    Type=oneshot
    RestartSec=20
    Restart=always
    ExecStart=/root/Scripts/mouse_detect.sh
    [Install]
    WantedBy=graphical.target
    It's stored as mouse-detect.service in /etc/systemd/system ... It fires too early, probably when KDM is active (hence why it auto-restarts every 20 seconds).... Not even sure if it's possible to get the mouse_detect.sh script to work during the KDM Session (as I'm not sure where the Xauthority information is stored for KDM and so on)...
    If I make it the service unit stop on a successful run of synclient (e.g. Restart=onfailure) - it won't every refire - if say I logout and log back into my KDE session!!
    Any thoughts on how to do this more cleanly??
    Given that the current solution works - I was just looking to learn some more - by implementing a less hacked version!! 
    Thanks
    Bob
    Last edited by bobwya (2013-09-26 14:25:52)

    Zamajalo wrote:What about using one simple udev rule? Manual can be found here
    The udev rule falls down when you boot with a USB mouse already attached to the laptop - on boot (as I clearly stated). The rule only detects change of state (mouse attached or detached). Also what if you have 2 USB mice attached?? :-) The udev idea of what a "mouse" is - is also rather generic (e.g. touchpad, infrared remote control are definitely not USB mice!!)
    The script is overkill for running from a udev rule (- although it does have the benefit of not have a hard-coded username). However the script is necessary to test for a mouse being attached - when a KDE session starts. That was basically what my question was about... How to run this script at the start of the KDE session - my use of lsusb is annoying - because it means the script must run as root (due to the verbose flag)... There must be a way to do this as a normal desktop user (and then the script should run OK in a normal autostart desktop script).
    Thanks
    Bob

  • K3011w - How disable the touchpad when using USB mouse?

    Is there a way to disable the touchpad on the docking keybd when using a USB mouse? It is a real pain typing along and be in the middle of sentence some where else on the page.

    hi whippetguy,
    Thanks for Posting,
       The touchpad on the dock uses a Windows driver and does not have any special Software to Disable it via shortcut,
    How I found to go around on what you need is
      With the tablet on the dock with no USB mouse yet
                      Press (Windows key+x) and choose device manager on the list
                            On Device Manager window open mice and pointing device and rightclick disable
    This should disable the dock touchpad and Now you can plu in your USB mouse,
    Before you unplu your USB mouse after use, Go to device manager again and Enable the device you disabled.
    Hope this helps
    Cheers!
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution"! This will help the rest of the Community with similar issues identify the verified solution and benefit from it.
    Follow @LenovoForums on Twitter!

  • [SOLVED] Custom udev rule only working when triggered manually

    I have the following rule created for a USB gamecube controller adapter:
    SUBSYSTEMS=="usb", ATTRS{idVendor}=="057e", ATTRS{idProduct}=="0337", MODE="0666"
    This rule only takes effect when I run udevadm trigger AFTER my device is plugged in. If I then unplug the device, and plug it back in, my device no longer works. My device also doesn't work on boot. I have to plug my device in and then trigger the rules manually.
    Any ideas why this is happening? I don't want to have to run udevadm trigger every time I turn my computer on.
    Last edited by Exershio (2015-04-15 23:01:19)

    I tried reloading the configuration but it doesn't affect the issue. As for monitoring udev, this appears when I plug the device in:
    KERNEL[3439.476646] add /devices/pci0000:00/0000:00:12.0/usb4/4-5 (usb)
    KERNEL[3439.478441] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0 (usb)
    KERNEL[3439.486155] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0/0003:057E:0337.0009 (hid)
    KERNEL[3439.492319] add /class/usbmisc (class)
    KERNEL[3439.492497] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0/usbmisc/hiddev0 (usbmisc)
    KERNEL[3439.492602] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0/0003:057E:0337.0009/hidraw/hidraw0 (hidraw)
    UDEV [3439.493842] add /class/usbmisc (class)
    UDEV [3439.494832] add /devices/pci0000:00/0000:00:12.0/usb4/4-5 (usb)
    UDEV [3439.496365] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0 (usb)
    UDEV [3439.498256] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0/usbmisc/hiddev0 (usbmisc)
    UDEV [3439.498378] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0/0003:057E:0337.0009 (hid)
    UDEV [3439.499567] add /devices/pci0000:00/0000:00:12.0/usb4/4-5/4-5:1.0/0003:057E:0337.0009/hidraw/hidraw0 (hidraw)
    So it seems udev is detecting the GC adapter being plugged in, but it doesn't apply permissions 0666 to it until I manually run udevadm trigger.
    See what happens below, directly after plugging it in:
    $ ls -l /dev/bus/usb/004/005
    crw-rw-r-- 1 root root 189, 388 Apr 15 16:59 /dev/bus/usb/004/005
    $ sudo udevadm trigger
    $ ls -l /dev/bus/usb/004/005
    crw-rw-rw- 1 root root 189, 388 Apr 15 17:03 /dev/bus/usb/004/005
    Okay this is weird. So I appended my udev rule with GROUP="users" to see if that would help, and after reloading the rules, this happens after my device is plugged in:
    $ ls -l /dev/bus/usb/004/005
    crw-rw-r-- 1 root users 189, 393 Apr 15 17:32 /dev/bus/usb/004/005
    $ sudo udevadm trigger
    $ ls -l /dev/bus/usb/004/005
    crw-rw-rw- 1 root users 189, 393 Apr 15 17:34 /dev/bus/usb/004/005
    So it appears the device is taking on GROUP="users" immediately after being plugged in, but it wont set MODE="0666" until after running udevadm trigger
    Anyone have any ideas?
    Last edited by Exershio (2015-04-15 21:38:15)

  • Map scancodes to keycodes & udev rules

    I followed the wiki here and here. My keymap file /usr/lib/udev/keymaps/chicony-kb-9805:
    0xA0 www # 158 XF86WWW
    0xA3 close # 214 XF86Close
    0xB2 f13 # 191 XF86Tools
    0x92 f14 # 192 XF86Launch5
    0xB0 f15 # 193 XF86Launch6
    0xA1 f16 # 194 XF86Launch7
    0xAE previoussong # 173 XF86AudioPrev
    0xA4 stopcd # 174 XF86AudioStop
    0xA2 playpause # 172 XF86AudioPlay
    0x99 nextsong # 171 XF86AudioNext
    0xA6 volumeup # 123 XF86AudioRaiseVolume
    0x9E volumedown # 122 XF86AudioLowerVolume
    0x97 mute # 121 XF86AudioMute
    0xA5 sleep # 150 XF86Sleep
    I found my keyboard with $ /lib/udev/findkeyboards:
    AT keyboard: input/event0
    Then the command udevadm info -a -p $(udevadm info -q path -n /dev/input/event0) returns:
    Udevadm info starts with the device specified by the devpath and then
    walks up the chain of parent devices. It prints for every device
    found, all possible attributes in the udev rules key format.
    A rule to match, can be composed by the attributes of the device
    and the attributes from one single parent device.
    looking at device '/devices/platform/i8042/serio0/input/input0/event0':
    KERNEL=="event0"
    SUBSYSTEM=="input"
    DRIVER==""
    looking at parent device '/devices/platform/i8042/serio0/input/input0':
    KERNELS=="input0"
    SUBSYSTEMS=="input"
    DRIVERS==""
    ATTRS{name}=="AT Translated Set 2 keyboard"
    ATTRS{phys}=="isa0060/serio0/input0"
    ATTRS{uniq}==""
    ATTRS{properties}=="0"
    looking at parent device '/devices/platform/i8042/serio0':
    KERNELS=="serio0"
    SUBSYSTEMS=="serio"
    DRIVERS=="atkbd"
    ATTRS{description}=="i8042 KBD port"
    ATTRS{bind_mode}=="auto"
    ATTRS{extra}=="0"
    ATTRS{force_release}=="369-370"
    ATTRS{scroll}=="0"
    ATTRS{set}=="2"
    ATTRS{softrepeat}=="0"
    ATTRS{softraw}=="1"
    ATTRS{err_count}=="0"
    looking at parent device '/devices/platform/i8042':
    KERNELS=="i8042"
    SUBSYSTEMS=="platform"
    DRIVERS=="i8042"
    looking at parent device '/devices/platform':
    KERNELS=="platform"
    SUBSYSTEMS==""
    DRIVERS==""
    I can successfully load the keymap with # /lib/udev/keymap input/event0 chicony-kb-9805 but I can't get it loaded automatically with an udev rule. When I try to apply the keymap to device '/devices/platform/i8042/serio0/input/input0/event0' , It doesn't load (/etc/udev/rules.d/98-kb-9805.rules):
    SUBSYSTEM=="input", KERNEL=="event0", RUN+="/lib/udev/keymap input/$name chicony-kb-9805"
    Nor does it load when trying to apply to device '/devices/platform/i8042/serio0/input/input0':
    SUBSYSTEMS=="input", ATTRS{name}=="AT Translated Set 2 keyboard", RUN+="/lib/udev/keymap input/$name chicony-kb-9805"
    How should the udev rule file look like for it to work? Thanks.

    I think I figured out a way to do it using udev, and I'll update the wiki page once I've tested it a bit.
    Edit: All done, so now I can disable my hal daemon (big boot speed improvement ). Unfortunately I can't uninstall yet since hal-cups-utils has only recently moved over, and some packages still depend on the ancient gnome-vfs
    Last edited by PirateJonno (2010-06-22 10:11:32)

  • [solved] /etc/udev/rules.d/10-network.rules ignored

    Hi.
    I have 4 nics (eth0, eth1, eth2, eth3) mapped to MAC addresses in  /etc/udev/rules.d/10-network.rules.
    Some months ago, I had to symlink /etc/udev/rules.d/80-net-name-slot.rules to /dev/null in order to use these static names.
    Now it doesn't work anymore (again and again and again) after a full update (kernel and I assume systemd).  The "nic-names" are completely wrong.  You call this "predictable". I call this "unpredictable". The only thing which is predictable is that after a kernel update, the network will stop working. It has been that way for months and months ... fortunately I don't update other machines anymore.
    Was this non sense really necessary?
    Anyway, if you could tell me what to do now to get my network rules applied again, I would really appreciate.
    Right now all ethX/MAC are wrong and none of them gets an IP (had to set an IP manually to post here).
    * I know what "predictable Network Interface Names" is about. I don't want this bullshit. It's much worse as it used to be. Keep it simple, folks!
    Last edited by Agnelo de la Crotche (2013-03-27 07:14:05)

    tomegun wrote:To narrow down the problem you are experiencing: What do you mean when you say that the names are "wrong"? Are they still eth0, eth1,... just in the wrong order, or are you actually seeing the "weird" new names given by udev?
    To answer this question more precisely.
    * with  /etc/udev/rules.d/80-net-name-slot.rules => /dev/nul and /etc/udev/rules.d/10-network.rules posted earlier  (in #4)
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    2: eth0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:0a:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    3: eth1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:06:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    4: eth2: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:24:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    5: eth3: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:1b:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    6: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN mode DEFAULT
    link/ether 66:64:b3:6a:26:61 brd ff:ff:ff:ff:ff:ff
    The rules are ignored.
    * after deleting   /etc/udev/rules.d/80-net-name-slot.rules
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    2: enp6s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:0a:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    3: enp6s1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:06:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    4: enp2s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:24:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    5: enp4s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:1b:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    6: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN mode DEFAULT
    link/ether a2:ee:ec:d1:65:2d brd ff:ff:ff:ff:ff:ff
    The rules don't apply.
    * with  /etc/udev/rules.d/80-net-name-slot.rules => /dev/nul and after replacing eth0, eth1, eth2, eth3 with arbitrary names net0, net1, net2, net3 in  /etc/udev/rules.d/10-network.rules
    1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    2: net1: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:24:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    3: net3: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:0a:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    4: net2: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:06:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    5: net0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT qlen 1000
    link/ether 00:1b:XX:XX:XX:XX brd ff:ff:ff:ff:ff:ff
    6: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN mode DEFAULT
    link/ether ea:63:09:b7:1b:1b brd ff:ff:ff:ff:ff:ff
    But the rules were applied in this case!
    It solved the problem described originally.  I think I was hit by the race condition after upgrating to kernel 3.8.4-1. This was actually my first 3.8 kernel.
    With kernel 3.7, the rules were working even if the devices were named eth0, eth1, etc.
    Those names don't work anymore, at least in my case.
    Further I  created this file for static ips:
    # cat /etc/systemd/system/network.service
    [Unit]
    Description=Wired Static IP Connectivity
    Wants=network.target
    Before=network.target
    BindsTo=sys-subsystem-net-devices-net0.device
    After=sys-subsystem-net-devices-net0.device
    [Service]
    Type=oneshot
    RemainAfterExit=yes
    ExecStart=/sbin/ip link set dev net0 up
    ExecStart=/sbin/ip addr add 192.168.101.9/24 dev net0
    ExecStart=/sbin/ip link set dev net1 up
    ExecStart=/sbin/ip addr add 192.168.102.9/24 dev net1
    ExecStart=/sbin/ip link set dev net2 up
    ExecStart=/sbin/ip addr add 192.168.104.9/24 dev net2
    ExecStart=/sbin/ip link set dev net3 up
    ExecStart=/sbin/ip addr add 192.168.105.9/24 dev net3
    ExecStart=/sbin/ip route add default via 192.168.101.1
    ExecStop=/sbin/ip addr flush dev net0
    ExecStop=/sbin/ip link set dev net0 down
    ExecStop=/sbin/ip addr flush dev net1
    ExecStop=/sbin/ip link set dev net1 down
    ExecStop=/sbin/ip addr flush dev net2
    ExecStop=/sbin/ip link set dev net2 down
    ExecStop=/sbin/ip addr flush dev net3
    ExecStop=/sbin/ip link set dev net3 down
    [Install]
    WantedBy=multi-user.target
    I disabled netcfg and enabled network.service.
    Problem is solved now.

Maybe you are looking for

  • PIctures and music will not come off my iPhone.

    I am trying to clean up my iPhone. I want to remove some old pictures but they will not come off. I have tried removing them from iTunes. I unclicked sync photos and did a sync but they will not remove. They are pictures I uploaded from my computer m

  • How do I move iCloud notes to ON MY MAC?

    Short story: I had to move my notes from ON MY MAC to iCloud in order to move them from a broken system to a new system. Now, I am on the new system and am trying to firgure out how to move my notes out of iCloud and keep them ON MY MAC. If I disable

  • Unable to mount samba share file for xbox 360

    I want to be able to stream music from a directory in my arch linux computer (xfce4) to my xbox using samba on a local network using ethernet cables and a router not connected to the internet. I've been able to get samba to startup and I see the fold

  • Screen freezing in Lion

    Since upgrading to Lion, I've had to hard shut down (?) my computer more each day. Is this a common problem or possible virus?

  • Slow Photo Slideshows?

    I have my 5G iPod preferences set for 2 seconds for every photo in Slideshow settings without transitions and it seems to take forever to get to the next photo. Is this common? I'm used to the faster settings on my Nano. Also, in my iPod preferences,