Add a secondary disk to a virtual machine

If the main disk is not large enough when it is first imported, you can do this procedure to add a larger virtual data disk to the virtual machine (VM).

You should be familiar with managing virtual disks in your hypervisor environment. If you are not, refer to your hypervisor manual or contact your hypervisor's support service.
Note: When you add a disk, use a disk type of SCSI or SATA that uses a storage type of:
  • LSI Logic SAS
  • LSI Logic, or
  • SATA
IDE disks are not recommended.
  1. Add a disk to the virtual machine (VM).
  2. Restart the VM.
  3. In the VM console, to obtain the name of the disk devices, enter this command:
    sysctl kern.disks
  4. Assuming ada1 is the device disk added as a secondary disk (note that ada0 is the OS device), execute this command to move the data partition to it:
    data_move ada1