Translate

2/6/10

VMWARE-Procedimiento de recuperación tabla de particiones.

Recovering a lost partition table on a VMFS volume

Details


  • VMFS datastore is missing.   
  • Solution

The following sections guide you through recreating the partition table of a LUN that has a VMFS datastore. Prior to implementing these steps, become familiar with how VMware ESX identifies disks and LUNs. For more information, see Identifying disks when working with VMware ESX (1014953).
Warnings:
  • The steps outlined here are potentially hazardous for your environment if they are not followed exactly. If you are not comfortable performing these steps, contact VMware Technical Support and work with them to resolve the issue. For more information, see How to Submit a Support Request.
  • If a LUN does not have a valid partition table, it may not meet the criteria for VirtualCenter’s storage filtering safeguards. Refer to your storage configuration or SAN administrator before making any changes such as create a VMFS datastore or an RDM, add an extent, or increase a VMFS datastore.
ESX 2.x
To recreate the partition table:
  1. Log in to the ESX host service console.
  2. Type vmkpcidivy -q vmhba_devs and press Enter to get list of Linux devices and their VMkernel name.
  3. Type fdisk -l /dev/sdX and press Enter to confirm that the partition is no longer here.
  4. Recreate the partition table:


    1. Start fdisk with the command fdisk /dev/sdX and press Enter.
    2. Create the partition:


      1. Type n and press Enter to create a new partition.
      2. Type p and press Enter to create a primary partition.
      3. Type 1 and press Enter to create the first partition.
      4. Press Enter to keep the default value.
      5. Press Enter to keep the default value.
    3. Change the partition to type fb (VMFS):


      1. Type t and press Enter to change the type of partition.
      2. Type fb and press Enter to set the partition as VMFS.
    4. Type w and press Enter to save.

      Note
      : This command exits fdisk and returns you to the command prompt.
       

  5. Type vmkfstools -V and press Enter to discover the VMFS.

ESX 3.x

To recreate the partition table:
  1. Log in to the ESX host service console.
  2. Type esxcfg-vmhbadevs -q and press Enter to get a list of Linux devices and their VMkernel name.
  3. Type fdisk -l /dev/sdX and press Enter to confirm that the partition is no longer here.
  4. Recreate the partition table:


    1. Start fdisk with the command fdisk /dev/sdX and press Enter.
    2. Create the partition:


      1. Press n and press Enter to create a new partition.
      2. Press p and press Enter to select that this is a primary partition.
      3. Press 1 and press Enter to make the first partition.
      4. Press Enter to keep the default value.
      5. Press Enter again to keep the default value.

    3. Change the partition to type fb (VMFS):


      1. Press t and press Enter.
      2. Press 1 and press Enter.
      3. Enter fb and press Enter.

    4. Align the partition to sector 128. Do not execute the realign procedure if the volume was originally created from the ESX command line or if the volume was upgraded from an ESX 2.x as the starting sector is 63, which is the default when using fdisk.

      If the VMFS volume was originally created using VMware Infrastructure Client, the beginning of the partition was set to sector 128 and the alignment is required to match the beginning of the partition to where the volume used to be.

      Note: Looking at other VMFS partitions with fdisk -lu in the same environment reveals if the current practice is to align the partition start to block 128 or not.




      1. Type x and press Enter to move to expert mode.
      2. Type b and press Enter to change the beginning of the partition.
      3. Type 1 and press Enter to select the first partition.
      4. Type 128 and press Enter to move to the block 128 the beginning of the partition.

    5. Type w and press Enter to save.
      Note: This exits fdisk and returns you to the command prompt.
  5. Type vmkfstools -V and press Enter to discover the VMFS.
Note: This procedure may not work on VMFS volumes that are participating in a spanned set (extents). Contact VMware Technical Support and work with them to resolve the issue.

