在esxi5.5的虚拟化服务器上添加一块900G的硬盘时,报如下错误。

ESXI5.5添加本地磁盘出错的解决_ESXi5.5

这个错误的出现主要是因为这块盘被使用过,还带有原分区信息。

解决办法:

首先到 配置->安全配置文件里启用ssh服务。然后使用SecureCRT或PUTTY远程登陆EXSI主机。

ESXI5.5添加本地磁盘出错的解决_ESXi5.5_02

1、查看分区信息

ls /vmfs/devices/disks

ESXI5.5添加本地磁盘出错的解决_ESXi5.5_03

2、与exsi上的标识符对应

ESXI5.5添加本地磁盘出错的解决_ESXi5.5_04

3、使用partedutil工具看到有1个分区,然后删除分区。(注:LINUX里新建和调整分区一般用FDISK和PARTED。 fdisk可划分单个分区不超过2T的分区,parted命令可以划分单个分区大于2T的GPT格式的分区,在EXSI里使用partedUtil命令来设置和调整分区。)

#partedUtil delete vmfs/devices/disks/naa.600605b0051527001970471b0e906a8b 1


4、重新添加磁盘

ESXI5.5添加本地磁盘出错的解决_ESXi5.5_05

5、选择磁盘

ESXI5.5添加本地磁盘出错的解决_ESXi5.5_06

6、选择文件系统

ESXI5.5添加本地磁盘出错的解决_ESXi5.5_07

7、检查磁盘布局并完成

ESXI5.5添加本地磁盘出错的解决_ESXi5.5_08

8、添加成功。


附:重置分区大小

Resizing a partition

The partedUtil command can be used to resize an existing partition on ESXi/ESX 4.0 and higher. This does not resize the file system within the partition, and is no different from deleting and recreating the partition with a new starting or ending sector.

To resize a partition, run this command:

partedUtil resize "/vmfs/devices/disks/DeviceName" PartitionNumber NewStartSector NewEndSector

Example: To move partition 4 such that it starts in the same location (for example, 2474073) and ends at the new ending sector (1234567890), run this command:

partedUtil resize "/vmfs/devices/disks/mpx.vmhba0:C0:T0:L0" 4 2474073 1234567890

Caution: There is no facility to undo a partition table change other than creating a new partition table. Ensure that you have a backup before making any change. Ensure that there is no active I/O to a partition before modifying it.


本文出自 “滴水穿石孙杰” 博客,请务必保留此出处http://xjsunjie.blog.51cto.com/999372/1681987