解決:ESX 4.1 Host 無法開機 (esxconsole.vmdk missed)

    版本為 12:07, 15 Nov 2024

    到這個版本。

    返回到 版本存檔.

    查閱目前版本

    說明

    一台 VMware ESX 4.1 主機,經過一次歲修停機後,再次開機時,停在如下的訊息:

     * vsd-mount .................................................... [Failed]

    You have entered the recovery shell. The situation you are in may be recoverable.
    If you are able to fix this situation the boot process will continue normally after you exit this terminal.
    /Bin/SH: cant access TTY job control turned off

    官方教學: ESX fails to boot when the disk containing the datastore with esxconsole.vmdk is detected as a snapshot (1012142)

    確認原因

    1. 檢查 /root/messages.log

    # tail -50 /root/messages
    

    錯誤顯示檔案 /vmfs/volumes/4d9eab94-5b35e5a5.../esxconsole-4d9eaabc-6870-.../esxconsole.vmdk 找不到

    2. 檢查 /etc/vmware/esx.conf,確認 esxconsole.vmdk 的設定路徑

    # grep -i cosvmdk /etc/vmware/esx.conf
    

    /boot/cosvmdk="/vmfs/volumes/4d9eab94-5b35e5a5.../esxconsole-4d9eaabc-6870-.../esxconsole.vmdk"

    3. 搜尋檔案 esxconsole.vmdk,確認檔案已經遺失

    find /vmfs/volumes/ -name esxconsole.vmdk
    

    在同一個目錄 /vmfs/volumes/4d9eab94-5b35e5a5.../esxconsole-4d9eaabc-6870-.../,必須有 esxconsole-flat.vmdk 的存在,這是實際的 esxconsole 虛擬系統檔,而 esxconsole.vmdk 是虛擬機的定義檔,少了這個,虛擬機就無法被開啟。

    解決方案

    由於 ESX 開機所需要的 esxconsole 虛擬系統無法被開啟,原因是該虛擬系統的定義檔 esxconsole.vmdk 遺失,解決方式是

    1. 重新偵測及註冊 VMFS volume
    2. 重建 esxconsole.vmdk
    重新偵測 VMFS volume

    註: 此法也適用於 ESX 重開機後,發生找不到 VMS Volume 的狀況

    1. Provide the necessary credentials to access the busy box.
    2. Run this command to enable automatic resignaturing of datastores on the host:

      # esxcfg-advcfg -s 1 /LVM/EnableResignature

      You must get output similar to:

      Value of EnableResignature is 1 .

      Note: If the root is mounted as read-only, run the mount -o remount / command to remount the volumes so that they are in a writable state.
       
    3. Run this command to unload the VMFS drivers:

      # vmkload_mod -u vmfs3
       
    4. Run this command to load the VMFS drivers:

      # vmkload_mod vmfs3
       
    5. Run this command to detect new VMFS volumes and resignature the volume:

      # vmkfstools -V
       
    6. Disable resignaturing on the host again (change its value back to 0):

      # esxcfg-advcfg -s 0 /LVM/EnableResignature
       
    7. Run this command to identify the full path of the service console file:

      # find /vmfs/volumes/ -name esxconsole.vmdk

      The output appears similar to:

      /vmfs/volumes/4a14d968-88bf7161-700f-00145ef48f76/esxconsole-4a14d906-2f96-7956-7284-00145ef48f74/esxconsole.vmdk

    Note:

    如果 esxconsole.vmdk 檔案不存在,請繼續以下步驟: 重建虛擬系統定義檔 esxconsole.vmdk。

    重建虛擬系統定義檔 esxconsole.vmdk

    請參閱: 重建 VM 的定義檔 (myvm.vmdk)

    Powered by MindTouch Core