ESX 4.x

  1. Log in to the ESX host service console.
  2. Run the command:

    esxcfg-scsidevs -c
    The output appears similar to:
    Device UID                            Device Type   Console Device                                Size     Plugin Display Name
    mpx.vmhba0:C0:T0:L0                   Direct-Access /dev/sdb                                      139890MB NMP    Local ServeRA Disk (mpx.vmhba0:C0:T0:L0)
    mpx.vmhba3:C0:T0:L0                   CD-ROM        /dev/sr0                                      0MB      NMP    Local HL-DT-ST CD-ROM (mpx.vmhba3:C0:T0:L0)
    naa.5005076c02045649                  Enclosure Svc Dev/vmfs/devices/genscsi/naa.5005076c02045649 0MB      NMP    Local IBM Enclosure Svc Dev (naa.5005076c02045649)
    naa.600601606a20160084afee93bce8de11  Direct-Access /dev/sdf                                      153600MB NMP    DGC Fibre Channel Disk (naa.600601606a20160084afee93bce8de11)
    naa.60060160b4111600624c5b749c7edd11  Direct-Access /dev/sda                                      153600MB NMP    DGC Fibre Channel Disk
    (naa.60060160b4111600624c5b749c7edd11)
    naa.6090a038f0cd4e5bdaa8248e6856d4fe  Direct-Access /dev/sde                                      256005MB NMP    EQLOGIC iSCSI Disk
    (naa.6090a038f0cd4e5bdaa8248e6856d4fe)
    naa.6090a038f0cd6e5165a344460000909b  Direct-Access /dev/sdd                                      153600MB NMP    EQLOGIC iSCSI Disk
    (naa.6090a038f0cd6e5165a344460000909b)

     
  3. Identify the disk in question, and make note of the value under the Console Device column.
  4. Run the command:
    fdisk -l <dev>
    Where <dev> is the value recorded in step 2.

    The output appears similar to
    :
    Disk /dev/sde: 268.4 GB, 268440698880 bytes
    255 heads, 63 sectors/track, 32636 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot Start End Blocks Id System
    /dev/sde1 1 32636 262148606 fb VMware VMFS

     
  5. Start fdisk with the command following command and press Enter.
    fdisk /dev/sdX
  6. Create the partition:




    1. Press n and press Enter to create a new partition.
    2. Press p and press Enter to select that this is a primary partition.
    3. Press 1 and press Enter to make the first partition.
    4. Press Enter to keep the default value.
    5. Press Enter again to keep the default value.
    6. Change the partition to type fb (VMFS):




      1. Press t and press Enter.
      2. Press 1 and press Enter.
      3. Enter fb and press Enter.
         
  7. Align the partition to sector 128.

    Caution: Do not execute the realign procedure if the volume was originally created from the ESX command line or if the volume was upgraded from ESX 2.x as the starting sector is 63, which is the default when using fdisk.If the VMFS volume was originally created using VMware Infrastructure Client, the beginning of the partition was set to sector 128 and the alignment is required to match the beginning of the partition to where the volume used to be.

    Note: Looking at other VMFS partitions with fdisk -lu in the same environment reveals if the current practice is to align the partition start to block 128 or not.





    1. Type x and press Enter to move to expert mode.
    2. Type b and press Enter to change the beginning of the partition.
    3. Type 1 and press Enter to select the first partition.
    4. Type 128 and press Enter to move to the block 128 the beginning of the partition.
    5. Type w and press Enter to save.

      Note: This exits fdisk and returns you to the command prompt.

       
  8. Run vmkfstools -V and press Enter to discover the VMFS.
Note: This procedure may not work on VMFS volumes that are participating in a spanned set (extents). Contact VMware Technical Support and work with them to resolve the issue.

Fuente: http://kb.vmware.com/selfservice/microsites/search.do?language=en_US&cmd=displayKC&externalId=1002281

A.S.

1 comentario:

  1. Рeculіaг аrtiсlе, just whаt ӏ neeԁed.


    Hеre is my web ρage - Same Day Payday Loans

    ResponderEliminar