Re: generating a Linux WWN?

Douglas Gilbert
2007-10-03T15:00:46Z

Jeff Garzik wrote:
> Luben Tuikov wrote:
>> --- Jeff Garzik <jeff@garzik.org> wrote:
>>> The admin will have the option to auto-generate a WWN, should they so
>>> desire.
>
>> What does that mean? "auto-generate"? By whom?
>
> The admin tells the kernel module to auto-generate a WWN, and the kernel
> module happily obliges.
>
> The generation algorithm is whatever makes people happy. I would
> probably pick a fixed prefix like 0x6C 0x69 0x63 ("lin"), something that
> doesn't conflict with IEEE org ids for a long time to come. Then,
> get_random_bytes() or hash some useful machine characteristics for the
> rest of the bytes.
>
>
>> What if they don't "auto-generate" (whatever that means)?
>
> Well, you either have a WWN or you don't :)

Jeff,
It is not quite black and white. As I tried to point
out, when a SAS HBA is run in target mode, there is
a good chance there aren't _enough_ unique SAS addresses
allocated by the manufacturer.

There should be naa-5 addresses for the ports, it is
the target device address and 0 or more lu addresses that
may need to be generated.

Doug Gilbert