creating a virtual whole-disk from real partitions
a feature i would like to see is a way to specify "a disk" as a series of file and/or block device sources, creating a virtual partition table with the various sources, in their whole, becoming virtual partitions of this created whole disk, with sizes determined either from the size of the source or specified in the list, plus support for partitioned sources (specify which partition(s) is/are sources). a simple usage would allow 2 files to become a 2 partition whole disk ... a more complex usage could make a 5 partition BSD disk appear as a 5 partition GUID disk (need support for BSD, DOS, and GUID parsing and creation for thorough usage).
Your thoughts on such a feature? |
If I am getting it correctly you are talking about slicing a single disk and then using the partition to act as a whole virtual disk. Which means if I have 100 gig HDD and I create 5 partitions of 20 GB each then each one of them will act as 20 gig hdd which will have its own partition table and I can further partition it. Is that correct?
If the above is correct then I would say it is pretty good and I can somewhat correlate it with what Openfiler does. Though it is based on iscsi and virtual SAN concept but the idea remains the same. |
Can you explain why you'd want to do this maybe. Not sure I get it.
I think you can already in many VM's. "specify "a disk" as a series of file and/or block device sources," The partition table has nothing to do with how the virtual disk is made. So parts of your question is how to make up a virtual hard drive from more than one file or raw device. All in all I don't see the need for this exactly. The current methods may be to use LVM, ZFS or Btrfs on a virtual hard drive. Virtual support for raw and partitions and disks exist now. We used to make virtual hard drives out of less than 2G files to bypass the filesystem limits. It is still there but now used that much now. |
I may be reading this wrong, but if you have a number of disk images, then mounting them under a single directory using losetup would appear to achieve what you are describing.
|
Sounds like you could use LVM
|
Quote:
as a plus it could make cloud configurations easier. Quote:
Quote:
Quote:
Quote:
example: i have a file that is to be partition 1 (already ext2) a big (nearly 2TB) partition on a USB drive is to be partition 2 (ext4) a ramdisk is to be partition 3 (initialized as swap) how would LVM, ZFS or Btrfs be used here? |
Quote:
maybe you are reading me wrong. |
Quote:
Quote:
|
Quote:
Code:
$ truncate --size 2T /var/tmp/stuff |
@Skaperen
Quote:
|
Quote:
|
Quote:
|
All times are GMT -5. The time now is 11:34 PM. |