From: Date: Mon, 08 Oct 2007 04:10:50 +0000 Subject: Unable to run a user program on usb device connection Message-Id: <904273.49832.qm@web51611.mail.re2.yahoo.com> List-Id: References: <527409.71590.qm@web51603.mail.re2.yahoo.com> In-Reply-To: <527409.71590.qm@web51603.mail.re2.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: quoted-printable To: linux-hotplug@vger.kernel.org Hi, I'm a newbie to Linux hotplug sub-system. Please excuse me if the question is very basic. I want to hook a user space application with the hot plug sub-system in such a way that the application is executed on attaching a specific USB device. I've explained what all I tried below, please let me know where I'm going wrong. My linux kernel version is 2.6.10 and it uses the =93udev=94 mechanism to support hot plug. Our application should be executed when a device with a specific vendor id and product id is plugged in the USB bus. I=92ve enabled the hot plug support in the kernel; in fact by default CONFIG_HOTPLUG was enabled. I included a test.rules file in the /etc/udev/rules.d/ directory in which I have included the above mentioned vendor id, product id and in the PROGRAM parameter the name of the application to be run. To start with, this program is just a shell script that prints =93Hello World=94 on the console. After this, when we plug in the above mentioned device I=92m sure that the kernel has detected it because I=92m seeing the device=92s information in /proc/bus/usb/devices. But our shell script is not getting called at all. Can some one let me know what I'm missing here? The test.rules file contains the following line only ATTR{idVendor}=3D"0451", ATTR{idProduct}=3D"97fb", SYMLINK+=3D"hello-%k", MODE=3D"666", PROGRAM=3D"/home/shankar/usb_disp.sh" Please help me in getting this sorted out. Thanks in Advance, Shankar =20 =20 ___________________________________________________________________________= _________ Be a better Heartthrob. Get better relationship answers from someone who kn= ows. Yahoo! Answers - Check it out.=20 http://answers.yahoo.com/dir/?link=3Dlist&sid96545433 ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ 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