Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I know, it's a often asked question on many boards and I have read the wikipedia article. But those articles aren't satisfactory. I want to know it because I have Ubuntu 12.04 for Android on my chrooted HTC One X. For normal file systems like a disk or a hard drive image it seems to be clear but how works a operating system loop device? My thought is, that a simualted disk is a static thing which has no own life but an operating system has it's own life with processes and threads which are running.

  • Notices the kernel (here Android) that the loop device is an os image which needs a special mounting/handling? How is the native kernel in contact with the virtual os so that I can use an os within an os?
  • Obviously it's mounted like a file system but communicates it with the kernel via the loop back adapter or has it nothing to do with that? (just the normal network communication)

I hope my problem isn't asked to complicated. Thanks for your help.

share|improve this question
You seem to not be a native English speaker. As written, I can not understand your question. You might try editing the question to contain it in your native language, and others may be able to help translate. – psusi Jun 25 '12 at 22:49
up vote 1 down vote accepted

Loop devices generally provides an interface to access a file as a file-system. In order to loop mount an image you have to place the image somewhere in your real file-systems, i.e. disk-partitions.

So while loop devices are virtual, the files they provides access to are not and those files occupy space.

When you add some data to the loop-mounted file-system the data is actually added to the image file, as if you are appending/inserting some bytes of data somewhere in a file. Loop device decides where to put those bytes. So the image file grows in size and deducts space from the hosting file-system.

To answer the question about how OS within an OS runs, it can be said that they either share kernels or use a hypervisor to emulate an encapsulated environment which translate another OS'es instructions to hosting OS'es instructions.

share|improve this answer
Thank you. That really helps me – seb Jun 30 '12 at 6:35

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.