In some environments you may need to move large VM images between ESXi hosts without relying on a network. A USB flash drive or external disk can help. There are two main approaches: (1) mount the USB as a normal filesystem (FAT/NTFS) and copy files via SSH, or (2) format the USB as a VMFS datastore and attach it to each host. The first method is straightforward but limited by filesystem size and requires CLI tools; the second (recommended) creates a real VMFS6 datastore on the USB, allowing full-size files and GUI access. Note that USB-as-VMFS is unsupported by VMware, so use it carefully for temporary transfers or lab use only.
Method 1 requires disabling the USB arbitrator, plugging in the drive, and using ESXi shell tools like mcopy or ntfscat to move files. This works only if you disable the USB arbitrator so ESXi sees the device and copy in chunks, because FAT32 has a 4 GB file-size limit. By contrast, Method 2 supports multi-terabyte transfers without such limits, and lets you use the vSphere Client or datastore browser once the VMFS is mounted.
Below we walk through Method 2 step by step. We use SSH commands on each host to create, copy, and mount the USB datastore. Adjust hostnames and device IDs as needed. All commands are run as root on the ESXi host shell or via SSH.
Step 1: Disable the USB Arbitrator
Before ESXi will access a USB drive for storage, you must stop the USB Arbitrator. For example, SSH into the ESXi host (or use the DCUI) and run:
/etc/init.d/usbarbitrator stop chkconfig usbarbitrator off
This immediately stops the arbitrator and disables it across reboots. As a GUI alternative, you can set USB.arbitratorAutoStartDisabled=1 in Advanced Settings and reboot. With the service stopped, plug the USB drive into the host’s USB port. ESXi should now detect it as a local disk rather than pass it through to a VM.
Step 2: Rescan Storage
Tell ESXi to rescan for new devices. For example:
esxcfg-rescan -A # Rescan all SCSI/USB bus adapters
# (or)
esxcli storage core adapter rescan –all
This discovers the USB device. You can verify by listing storage devices, e.g.:
esxcfg-scsidevs -l | grep -i usb
or
ls /dev/disks/
Look for a line like mpx.vmhba34:C0:T0:L0 labeled Local USB Direct-Access. Note this device path (we’ll refer to it as ${DISK}) for partitioning and formatting.
Step 3: Partition & Format the USB as VMFS6
Once ESXi sees the raw USB disk, create a GPT partition and format it as VMFS6. Warning: This erases all data on the drive! For safety, use a USB stick ≥ 16 GB (an 8 GB stick will not work). Assuming the device path is /vmfs/devices/disks/mpx.vmhba34:C0:T0:L0, do:
partedUtil mklabel ${DISK} gpt
This makes a new GPT label. Next, create a single VMFS partition on the entire disk. You need the VMFS partition GUID AA31E02A400F11DB9590000C2911D1B8. Compute the end sector via partedUtil getptbl, or use this eval trick:
partedUtil setptbl ${DISK} gpt \
"1 2048 $(eval expr $(partedUtil getptbl ${DISK} | tail -1 | awk '{print $1 " * " $2 " * " $3}') - 1) AA31E02A400F11DB9590000C2911D1B8 0"
This command creates partition #1 starting at sector 2048 and ending at the last available sector, with the VMFS partition type. Finally, format it as VMFS6:
vmkfstools -C vmfs6 -S USB-DS ${DISK}:1
ESXi will create a VMFS6 filesystem on that partition. After this, a new datastore named “USB-DS” should appear in the Storage view of the Host Client and vSphere Client.
Step 4: Copy or Clone Files to the USB Datastore
Now the USB drive is a normal ESXi datastore. You can use the Host Client GUI (Datastore Browser) to upload ISOs, OVFs or other files to it. For large virtual disks, it’s faster to clone them via vmkfstools than to use cp or scp. For example, to copy a VM’s VMDK from another datastore to the USB datastore:
vmkfstools -i /vmfs/volumes/Datastore1/myvm/myvm.vmdk /vmfs/volumes/USB-DS/myvm.vmdk
This clones the disk image directly within the host. You can also do a Storage vMotion to the USB datastore if vMotion is available. If you only have an ISO or small file, a simple cp or the datastore browser works too. Because this is VMFS, the 4 GB limit of FAT32 is gone.
Step 5: Unmount and Attach to the Second Host
When done, unmount or detach the datastore on the first host or simply stop the host. Now move the USB drive to the target ESXi host and repeat Step 1. Then rescan for storage again. The USB VMFS should now appear as an existing datastore. In many cases ESXi will automatically mount it; if it shows up offline, use ESXCLI to attach it. For example:
/etc/init.d/usbarbitrator stop esxcfg-rescan -A esxcli storage filesystem list # see the new NAA ID or UUID
If the datastore is detected as a snapshot (offline), list and mount it:
esxcli storage vmfs snapshot list # (copy the shown VMFS UUID) esxcli storage vmfs snapshot mount -u <UUID>
This brings the USB datastore online on the second host. It now contains all the files you copied. You can browse it in the GUI or use it normally. When finished, unmount the USB datastore and safely disconnect the drive. Finally, re-enable USB arbitrator on each host:
chkconfig usbarbitrator on /etc/init.d/usbarbitrator start
Conclusion
By following these steps, you can shuttle large VMs, ISOs or backups between isolated ESXi hosts via a USB disk. This hack restores the convenience of the GUI and removes the 4 GB file limit of FAT32, at the cost of using an unsupported configuration. Always double-check that you have the right device paths before partitioning, and copy off any important data from the USB drive beforehand.