Pcornel
Storage · SAN

LUN

Cheat sheet · https://pcornel.dk/topic.php?topic=4069

Back to the Topic

Answer

A LUN number identifies a logical unit within a target context, while persistent identifiers such as serial/WWID-style values are used by hosts to recognize the same underlying device across paths. Arrays map that logical unit to selected initiators.

Remember

  • LUN number ≠ globally unique identifier.
  • Same capacity ≠ same LUN.
  • Multiple path devices with one persistent ID ≠ duplicate storage.
  • Visible LUN ≠ safe-to-format or mount.

First checks

  • lsscsi -s — LUN sizes
  • sg_readcap /dev/sdX — capacity
  • echo 1 > /sys/block/sdX/device/rescan — rescan after resize

Verify in this order

array volume → LUN id → host disk

Where it usually breaks

First mismatch in initiator → link/fabric/network → session/login → target port → LUN/namespace presentation → multipath → block consumer; preserve identity/pre-state before mutation.

SAN → LUN SAN/iSCSI map

SAN/iSCSI boundaryWhat to verifyProof limit
Identity / presentationInitiator + target identity, portal/fabric path, LUN stable ID and mappingDiscovery or login alone does not prove correct storage ownership
Path / transportLink/VLAN/IP/TCP or fabric state, path independence, session/path errors and multipath groupingOne reachable path does not prove resilience or backend health
Failure boundaryA LUN visible on the host proves presentation of a block object; it does not prove its identity by capacity alone, filesystem safety or redundancy.Correlate host, network/fabric and target/array evidence for the same time window
AcceptanceHealthy evidence: array and host agree on persistent identity/capacity, all expected paths group to one device and upper ownership is documented.Close only after the original block workload and upper-layer consistency check succeeds

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=4069

Confirmation

Confirm action

Continue?