Subject: Re: Another changer, another changer problem
To: Christoph Badura <bad@ora.de>
From: C Kane <ckane@best.com>
List: current-users
Date: 10/01/1998 18:02:04
Christoph Badura writes:
>woods@most.weird.com (Greg A. Woods) writes:
>
>>The former two
>>are probably not worthy of use, but the latter still is though I'll
>>probably keep it in my AT&T 3B2 where it has full OS support, including
>>explict device naming such as "c0t0d0s0" which means "controller 0,
>>target 0, disk(LUN) 0, slice 0" (something I wish NetBSD had).
>
>Excuse me?
>
>	sd0 at scsibus0 target 0 lun 0
>
>in the kernel config file works just fine.  Noone is preventing you from
>changing to /dev and doing "ln sd0a c0t0d0s0" either.

Using a link misses the point.  I want nailed-down names so device-
renaming does not occur on bootup.

Another thing is that if we have a limit of 8 bits for the minor
number, there can be only 32 nailed-down devices.

Also, on those OSs which already nail down the device names,
you never need to rescan if you powerup or powerdown a device (which
isn't recommended by spec, I know, but it does come in awfully handy to
attach a tape drive to a system which doesn't usually have one),
and those systems use the same name regardless of if the device is
a fixed drive, removable drive, tape, CD, printer, or whatever else
it might be.

I'm used to HP-UX, which on bootup creates the needed device files for
the SCSI devices it finds.  Currently I have:
brw-r-----   1 bin        sys         31 0x005000 Sep 14 11:33 c0t5d0
brw-r-----   1 bin        sys         31 0x006000 Sep 29 11:07 c0t6d0
brw-r-----   1 bin        sys         31 0x012000 Sep 14 11:33 c1t2d0
The fixed disks are c0t5d0 and c0t6d0, and c1t2d0 is a SCSI floppy.
This is a different naming scheme than AT&T mentioned earlier.
The nibbles seem to be cct??b where cc is controller, t is target,
and b are control bits (I've seen them used only for tapes to indicate
no-rewind, for example).  I'm not sure if the "d0" corresponds to one
or two nibbles -- never seen it used.  HP seems to use 24 bits for the
minor number.

If I added a tape drive, I could manually create c1t3d0 (for example;
this would not go away even if the tape were not present on next
reboot), and immediately access the tape device.

HP-UX includes "ioscan" which will find all attached hardware for which
drivers are in the kernel, whether or not they have device files.

-- Chuck