As with many vSphere tasks, there are multiple ways in which you can upgrade datastores from VMFS3 to VMFS5. Before looking at how to upgrade a datastore, there are a few things worth mentioning about VMFS 5 and upgraded datastores.
- VMFS 5 has a block size of 1MB. This block size is the only one available an supports files of up to 2 TB.
- VMFS 5 sub blocks are 8KB. Significantly smaller than with VMFS 3 (64 KB).
- However, if you are upgrading, the block size you had in place on your VMFS 3 datastore will remain when it is upgraded to VMFS 5. Often, because of this, it is determined that it is preferable to replace VMFS 3 datastores with VMFS 5, utilising svMotion to move virtual machines around whilst datastores are destroyed and recreated.
- The disk type of an upgraded VMFS 3 datastore will remain as MBR until it is grown larger than 2TB. At this point it will be converted to a GPT disk automatically.
- VMFS datastore upgrades can be carried out on datastores with powered on virtual machines without issue.
Upgrading a Datastore using the vSphere Client
To upgrade a datastore to VMFS 5 using the vSphere client, log into vCenter, select a host that has access to the datastore you want to upgrade then, on the Configuration tab, click Storage.
With your chosen datastore highlighted, click ‘Upgrade to VMFS 5’:
You will receive a warning stating that all hosts that need to access the datastore must be version 5.0 or above otherwise they will lose access to the datastore. Click OK to start the upgrade – it will complete fairly quickly. Once the task is complete you can confirm that your datastore is VMFS5 by checking the type column:
Upgrading a VMFS Datastore using esxcli
You can also perform the upgrade using esxcli. To do so, run the following command:
~ # esxcli storage vmfs upgrade -l Datastore
Upgrading VMFS Datastores using VMKFSTOOLS
We can upgrade a VMFS datastore using vmkfstools by running the following command. We’ll be upgrading the datastore detail in the previous example. It is currently VMFS-3.54. To upgrade, run the following:
~ # vmkfstools --upgradevmfs /vmfs/volumes/NewVOL/ VMware ESX Question: Please ensure that the VMFS-3 volume /vmfs/volumes/4ff9c8a0-27ae1bdb-4a70-000c29e8410a is not in active use by any local or remote ESX 3.x/4.x server. We recommend the following: 1. Back up data on your volume as a safety measure. 2. Take precautions to ensure no ESX 3.x/4.x servers are accessing this volume. Continue converting VMFS-3 to VMFS-5? 0) _Yes 1) _No Select a number from 0-1: 0 Checking if remote hosts are using this device as a valid file system. This may take a few seconds... Upgrading file system /vmfs/volumes/NewVOL/... done.
Check that it has been upgrade successfully by using vmkfstools to query the VMFS volume:
~ # vmkfstools --queryfs -h /vmfs/volumes/NewVOL/ VMFS-5.54 file system spanning 1 partitions. File system label (if any): NewVOL Mode: public Capacity 4.8 GB, 4.2 GB available, file block size 1 MB UUID: 4ff9c8a0-27ae1bdb-4a70-000c29e8410a Partitions spanned (on "lvm"): mpx.vmhba1:C0:T2:L0:1 Is Native Snapshot Capable: NO
We can see that the VMFS version is now VMFS-5.54.Keep up to date with new posts on Buildvirtual.net - Follow us on Twitter: Follow @buildvirtual