Powering on the virtual machine fails with the error: Unable to open SCSI device '/vmfs/devices/genscsi/' (scsiX:Y)
search cancel

Powering on the virtual machine fails with the error: Unable to open SCSI device '/vmfs/devices/genscsi/' (scsiX:Y)

book

Article ID: 310136

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

Symptoms:

Summary

A virtual machine fails to power on with the error:

Module DevicePowerOn power on failed.
Unable to open SCSI device <device> (scsiX:Y): <Reason>

Example

Module DevicePowerOn power on failed.
Unable to open SCSI device '/vmfs/devices/genscsi/mpx.vmhba32:C0:T0:L0' (scsi0:1): Could not find the file.

Module DevicePowerOn power on failed.
Unable to open SCSI device '/dev/genscsi/naa.0123456789' (scsi0:2): Failed to lock the file.

Impact

The virtual machine cannot be powered on.


Environment

VMware ESX 4.1.x
VMware vSphere ESXi 5.0
VMware ESX Server 3.5.x
VMware vSphere ESXi 5.1
VMware ESX 4.0.x

Resolution

Resolving the issue when you experience the Could not find the file error

The Could not find the file error indicates that you have configured the virtual machine to use a host SCSI device in the passthrough (generic) mode and then have either moved the virtual machine or changed the hardware configuration of the host or manually edited the virtual machine configuration file, so that the SCSI device no longer exists.

To workaround this issue when the virtual machine is powered off, using the vSphere client, delete the SCSI device entry from the virtual machine configuration.
 
To delete the SCSI device entry from the virtual machine configuration:
  1. In the vSphere Client, click Edit virtual machine settings.
  2. Select the SCSI device to be deleted and click Remove.
  3. Click OK.
  4. Add the SCSI device back to the virtual machine, if required.

    To add the SCSI device back to the virtual machine:
     
    1. Click Edit virtual machine settings > Add > SCSI device.
    2. Select the SCSI device to be added and click OK.
       
  5. Power on the virtual machine.
  6. Verify that all virtual disks have associated SCSI device numbers associated
To workaround this issue when the virtual machine is in a suspended state, manually edit the .vmx file of the virtual machine and remove the entry corresponding to the SCSI device or modify the entry to point to the correct SCSI device.
 
To manually edit the .vmx file:
 
Note: For more information on editing the .vmx file, see Tips for editing a .vmx file (1714 ).
  1. Locate the virtual machine configuration file (.vmx).
  2. Open the .vmx file using a text editor.
  3. Find the entries for the SCSI device. For example:

    scsi0:9.present = "TRUE"
    scsi0:9.deviceType = "scsi-passthru"
    scsi0:9.fileName = "/vmfs/devices/genscsi/mpx.vmhba32:C0:T0:L0"

     
  4. To remove the SCSI device, delete these entries from the .vmx file.

    Caution: If you remove the SCSI device when the virtual machine is in a suspended state, the virtual machine may experience a kernel panic (BSOD). Use this option only when there is no other way to reconnect the SCSI device.
     
  5. To point to the correct SCSI device, modify the fileName entry to point to the correct filename.
  6. Power on the virtual machine.

Resolving the issue when you experience the Failed to lock the file error

The Failed to lock the file error indicates that some other virtual machine is already using this SCSI device. Sharing of such SCSI devices among virtual machines is not supported.

To workaround this issue when your virtual machine does not need access to this SCSI device:
  1. Using the vSphere client, edit the virtual machine's settings and remove the SCSI device entry.
  2. Power on the virtual machine.
To workaround this issue when your virtual machine needs access to this SCSI device, ensure that the other virtual machine that is pointing to the SCSI device is powered off when using your virtual machine.

 


Additional Information

仮想マシンのパワーオンが次のエラーで失敗する: SCSI デバイス「/vmfs/devices/genscsi/<deviceName>」 (scsiX:Y) を開くことができません
打开虚拟机电源失败并显示错误:无法打开 SCSI 设备“/vmfs/devices/genscsi/”(scsiX:Y)