Delete disk partitions by mistake in ESXi
Because you are not familiar with ESXi commands and are careless, you accidentally delete the partitions of the ESXi operating system. The operation procedure is as follows:
Obtain disk device information:
[Root @ localhost: ~] Fdisk-l
[Root @ localhost: ~] Fdisk-l
***
* ** The fdisk command is deprecated: fdisk does not handle GPT partitions. Please use partedUtil
***
Found valid GPT with protective MBR; using GPT
Disk/dev/disks/t10.ATA _____ WDC_WD10EZEX2D00KUWA0_________________________WD2DWCC1S5769136: 1953525168 sectors, 1863 M
Logical sector size: 512
Disk identifier (GUID): 4155b291-d307-43c6-81d8-f02bb180c373
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 1953525134
Number Start (sector) End (sector) Size Code Name
1 2048 1953523711 1863 M 0700
Found valid GPT with protective MBR; using GPT
Disk/dev/disks/t10.ATA _____ wdc_wd5000aads2d00s9b0____________________________wd2dwcav9d135907: 976773168 sectors, 931 M
Logical sector size: 512
Disk identifier (GUID): 10100004b4-fba3-4dbf-b6f6-51a88b871f73
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 976773134
Number Start (sector) End (sector) Size Code Name
1 64 8191 8128 0700
2 7086080 15472639 8190 K 0700
3 15472640 976773134 916 M 0700
5 8224 520191 499 K 0700
6 520224 1032191 499 K 0700
7 1032224 1257471 219 K 0700
8 1257504 1843199 571 K 0700
9 1843200 7086079 5120 K 0700
The ESXi operating system is installed on the hard disk:/dev/disks/t10.ATA _____ WDC_WD5000AADS2D00S9B0________________________WD2DWCAV9D135907,
Command I executed: partedUtil delete/dev/disks/t10.ATA _____ wdc_wd5000aads2d00s9b0____________________________wd2dwcav9d135907 1
As a result, partition 1 of the hard disk is lost.
[Root @ localhost: ~] Fdisk-l
***
* ** The fdisk command is deprecated: fdisk does not handle GPT partitions. Please use partedUtil
***
Found valid GPT with protective MBR; using GPT
Disk/dev/disks/t10.ATA _____ WDC_WD10EZEX2D00KUWA0_________________________WD2DWCC1S5769136: 1953525168 sectors, 1863 M
Logical sector size: 512
Disk identifier (GUID): 4155b291-d307-43c6-81d8-f02bb180c373
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 1953525134
Number Start (sector) End (sector) Size Code Name
1 2048 1953523711 1863 M 0700
Found valid GPT with protective MBR; using GPT
Disk/dev/disks/t10.ATA _____ wdc_wd5000aads2d00s9b0____________________________wd2dwcav9d135907: 976773168 sectors, 931 M
Logical sector size: 512
Disk identifier (GUID): 10100004b4-fba3-4dbf-b6f6-51a88b871f73
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 976773134
Number Start (sector) End (sector) Size Code Name
2 7086080 15472639 8190 K 0700
3 15472640 976773134 916 M 0700
5 8224 520191 499 K 0700
6 520224 1032191 499 K 0700
7 1032224 1257471 219 K 0700
8 1257504 1843199 571 K 0700
9 1843200 7086079 5120 K 0700
Alas, the result is tragic ..................
When the system does not restart, the system can still run normally. I copied important data, but fortunately there are only two virtual machines. The system cannot be started directly after being restarted.
# Esxcfg-scsidevs-l
Copy code
[Root @ localhost: ~] Esxcfg-scsidevs-l
T10.ATA _____ WDC_WD10EZEX2D00KUWA0_________________________WD2DWCC1S5769136
Device Type: Direct-Access
Size: 953869 MB
Display Name: Local ATA Disk (t10.ATA _____ WDC_WD10EZEX2D00KUWA0_________________________WD2DWCC1S5769136)
Multipath Plugin: NMP
Console Device:/vmfs/devices/disks/t10.ATA _____ wdc_wd10ezex2d00kuwa0_____________________wd2dwcc1s5769136
Devfs Path:/vmfs/devices/disks/t10.ATA _____ wdc_wd10ezex2d00kuwa0_____________________wd2dwcc1s5769136
Vendor: ATA Model: WDC WD10EZEX-00K Revis: 15.0
SCSI Level: 5 Is Pseudo: false Status: on
Is RDM Capable: false Is Removable: false
Is Local: true Is SSD: false
Other Names:
Vml1_00000000202020202057442d574343315335373639313336574443205744
VAAI Status: unknown
T10.ATA _____ wdc_wd5000aads2d00s9b0____________________________wd2dwcav9d135907
Device Type: Direct-Access
Size: 476940 MB
Display Name: Local ATA Disk (t10.ATA _____ wdc_wd5000aads2d00s9b0____________________________wd2dwcav9d135907)
Multipath Plugin: NMP
Console Device:/vmfs/devices/disks/t10.ATA _____ WDC_WD5000AADS2D00S9B0________________________WD2DWCAV9D135907
Devfs Path:/vmfs/devices/disks/t10.ATA _____ WDC_WD5000AADS2D00S9B0________________________WD2DWCAV9D135907
Vendor: ATA Model: WDC WD5000AADS-0 Revis: 01.0
SCSI Level: 5 Is Pseudo: false Status: on
Is RDM Capable: false Is Removable: false
Is Local: true Is SSD: false
Other Names:
Vml1_00000000202020202057442d574341563944313335393037574443205744
VAAI Status: unknown
This article permanently updates the link address: