Bug#514976: update-grub cannot locate /boot on /dev/sdag1, even when device.map is correct (worked in Etch)

Chris Samuel csamuel at vpac.org
Tue Mar 31 22:24:45 UTC 2009


----- "Robert Millan" <rmh at aybabtu.com> wrote:

Hi Robert,

> We need some naming spec on how are disks numbered after /dev/sdz.  I
> can guess, but that's not good enough, some authoritative reference
> would be necessary.

There is a function in the kernel in drivers/scsi/sd.c
called sd_format_disk_name() which does this and I suspect
is therefore the definitive reference.

Its comments say:

/**
 *      sd_format_disk_name - format disk name
 *      @prefix: name prefix - ie. "sd" for SCSI disks
 *      @index: index of the disk to format name for
 *      @buf: output buffer
 *      @buflen: length of the output buffer
 *
 *      SCSI disk names starts at sda.  The 26th device is sdz and the
 *      27th is sdaa.  The last one for two lettered suffix is sdzz
 *      which is followed by sdaaa.
 *
 *      This is basically 26 base counting with one extra 'nil' entry
 *      at the beggining from the second digit on and can be
 *      determined using similar method as 26 base conversion with the
 *      index shifted -1 after each digit is computed.
 *
 *      CONTEXT:
 *      Don't care.
 *
 *      RETURNS:
 *      0 on success, -errno on failure.
 */


How is that ?

cheers,
Chris
-- 
Christopher Samuel - (03) 9925 4751 - Systems Manager
 The Victorian Partnership for Advanced Computing
 P.O. Box 201, Carlton South, VIC 3053, Australia
VPAC is a not-for-profit Registered Research Agency





More information about the Pkg-grub-devel mailing list