Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

When I tried to extract (used right click and extract) a 2Gb ISO file it took a lot of time. I tried to mount the ISO using -o loop and its works fast. Why is it so?

share|improve this question

1 Answer 1

up vote 10 down vote accepted

You should clarify what you mean by extracting but as far as I understood:

  • in the first case you copy each file and folder out of the ISO file. By making a copy you need to read everything and write everything to a different location

  • mounting just makes the content available but does nothing else (no copy thus no read/write). The content is available as part of the file system but is read only when you make an operation on a file.

share|improve this answer
    
How mounting makes content available without reading? –  user3539 Nov 25 '12 at 16:00
    
I edited the answer: the files and folders are available but are not read until copied/opened/... –  Matteo Nov 25 '12 at 16:15
1  
When you mount it, all it does is read the index of files/folders from the ISO which tells the operating system the name and starting block of each file. So reading that is trivial, that's why it is fast and that's what is meant by "making content available". –  tpg2114 Nov 25 '12 at 21:16

Your Answer

 
discard

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.