Thursday, June 21, 2012

VirtualBox - How to create ASM Disks

1.  Shutdown Virtual machine:
      # shutdown -h now

2.  from Windows command prompt:
     mkdir E:\VirtualBox\VM\harddisks (E:\VirtualBox is virtualbox home)
You need to change your VirtualBox directory accordingly

3.  run as below from command prompt:

cd E:\VirtualBox\VM\harddisks 

# Create the disks and associate them with VirtualBox as virtual media.
# Each disk is 5 GB size, total 25 GB

E:\VirtualBox\VM\harddisks>E:\VirtualBox\VBoxManage createhd --filename asm1.vdi --size 5120 --format VDI --variant Fixed 
E:\VirtualBox\VM\harddisks>E:\VirtualBox\VBoxManage createhd --filename asm2.vdi --size 5120 --format VDI --variant Fixed
E:\VirtualBox\VM\harddisks>E:\VirtualBox\VBoxManage createhd --filename asm3.vdi --size 5120 --format VDI --variant Fixed
E:\VirtualBox\VM\harddisks>E:\VirtualBox\VBoxManage createhd --filename asm4.vdi --size 5120 --format VDI --variant Fixed
E:\VirtualBox\VM\harddisks>E:\VirtualBox\VBoxManage createhd --filename asm5.vdi --size 5120 --format VDI --variant Fixed


Connect them to the VM



E:\VirtualBox\VBoxManage storageattach Linux --storagectl "SATA Controller" --port 1 --device 0 --type hdd --medium asm1.vdi --mtype shareable
E:\VirtualBox\VBoxManage storageattach Linux --storagectl "SATA Controller" --port 2 --device 0 --type hdd --medium asm2.vdi --mtype shareable
E:\VirtualBox\VBoxManage storageattach Linux --storagectl "SATA Controller" --port 3 --device 0 --type hdd --medium asm3.vdi --mtype shareable
E:\VirtualBox\VBoxManage storageattach Linux --storagectl "SATA Controller" --port 4 --device 0 --type hdd --medium asm4.vdi --mtype shareable
E:\VirtualBox\VBoxManage storageattach Linux --storagectl "SATA Controller" --port 5 --device 0 --type hdd --medium asm5.vdi --mtype shareable




# Make shareable
E:\VirtualBox\VBoxManage modifyhd asm1.vdi --type shareable
E:\VirtualBox\VBoxManage modifyhd asm2.vdi --type shareable
E:\VirtualBox\VBoxManage modifyhd asm3.vdi --type shareable
E:\VirtualBox\VBoxManage modifyhd asm4.vdi --type shareable
E:\VirtualBox\VBoxManage modifyhd asm5.vdi --type shareable




No comments:

Post a Comment