From mboxrd@z Thu Jan 1 00:00:00 1970 From: dark_mail@gmx.net Date: Wed, 17 Jan 2007 00:34:18 +0000 Subject: invalid SUBSYSTEMS operation in rules.d file Message-Id: <45AD6F0A.6030100@gmx.net> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable To: linux-hotplug@vger.kernel.org I'm using uudev 103 on a gentoo system with a 2.6.19 kernel. I want my system to automatically create a device node for my usbstick, with two partitions. So I created the following 06-usbsticks.rules file: [code] #BUS=3D"usb", KERNEL=3D"sd*", SYSFS{serial}=3D"0000000000077D", NAME=3D"%k", SYMLINK=3D"blackstick%n", GROUP=3D"users" BUS=3D"usb", KERNEL=3D"sd*", SYSFS{serial}=3D"L82020506180008560", NAME=3D"= %k", NAME=3D"printer%n", GROUP=3D"users" DRIVERS=3D"usb", ATTRS{serial}=3D"0000000000077D", ATTRS{product}=3D"USB Mass Storage Device", NAME=3D"blackstick%n", GROUP=3D"users", OPTIONS=3D"last_rule" [/code] The first line (actually they are three lines, separated by an empty line) is the old rule I used that didn't worl after an upgrade of udev. The second one is meant for the cardreader within my printer, and the last rule is supposed to create a device node /dev/blackstick" when the stick is inserted, along with two nodes for the actual partitions. I had an additional key SUBSYSTEMS=3D"usb", but it gave me the following error upon start of udev: udevd[457]: add_to_rules: invalid SUBSYSTEMS operation udevd[457]: add_to_rules: invalid rule '/etc/udev/rules.d/06-usbsticks.rules:3' But even when this key is removed udev complains, and of course doesn't create the appropriate device node. "udevinfo -a -p /sys/block/sda" returns: [code] Udevinfo 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 '/block/sda': KERNEL=3D"sda" SUBSYSTEM=3D"block" DRIVER=3D"" ATTR{stat}=3D" 1 0 8 72 0 0 0 0 0 72 72" ATTR{size}=3D"4096000" ATTR{removable}=3D"1" ATTR{range}=3D"16" ATTR{dev}=3D"8:0" looking at parent device '/devices/pci0000:00/0000:00:02.3/usb2/2-2/2-2:1.0/host0/target0:0:0/0:0:0:= 0': KERNELS=3D"0:0:0:0" SUBSYSTEMS=3D"scsi" DRIVERS=3D"sd" ATTRS{ioerr_cnt}=3D"0x0" ATTRS{iodone_cnt}=3D"0x9" ATTRS{iorequest_cnt}=3D"0x9" ATTRS{iocounterbits}=3D"32" ATTRS{timeout}=3D"30" ATTRS{state}=3D"running" ATTRS{rev}=3D"0.00" ATTRS{model}=3D"2006-06-22 " ATTRS{vendor}=3D"TinyDisk" ATTRS{scsi_level}=3D"3" ATTRS{type}=3D"0" ATTRS{queue_type}=3D"none" ATTRS{queue_depth}=3D"1" ATTRS{device_blocked}=3D"0" ATTRS{max_sectors}=3D"240" looking at parent device '/devices/pci0000:00/0000:00:02.3/usb2/2-2/2-2:1.0/host0/target0:0:0': KERNELS=3D"target0:0:0" SUBSYSTEMS=3D"" DRIVERS=3D"" looking at parent device '/devices/pci0000:00/0000:00:02.3/usb2/2-2/2-2:1.0/host0': KERNELS=3D"host0" SUBSYSTEMS=3D"" DRIVERS=3D"" looking at parent device '/devices/pci0000:00/0000:00:02.3/usb2/2-2/2-2:1.0': KERNELS=3D"2-2:1.0" SUBSYSTEMS=3D"usb" DRIVERS=3D"usb-storage" ATTRS{modalias}=3D"usb:v0457p0151d0100dc00dsc00dp00ic08isc06ip50" ATTRS{bInterfaceProtocol}=3D"50" ATTRS{bInterfaceSubClass}=3D"06" ATTRS{bInterfaceClass}=3D"08" ATTRS{bNumEndpoints}=3D"03" ATTRS{bAlternateSetting}=3D" 0" ATTRS{bInterfaceNumber}=3D"00" looking at parent device '/devices/pci0000:00/0000:00:02.3/usb2/2-2': KERNELS=3D"2-2" SUBSYSTEMS=3D"usb" DRIVERS=3D"usb" ATTRS{serial}=3D"0000000000077D" ATTRS{product}=3D"USB Mass Storage Device" ATTRS{maxchild}=3D"0" ATTRS{version}=3D" 2.00" ATTRS{devnum}=3D"2" ATTRS{speed}=3D"12" ATTRS{bMaxPacketSize0}=3D"64" ATTRS{bNumConfigurations}=3D"1" ATTRS{bDeviceProtocol}=3D"00" ATTRS{bDeviceSubClass}=3D"00" ATTRS{bDeviceClass}=3D"00" ATTRS{bcdDevice}=3D"0100" ATTRS{idProduct}=3D"0151" ATTRS{idVendor}=3D"0457" ATTRS{bMaxPower}=3D" 98mA" ATTRS{bmAttributes}=3D"80" ATTRS{bConfigurationValue}=3D"1" ATTRS{bNumInterfaces}=3D" 1" ATTRS{configuration}=3D"" looking at parent device '/devices/pci0000:00/0000:00:02.3/usb2': KERNELS=3D"usb2" SUBSYSTEMS=3D"usb" DRIVERS=3D"usb" ATTRS{serial}=3D"0000:00:02.3" ATTRS{product}=3D"OHCI Host Controller" ATTRS{manufacturer}=3D"Linux 2.6.19 ohci_hcd" ATTRS{maxchild}=3D"3" ATTRS{version}=3D" 1.10" ATTRS{devnum}=3D"1" ATTRS{speed}=3D"12" ATTRS{bMaxPacketSize0}=3D"64" ATTRS{bNumConfigurations}=3D"1" ATTRS{bDeviceProtocol}=3D"00" ATTRS{bDeviceSubClass}=3D"00" ATTRS{bDeviceClass}=3D"09" ATTRS{bcdDevice}=3D"0206" ATTRS{idProduct}=3D"0000" ATTRS{idVendor}=3D"0000" ATTRS{bMaxPower}=3D" 0mA" ATTRS{bmAttributes}=3D"e0" ATTRS{bConfigurationValue}=3D"1" ATTRS{bNumInterfaces}=3D" 1" ATTRS{configuration}=3D"" looking at parent device '/devices/pci0000:00/0000:00:02.3': KERNELS=3D"0000:00:02.3" SUBSYSTEMS=3D"pci" DRIVERS=3D"ohci_hcd" ATTRS{msi_bus}=3D"" ATTRS{broken_parity_status}=3D"0" ATTRS{enable}=3D"1" ATTRS{modalias}=3D"pci:v00001039d00007001sv00001019sd00000A14bc0Csc03i1= 0" ATTRS{local_cpus}=3D"1" ATTRS{irq}=3D"11" ATTRS{class}=3D"0x0c0310" ATTRS{subsystem_device}=3D"0x0a14" ATTRS{subsystem_vendor}=3D"0x1019" ATTRS{device}=3D"0x7001" ATTRS{vendor}=3D"0x1039" looking at parent device '/devices/pci0000:00': KERNELS=3D"pci0000:00" SUBSYSTEMS=3D"" DRIVERS=3D"" [/code] According to the manuals I read so far my rule should work, but somehow it doesn't. Can anybody tell me what's wrong here? ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=DEVD= EV _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net Linux-hotplug-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel