[root@ITEEST root]# fdisk /dev/sdb
The number of cylinders for this disk is set to 17684.
There is nothing wrong with that, but this is larger than 1024,
and could in certain setups cause problems with:
1) software that runs at boot time (e.g., old versions of LILO)
2) booting and partitioning software from other OSs
(e.g., DOS FDISK, OS/2 FDISK)
Command (m for help): n (#输入n参数来增加新的分区#)
Command action (#选择新建的分区类型,主分区还是扩展分区;选择p或者e#)
e extended
p primary partition (1-4)
p (#这里选择P是主要分区#)
Partition number (1-4): 1 (#添加主分区1 #)
First cylinder (1-17684, default 1):
Using default value 1
Last cylinder or +size or +sizeM or +sizeK (1-17684, default 17684):
Using default value 17684
Command (m for help): x (#输入x ,进行专家模式#)
Expert command (m for help): b (#专家行模式,输入b ,编辑bsd类型分区#)
Partition number (1-4): 1 (#添加主分区1#)
New beginning of data (63-284093459, default 63):
Using default value 63
Expert command (m for help): r (#输入r ,返回主菜单#)
Command (m for help): t (#输入t ,改变分区类型,系统会提示要改变哪个分区#)
Selected partition 1
Hex code (type L to list codes): fb (如果想知道系统支持的分区类型列表,输入l#)
Changed system type of partition 1 to fb (Unknown)
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
WARNING: Re-reading the partition table failed with error 16: Device or resource busy.
The kernel still uses the old table.
The new table will be used at the next reboot.
Syncing disks.
[root@ITEEST root]# fdisk ?–l
Unable to open –l
[root@ITEEST root]# fdisk -l
-bash: fdi: command not found
[root@ITEEST root]# fdisk -l
Disk /dev/sda: 146.5 GB, 146548981760 bytes
255 heads, 63 sectors/track, 17816 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sda1 * 1 13 104391 83 Linux
/dev/sda2 14 650 5116702+ 83 Linux
/dev/sda3 651 17480 135186975 fb Unknown
/dev/sda4 17481 17816 2698920 f Win95 Ext'd (LBA)
/dev/sda5 17481 17549 554211 82 Linux swap
/dev/sda6 17550 17803 2040223+ 83 Linux
/dev/sda7 17804 17816 104391 fc Unknown
Disk /dev/sdb: 145.4 GB, 145458462720 bytes
255 heads, 63 sectors/track, 17684 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/sdb1 1 17684 142046698+ fb Unknown
[root@ITEEST root]# vmkfstools -C vmfs3 -b 1m -S myVMFS vmhba0:1:0:1
Vmkfstools (#使用Vmkfstools 工具#)
-C (#建立一个虚拟磁盘#)
Vmfs3 (#创建为VMFS3文件格式系统#)
-b 1m (#用于指定文件块大小,我这里指定为1M#)
-S mlyVMFS (#设置VMFS文件系统标签, 我这里设置成mlyVMFS#)
vmhba0:1:0:1
(#vmhba0其中第一个0表示适配器,1表示第二块目标硬盘,0表示LUN(逻辑单位编号),1表示分区.如果这一位为0则表示整个磁盘#)
Creating file system on "vmhba0:1:0:1" with blockSize 1048576 and volume label "myVMFS".
Successfully created new volume: 48e1f0ec-56446db6-16c3-00114335e798
打开VIC的STORAGE就可以看到名字为myVMFS的第二个存储
阅读(1825) | 评论(0) | 转发(0) |