Loop Block experts on List?
tonysu at su-networking.com
Sat Dec 18 16:19:31 PST 2010
Yes, cloop devices are typically used to mount optical devices and from what
I understand many USB devices (the alternative is udev today). Loop devices
are pretty interesting, I also understand it can be a major component for
network deployment, eg part of some PXE and possibly used for network
In general, my questions all apply to "block device" loop devices, not "file
system" loop devices. "block devices" is the more common deployment which
maps at the block level as opposed to the "file system" type which accesses
the loop storage through the OS virtual file system.
1. Deploying a file system on top of another file system often causes
partition alignment issues, VMware in particular extensively writes about
this issue when transporting vmware disks from one system to another. Vmware
disks which are run on the system they were originally created are
automatically aligned when created. I can't find anything written anywhere
whether loop devices are subject to this same issue although to me it's
2. Are RDM (Raw Device Mapping) loop files interoperable cross platform? So,
as an example can an unformatted RDM file which simply contains blocks be
created on one OS, then be deployed as a loop device on another device? Is
there any difference if the file is simply disk blocks or if it has been
partitioned and formatted?
3. After long searching, I think that RDM typically maps sector to sector,
and this is because "since forever" the basic OS I/O disk operation common
to practically every PC OS is the 512 byte sector. For that reason,
typically all disk formatting larger than something like 16mb is either
based on 512 byte sectors or some multiple thereof. The common sense result
obviously is that loop device geometry should likely be based on 512 byte
sectors to maximize the likelihood of RDM mapping consistency, but today
disk capacities are getting so large that we will be seeing 4kbyte (4x 5112
byte) sectors (Western Digital's Advanced Format drives are already
formatted this way) to improve large disk performance. I can see this could
have a really horrendous impact on something like a Loop device,
particularly if files are defragmented in a way that decreases the
occurrence of 4 sequential sectors. Is there a known way to approach this
aside from regular special defragmentation(eg must re-sequence sectors, not
just compact)? I suppose the alternative to a defragmentation utility is the
tried and true "move the file to another partition and back again."
4.Is loop device disk geometry important? A loop device fs is a
quasi-virtual device where the disk geometry obviously isn't constrained by
the physical disk geometry, but is there a "best practice" for loop device
disk geometry? I see a multitude of examples of "single cylinder"
configurations for devices up to about 80mb, but no documentation or
guidance I can find for anything larger. Unfortuantely, I don't think I can
rely on VMware VMFS as guidance because VMFS is a kind of intermediate
virtualization layer between the loop disk fs and the physical fs which
could change relevant parameters. Am not as familiar with other
virtualization disk technologies (like Virtual Box, Xen, etc) which tend to
sit directly on the physical fs, maybe someone who is expert on this can
offer some expert opinion?
5. Is anyone deploying Loop Root Device files, and if so, did you have to
compile loop device support into the initrd or was it there by default?
On Fri, Dec 17, 2010 at 2:30 PM, Gus Wirth <gwirth79 at gmail.com> wrote:
> On 12/17/2010 11:45 AM, Tony Su wrote:
> > Am working on a project, have a number of questions I can't Google for
> > answers.
> > So, before asking specific questions, just wondering whether any List
> > Members consider themselves either experienced in use or theory relating
> > Loop(back) Block devices. Extra points if using as a root device. Main
> > of course in Linux, but any theory/experience using in other OS would be
> > valuable, too.
> Instead of fishing around, just ask your question. If someone knows the
> answer, they'll either post or tell you where you can find out.
> I have extensive experience with loopback mounts. It's called Knoppix,
> and it's technology has been incorporated in every LiveCD since its
> invention. The specific item is called cloop.
> There are other loopback mount types available as well. For instance,
> it's possible to create a file with a filesystem inside it and mount
> that using the loopback option.
> KPLUG-List at kernel-panic.org
More information about the KPLUG-List