9 Advanced topics The modified MBR will be stored inside the image, not on the host disk. For each of the above variants, you can register the resulting image for immediate use in VirtualBox by adding -register to the respective command line. The image will then immedi- ately appear in the list of registered disk images. An example is VBoxManage internalcommands createrawvmdk -filename /path/to/file.vmdk -rawdisk /dev/sda -partitions 1,5 -relative -register which creates an image referring to individual partitions, and registers it when the image is successfully created. 9.7.2 Configuring the hard disk vendor product data (VPD) VirtualBox reports vendor product data for its virtual hard disks which consist of hard disk se- rial number, firmware revision and model number. These can be changed using the following commands: VBoxManage setextradata "VM name" "VBoxInternal/Devices/ahci/0/Config/Port0/SerialNumber" "serial" VBoxManage setextradata "VM name" "VBoxInternal/Devices/ahci/0/Config/Port0/FirmwareRevision" "firmware" VBoxManage setextradata "VM name" "VBoxInternal/Devices/ahci/0/Config/Port0/ModelNumber" "model" The serial number is a 20 byte alphanumeric string, the firmware revision an 8 byte alphanu- meric string and the model number a 40 byte alphanumeric string. Instead of “Port0” (referring to the first port), specify the desired SATA hard disk port. Additional three parameters are needed for CD/DVD drives to report the vendor product data: VBoxManage setextradata "VM name" "VBoxInternal/Devices/ahci/0/Config/Port0/ATAPIVendorId" "vendor" VBoxManage setextradata "VM name" "VBoxInternal/Devices/ahci/0/Config/Port0/ATAPIProductId" "product" VBoxManage setextradata "VM name" "VBoxInternal/Devices/ahci/0/Config/Port0/ATAPIRevision" "revision" The vendor id is an 8 byte alphanumeric string, the product id an 16 byte alphanumeric string and the revision a 4 byte alphanumeric string. Instead of “Port0” (referring to the first port), specify the desired SATA hard disk port. 9.7.3 Access iSCSI targets via Internal Networking As an experimental feature, VirtualBox allows for accessing an iSCSI target running in a virtual machine which is configured for using Internal Networking mode. Please see chapter 5.10, iSCSI servers, page 82 chapter 6.5, Internal networking, page 88 and chapter 8.16, VBoxManage storageattach, page 119 for additional information. The IP stack accessing Internal Networking must be configured in the virtual machine which accesses the iSCSI target. A free static IP and a MAC address not used by other virtual machines must be chosen. In the example below, adapt the name of the virtual machine, the MAC address, the IP configuration and the Internal Networking name (“MyIntNet”) according to your needs. The following seven commands must first be issued: VBoxManage setextradata "VM name" VBoxInternal/Devices/IntNetIP/0/Trusted 1 VBoxManage setextradata "VM name" VBoxInternal/Devices/IntNetIP/0/Config/MAC 08:00:27:01:02:0f VBoxManage setextradata "VM name" VBoxInternal/Devices/IntNetIP/0/Config/IP 10.0.9.1 VBoxManage setextradata "VM name" VBoxInternal/Devices/IntNetIP/0/Config/Netmask 255.255.255.0 VBoxManage setextradata "VM name" VBoxInternal/Devices/IntNetIP/0/LUN#0/Driver IntNet VBoxManage setextradata "VM name" VBoxInternal/Devices/IntNetIP/0/LUN#0/Config/Network MyIntNet VBoxManage setextradata "VM name" VBoxInternal/Devices/IntNetIP/0/LUN#0/Config/IsService 1 144
Previous Page Next Page