I just had to create a couple VMFS volumes from the command-line on a local disk. It’s pretty straight forward but I needed to document it anyway, here it is:
- fdisk -l (check what the last partition is)
- fdisk /dev/sda
- n (new)
- default (start block)
- default (end block)
- t (partition type)
- 10 (partition 10, just created)
- fb (vmfs type)
- w (write config)
- reboot (Reboot the host before you format the newly created local partition)
- vmkfstools -C vmfs3 /vmfs/devices/disks/vmhba0:0:0:10
- Go to VI Client, Refresh storage view and rename the newly created volume
You can align the VMFS volume as follows, before you do step 9:
- X
- b
- 1
- 128 (disk alignment, check your SAN manual for the correct value, 128 is correct in most cases…)
- W
brugh says
you may want to mention that creating partitions from the cmdline requires manual aligning. vCenter does this for you but doing this with fdisk you have to set the startingblock of a parition to a multiple of 128 to align it on a 64k block.
Duncan Epping says
Absolutely correct Herco… Will update is asap.
JackMeHoffer says
Why do you have to reboot the host?
Duncan Epping says
it’s a requirement of the Service Console unfortunately.
Hugo Strydom says
Interesting, you only have to reboot if you add partions on /dev/sda. If create partions on /sdb,c,d, ect you dont need to.
Roger Lund says
Thanks for this, I was asking about this last week.
Roger L
http://rogerlunditblog.blogspot.com/
Cody Bunch says
Cool!
Effie Matzen says
Hello.This article was really motivating, particularly because I was searching for thoughts on this issue last Friday.