Virtualbox on Freebsd with ZFS

  • VirtualBox Disk로 사용할 공간 확보

zfs create -V 100G zroot/virtualbox-mira

  • 해당 raw로 디스크 매핑

VBoxManage internalcommands createrawvmdk -filename /root/VirtualBox\ VMs/mira/mira.vmdk -rawdisk /dev/zvol/zroot/virtualbox-mira

  • VM생성
    VBoxManage createvm –name “mira” –register

 

  • VM스펙 설정

VBoxManage modifyvm mira –memory 3072 –cpus 8 –nictype1 82545EM

VBoxManage storagectl mira –name “SATA Controller” –add sata –controller IntelAhci –portcount 4 –hostiocache on
VBoxManage storagectl mira –name “IDE Controller” –add ide –controller PIIX4

VBoxManage storageattach mira –storagectl “SATA Controller” –port 0 –device 0 –type hdd –medium /root/VirtualBox\ VMs/mira/mira.vmdk

VBoxManage storageattach mira –storagectl “IDE Controller” –port 0 –device 0 –type dvddrive –medium “/opt/zero/Windows.iso”

VBoxManage modifyvm mira –acpi on
VBoxManage modifyvm mira –ioapic on –boot1 dvd

VBoxManage modifyvm genie –memory 6144 –acpi on –boot1 dvd
777 17:11 VBoxManage createhd –filename /root/VirtualBox\ VMs/genie/genie.vmdk –size 102400
778 17:11 VBoxManage storagectl genie –name “IDE Controller” –add ide

 

주의사항

zfsnap등으로 스냅샷을 생성하면 virtualbox가 hang걸린다.