On Thu, Feb 23, 2017 at 9:26 AM, Dan Streetman <
<email address hidden>> wrote:
> > Checking that path [/dev/nvme0n1] and is same as link [nvme-nvme.8086-
> > 43564d44343334353030424e34303041474e-494e54454c205353445045444d4534
> 30304734-00000001]
>
> this is the wwid symlink, created by:
> SYMLINK+="disk/by-id/nvme-$attr{wwid}"
>
> > Checking that path [/dev/nvme0n1] and is same as link [nvme-
> > INTEL_SSDPEDME400G4_CVMD434500BN400AGN]
>
> this is the model/serial symlink, created by:
> ENV{ID_SERIAL}="$attr{model}_$env{ID_SERIAL_SHORT}",
> SYMLINK+="disk/by-id/nvme-$env{ID_SERIAL}"
>
What seems strange to me is that both links above completely differ in
format from those of a 'scsi' device, which is why I was comparing these to:
For example:
sdb's [wwn-0x600508b1001c29aef10ecd96f5df2342] vs nvme's [nvme-nvme.
8086-43564d44343334353030424e34303041474e-494e54454c205353445045444d4534
30304734-00000001]
or
sdb's [scsi-3600508b1001c29aef10ecd96f5df2342] vs nmve's [nvme-INTEL_
SSDPEDME400G4_CVMD434500BN400AGN].
This seems a bit inconsistent to me, for example the symlink for sdb's does
not include Model/Serial, where as they do for nvme's. That alone is a
format difference on how the symlinks are being created and which is why I
was asking, as it seems weird to me.
Thanks.
>
>
> > This is the script that gathers the block devices. I looked into it and
> it seems that it is
> > doing the right thing as it is getting the by-id link based on the
> /dev/nvme* path.
>
> def _path_to_idpath(path):
> """Searches dev_disk_byid for a device symlinked to /dev/[path]"""
> if os.path.exists(dev_disk_byid):
> for link in os.listdir(dev_disk_byid):
> if os.path.exists(path) and os.path.samefile(
> os.path.join(dev_disk_byid, link), path):
> return os.path.join(dev_disk_byid, link)
> return None
>
>
> this just searches all the symlinks in /dev/disk/by-id/ and uses the first
> one that points to the target device or partition. That's fine if you
> don't actually care about which of the symlinks you use.
>
> > The result is being rejected because the file path is currently to
> long for the field.
>
> well the max path size needs to be increased then.
>
> --
> You received this bug notification because you are subscribed to MAAS.
> https://bugs.launchpad.net/bugs/1665143
>
> Title:
> commissioning does not discover block devices on HP ProLiant DL360
> Gen9 servers
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/maas/+bug/1665143/+subscriptions
>
--
Andres Rodriguez (RoAkSoAx)
Ubuntu Server Developer
MSc. Telecom & Networking
Systems Engineer
On Thu, Feb 23, 2017 at 9:26 AM, Dan Streetman <
<email address hidden>> wrote:
> > Checking that path [/dev/nvme0n1] and is same as link [nvme-nvme.8086- 53030424e343030 41474e- 494e54454c20535 3445045444d4534 ="disk/ by-id/nvme- $attr{wwid} " 00G4_CVMD434500 BN400AGN] SERIAL} ="$attr{ model}_ $env{ID_ SERIAL_ SHORT}" , ="disk/ by-id/nvme- $env{ID_ SERIAL} "
> > 43564d443433343
> 30304734-00000001]
>
> this is the wwid symlink, created by:
> SYMLINK+
>
> > Checking that path [/dev/nvme0n1] and is same as link [nvme-
> > INTEL_SSDPEDME4
>
> this is the model/serial symlink, created by:
> ENV{ID_
> SYMLINK+
>
What seems strange to me is that both links above completely differ in
format from those of a 'scsi' device, which is why I was comparing these to:
For example:
sdb's [wwn-0x600508b1 001c29aef10ecd9 6f5df2342] vs nvme's [nvme-nvme. 3334353030424e3 4303041474e- 494e54454c20535 3445045444d4534
8086-43564d4434
30304734-00000001]
or
sdb's [scsi-3600508b1 001c29aef10ecd9 6f5df2342] vs nmve's [nvme-INTEL_ CVMD434500BN400 AGN].
SSDPEDME400G4_
This seems a bit inconsistent to me, for example the symlink for sdb's does
not include Model/Serial, where as they do for nvme's. That alone is a
format difference on how the symlinks are being created and which is why I
was asking, as it seems weird to me.
Thanks.
> idpath( path): exists( dev_disk_ byid): dev_disk_ byid): exists( path) and os.path.samefile( join(dev_ disk_byid, link), path): join(dev_ disk_byid, link) /bugs.launchpad .net/bugs/ 1665143 /bugs.launchpad .net/maas/ +bug/1665143/ +subscriptions
>
> > This is the script that gathers the block devices. I looked into it and
> it seems that it is
> > doing the right thing as it is getting the by-id link based on the
> /dev/nvme* path.
>
> def _path_to_
> """Searches dev_disk_byid for a device symlinked to /dev/[path]"""
> if os.path.
> for link in os.listdir(
> if os.path.
> os.path.
> return os.path.
> return None
>
>
> this just searches all the symlinks in /dev/disk/by-id/ and uses the first
> one that points to the target device or partition. That's fine if you
> don't actually care about which of the symlinks you use.
>
> > The result is being rejected because the file path is currently to
> long for the field.
>
> well the max path size needs to be increased then.
>
> --
> You received this bug notification because you are subscribed to MAAS.
> https:/
>
> Title:
> commissioning does not discover block devices on HP ProLiant DL360
> Gen9 servers
>
> To manage notifications about this bug go to:
> https:/
>
--
Andres Rodriguez (RoAkSoAx)
Ubuntu Server Developer
MSc. Telecom & Networking
Systems Engineer