From: Patrick Mansfield <patmans@us.ibm.com>
To: linux-hotplug@vger.kernel.org
Subject: Re: Problems using scsi_id with udevstart
Date: Tue, 05 Oct 2004 23:53:37 +0000 [thread overview]
Message-ID: <20041005235337.GA18153@beaverton.ibm.com> (raw)
In-Reply-To: <1097019226.2300.38.camel@bluto.andrew>
I don't know much about how udevstart operates. Anyway ...
On Tue, Oct 05, 2004 at 05:33:46PM -0600, Andrew Patterson wrote:
> Hi,
>
> I added the following udev rule to make human-readable device file names
> for my SCSI disks:
>
> BUS="scsi", KERNEL="sd*", PROGRAM="scsi_id", NAME="scsi_disks/%c-%b",
> SYMLINK="%k"
Interesting ... I was thinking of the opposite type of rule to match some
of the SUSE device naming, like:
BUS="scsi", KERNEL="sd*", PROGRAM="scsi_id", NAME="%k" SYMLINK="scsi_disks/%c-%b",
> When I run udevstart, I get the following errors in the logfile:
>
> Oct 5 17:25:17 natasha udevstart: PROGRAM execution of 'scsi_id' failed
> Oct 5 17:25:17 natasha udevstart: creating device node '/dev/sdy2'
> Oct 5 17:25:17 natasha udevstart: PROGRAM execution of 'scsi_id' failed
> Oct 5 17:25:17 natasha udevstart: creating device node '/dev/sdz'
>
> scsi_id is failing because no parameters are being passed to it, and I
> think DEVPATH is also not being set appropriately. Here is debug
> output:
>
> get_sysfs_device: device 2:0:0:0 is registered with bus 'scsi'
> namedev_name_device: sysfs_device-
> >path='/sys/devices/pci0000:20/0000:20:01.0/host2/2:0:0:0'
> namedev_name_device: sysfs_device->bus_id='2:0:0:0'
> namedev_name_device: sysfs_device->bus='scsi'
> wait_for_device_to_initialize: looking for file 'vendor' on bus 'scsi'
> namedev_name_device: class_dev->name = 'sda'
> namedev_name_device: udev->kernel_name = 'sda'
> namedev_name_device: kernel_number=''
> namedev_name_device: process rule
> match_rule: check for BUS dev->bus='scsi' sysfs_device->bus='scsi'
> match_rule: BUS matches
> match_rule: check PROGRAM
> execute_program:
>
> execute_program: result len 256 too short
> execute_program: result is ' matching
The above indicates udev thinks the output of scsi_id is too long.
[elm3b79 udev-bk]$ grep NAME_SIZE *.[hc] udev.h | grep define
logging.h:#define LOGNAME_SIZE 42
udev.h:#define NAME_SIZE 256
udev.h:#define NAME_SIZE 256
Greg or Kay, can you verify the above? Should we / can we increase
NAME_SIZE?
Andrew - what does running scsi_id from the command line return for the
device? Like this:
scsi_id -s /block/sdN
-- Patrick Mansfield
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
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
next prev parent reply other threads:[~2004-10-05 23:53 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-05 23:33 Problems using scsi_id with udevstart Andrew Patterson
2004-10-05 23:53 ` Patrick Mansfield [this message]
2004-10-05 23:55 ` Kay Sievers
2004-10-06 16:20 ` Andrew Patterson
2004-10-06 16:26 ` Andrew Patterson
2004-10-06 16:44 ` Kay Sievers
2004-10-06 16:59 ` Patrick Mansfield
2004-10-06 17:33 ` Andrew Patterson
2004-10-06 18:07 ` Kay Sievers
2004-10-06 18:42 ` Andrew Patterson
2004-10-06 19:13 ` Kay Sievers
2004-10-06 21:22 ` Andrew Patterson
2004-10-06 21:39 ` Kay Sievers
2004-10-06 22:24 ` Greg KH
2004-10-06 22:28 ` Andrew Patterson
2004-10-06 23:08 ` Kay Sievers
2004-10-06 23:19 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20041005235337.GA18153@beaverton.ibm.com \
--to=patmans@us.ibm.com \
--cc=linux-hotplug@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).