Using Multiple Disk Images in QEMU
QEMU by default lets you use 4 "hard drives", or simulated devices, as
Here's another way to get more disk drives, use QEMU disk images (created with
USB support has not always been available in QEMU, make sure you install the latest version (0.8.2 was the latest at the time this story was written, 21Aug2006). According to the QEMU website, the first version of QEMU with USB support is 0.8.0.
When you start QEMU, make sure you specify the
Create the disk images with:
Create a bunch of those, then use LVM or another tool that lets you mirror/concatinate volumes to simulate multiple disks. I think the limitation you would hit as far as the number of USB virtual disks would be 16, that being the maximum number of partitions allowed on SCSI disk devices in Linux, which is what Linux uses to connect USB disk devices to the system.
Here's a sample QEMU startup script with a Debian CD image on the emulated CD-ROM, some gratuitous network redirection, and a bunch of USB disks created using the above
Once you have QEMU up and running on the host with your guest OS, use the following commands in the QEMU monitor to mount disk images created with
Use the partitioning tools of the guest OS to partition and format the new "hard drives" once you attach them.