Sun Microsystems 3.0.0 Computer Accessories User Manual


 
5 Virtual storage
5.4 Cloning disk images
You can duplicate hard disk image files on the same host to quickly produce a second
virtual machine with the same operating system setup. However, you should only make
copies of virtual disk images using the utility supplied with VirtualBox; see chapter
8.16, VBoxManage clonehd, page 118. This is because VirtualBox assigns a unique
identity number (UUID) to each disk image, which is also stored inside the image, and
VirtualBox will refuse to work with two images that use the same number. If you do
accidentally try to reimport a disk image which you copied normally, you can make a
second copy using VirtualBox’s utility and import that instead.
Note that newer Linux distributions identify the boot hard disk from the ID
of the drive. The ID VirtualBox reports for a drive is determined from the
UUID of the virtual disk image. So if you clone a disk image and try to boot
the copied image the guest might not be able to determine its own boot disk
as the UUID changed. In this case you have to adapt the disk ID in your
boot loader script (for example /boot/grub/menu.lst). The disk ID looks like
scsi-SATA_VBOX_HARDDISK_VB5cfdb1e2-c251e503. The ID for the copied
image can be determined with
hdparm -i /dev/sda
5.5 iSCSI servers
iSCSI stands for “Internet SCSI” and is a standard that allows for using the SCSI proto-
col over Internet (TCP/IP) connections. Especially with the advent of Gigabit Ethernet,
it has become affordable to attach iSCSI storage servers simply as remote hard disks
to a computer network. In iSCSI terminology, the server providing storage resources
is called an “iSCSI target”, while the client connecting to the server and accessing its
resources is called “iSCSI initiator”.
VirtualBox can transparently present iSCSI remote storage to a virtual machine as
a virtual hard disk. The guest operating system will not see any difference between a
virtual disk image (VDI file) and an iSCSI target. To achieve this, VirtualBox has an
integrated iSCSI initiator.
VirtualBox’s iSCSI support has been developed according to the iSCSI standard and
should work with all standard-conforming iSCSI targets. To use an iSCSI target with
VirtualBox, you must first register it as a virtual hard disk with VBoxManage; see
chapter 8.18, VBoxManage addiscsidisk, page 120. The target will show up in the list
of disk images, as described in chapter 3.5, The Virtual Disk Manager, page 43, and
can thus be attached to one of the VM’s three hard disk slots the usual way.
5.5.1 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 (as de-
scribed in chapter 6.6, Internal networking, page 88). The setup of the virtual machine
80