Flush files to disk to reduce RAM usage
Issue #98
new
Hello everyone, when writing files to zip archives using fuse-zip, why does it add memory usage instead of copying each file one by one and then freeing up memory for the next write operation ?
Comments (3)
-
repo owner -
repo owner - changed title to Flush files to disk to reduce RAM usage
- marked as enhancement
-
repo owner - changed status to new
- Log in to comment
Hi!
Yes, fuse-zip stores new/modified files in RAM until unmount. This is how it’s implemented for now.
The main reason is ZIP file format: unlike traditional file systems it’s sequential so changing one file in the middle of the archive requires to re-write all data till the end. That’s why libzip doesn’t support “sync” operation that flushes the archive to disk and updates all the indices inside
struct zip
object.Implementing this on application level will require to close/reopen zipfile and re-read all file metainformation. It’s a big feature and I have no free time time do it right now.
See also feature #62.