LUN Detached State Persists or Spreads via Host Profiles in ESXi
search cancel

LUN Detached State Persists or Spreads via Host Profiles in ESXi

book

Article ID: 438523

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

You observe that one or more LUNs report an Operational State of "Detached" across multiple ESXi hosts in a cluster. This persistent software-level state typically follows a transient All-Paths-Down (APD) event or administrative action. Although SAN zoning is correct, standard HBA rescans and host reboots do not restore access. Log analysis reveals the status administratively off with the specific event code esx.problem.scsi.device.state.off

  • One or more LUNs appear with an Operational State of "Detached" on multiple ESXi hosts in a cluster. 
  • SAN zoning is correct, however standard HBA rescans and host reboots do not restore access.
  • Log analysis reveals the status administratively off with the following messages in vmkernel.log or vobd.log:
    • Device <NAA_ID> has been turned off administratively.
    • esx.problem.scsi.device.state.off

Environment

ESXi (All versions)
External storage attached

Cause

The ESXi kernel applies a persistent "off" attribute to the storage device after an administrator manually detaches the LUN from the ESXi host. This software-level flag prevents data corruption during transient pathing issues but remains active even after physical connectivity is restored. In ESXi 8.x, this state persists through reboots and rescans until you manually clear it.

Resolution

To restore access to the storage environment, you must first clear the administrative block on the device and then manually mount the file system.

  1. Re-attach the Storage Device

    • In the vSphere Client, navigate to Host > Configure > Storage > Storage Devices.
    • Select the affected LUN (e.g., naa.################).
    • Click the Attach icon.
    • Alternatively, you can use the following ESXCLI command via SSH: esxcli storage core device set --state=on -d <NAA_ID>
  2. Manually Mount the VMFS Datastore

    • Navigate to Host > Configure > Storage > Datastores.
    • Locate the datastore associated with the LUN (it may appear as inactive).
    • Click Mount Datastore.
    • Verification: You ensure the datastore status changes to Online and is accessible across all cluster members.

Additional Information

KB 414204: LUNs are not attaching to all the hosts

KB 425938: Troubleshooting "LUN Detached by User"