HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
mxmlnkn
ratarmount
Python2021–2026
mxmlnkn / ratarmount

ratarmount

Access large archives as a filesystem efficiently, e.g., TAR, RAR, ZIP, GZ, BZ2, XZ, ZSTD archives

12Distinct people
18Mentions
0Explicit recommenders
1.3KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Access large archives as a filesystem efficiently, e.g., TAR, RAR, ZIP, GZ, BZ2, XZ, ZSTD archives

GitHub

Where it is used

No documented product use was verified in the last source check.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 3:56:07 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year18 dated mentions

Observed mentions: 2021-11-11 07:46:57 UTC to 2026-05-04 01:24:41 UTC.

0123452021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments20212022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 4 mentions; 2 submissions, 2 comments20232024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 5 mentions; 3 submissions, 2 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2026-01-01 00:00:00 UTC to 2027-01-01 00:00:00 UTC (exclusive): 4 mentions; 1 submissions, 3 comments. Incomplete calendar period.2026*

* An incomplete calendar period is marked with an outlined bar. Its count is not directly comparable with a full period.

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC101
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC312
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC422
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC532
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC101
2026 (partial)2026-01-01 00:00:00 UTC2027-01-01 00:00:00 UTC413

What Hacker News says

18 sources
Per this 2018 page, GNU tar seems to work with SCHILY.* encoded xattrs, but not LIBARCHIVE.* ones: * https://mgorny.pl/articles/portability-of-tar-features.html#... * Via: https://github.com/mxmlnkn/ratarmount/issues/145 bsdtar ≥3.7.2 apparently adds both types to its files for maximum portability: * https://github.com/libarchive/libarchive/pull/691/files#diff... AFAICT, bsdtar will default to "ustar" format, but will auto-switch to "pax" if needed.
In Tar Files Created on macOS Display Errors When Extracting on Linux (2024)
I'm a bit disappointed that this only solves the "find index of file in tar" problem, but not at all the "partially read a tar.gz" file problem. So really you're still reading the whole file into memory, so why not just extract the files properly while you are doing that? Takes the same amount of time (O(n)) and less memory. The gzip-random-access problem one is a lot more difficult because the gzip has internal state. But in any case, solutions exist! Apparently the internal state is only 32kB, so if you save this at 1MB offsets, you can reduce the amount of data you need to decompress for one file access to a constant. https://github.com/mxmlnkn/ratarmount does this, apparently using https://github.com/pauldmccarthy/indexed_gzip internally. zlib even has an example of this method in its own source tree: https://github.com/gcc-mirror/gcc
Read the rest
/blob/master/zlib/examples/... All depends on the use case of course. Seems like the author here has a pretty specific one - though I still don't see what the advantage of this is vs extracting in JS and adding all files individually to memfs. "Without any copying" doesn't really make sense because the only difference is copying ONE 1MB tar blob into a Uint8Array vs 1000 1kB file blobs One very valid constraint the author makes is not being able to touch the source file. If you can do that, there's of course a thousand better solutions to all this - like using zip, which compresses each file individually and always has a central index at the end.
In Mounting tar archives as a filesystem in WebAssembly
mxmlnkn·Nov 1, 2024Submission

Show HN: Ratarmount 1.0.0 – Rapid access to large archives via a FUSE filesystem

Hi HN, Since my first posted introduction of ratarmount [0], 2 years have gone by and many features have been added. To summarize, ratarmount enables working with archived contents exposed as a filesystem without the data having to be extracted to disk: pip install ratarmount ratarmount archive.tar mounted ls -la mounted I started this project after noticing the slowness of archivemount with large TAR files and wondering how this could be because the file contents exist at some offset in the archive file and it should not be difficult to read that data. Turns out, that part was not difficult, however packaging everything nicely, adding tests, and adding many more formats and features such as union mounting and recursive mounting, are the things keeping me busy on this project until today. Since the last Show HN, a libarchive,
Read the rest
SquashFS, fsspec, and many more backends have been added, so that it now should be able to read every format that archivemount can and some more, and even read them remotely. However, performance for any use case besides bzip2/gzip-compressed TARs may vary even though I did my best. Personally, I am using it view to packed folders with many small files that do not change anymore. I pack these folders because else copying to other hard drives takes much longer. I'm also using it when I want to avoid the command line. I have added ratarmount as a Caja user script for mounting via right-click. This way, I can mount an archive and then copy the contents to another drive to effectively do the extraction and copying in one step. Initially, I have also used it to train on the ImageNet TAR archive directly. I probably should have released a 1.0.0 some years ago because I have kept the command line interface and even the index file format compatible as best as possible between the several 0.x versions already. Some larger future features on my wishlist are: - A new indexed_lz4 backend. This should be doable inside my indexed_bzip2 [1] / rapidgzip [2] backend library. - A custom ZIP and SquashFS reader accelerated by rapidgzip and indexed_bzip2 to enable faster seeking inside large files inside those archives. - I am eagerly awaiting the Linux Kernel FUSE BPF support [3], which might enable some further latency reductions for use cases with very small files / very small reads, at least in the case of working with uncompressed archives. I have done comparisons for such archives (100k images a 100 KiB) and noticed that direct access via the Python library ratarmountcore was roughly two times faster than access via ratarmount and FUSE. Maybe I'll even find the time to play around with the existing unmerged FUSE BPF patch set. [0] https://news.ycombinator.com/item?id=30631387 [1] https://news.ycombinator.com/item?id=31875318 [2] https://news.ycombinator.com/item?id=37378411 [3] https://lwn.net/Articles/937433/
76 points · Open discussion
The libfuse github has some good examples for C/C++ in [0] of increasing complexity: - passthrough.c mirrors existing filesystem, "Its performance is terrible." - passthrough_fh.c "performance is not quite as bad." - passthrough_ll.c implemented with low level api and "the least bad among the three" - passthrough_hp.cc high performance version written in C++ Some interesting fuse projects in my notes: [1] splitting large files into segments; [2] show ZFS incremental snapshots as files; [3] transparent filesystem compression; [4] and [5] options for mounting archives as filesytems. - [0] https://github.com/libfuse/libfuse/tree/master/example - [1] https://github.com/seiferma/splitviewfuse - [2] https://github.com/UNFmontreal/zfs_fuse_snapshot - [3] https://github.com/FS-make-simple/fusecompress - [4] https://github.com/google/fuse-archive
Read the rest
In Started a guide to writing FUSE filesystems in Python

Ask HN: A better Criu Alternative for decompression software / Erlang?

So Criu (https://criu.org/) , is a checkpoint restore utility which could be used with docker. Now the main use case of this is docker live migration from which I learned something But I also realised that this allows (atleast on linux) (though you could use wsl on windows) to allow decompression software like winrar , peazip etc. or cli tools like unrar-free to shutdown while the decompression is taking place and also erlang + criu just feels like a very awesome combination Now we could do something like this by taking random access (https://github.com/mxmlnkn/ratarmount) but I was wondering about this if we could have some sort of backup software where it would continue downloading the file right from where its left even the computer shuts down. and though there is dmtcp , I am not exactly sure if that's the right cause since on criu's
Read the rest
website comparing this. It says "Such behavior is very dangerous, as application might see wrong files in the /proc filesystem if it will try to access one via its PID." Now I was wondering if we could have a general sort of Virtual Machine which could run a specific language (especially the erlang , especially erlang with its let it fail approach could be nice) / For decompression software as well. Is criu the best we can get within the linux world , has somebody thought of creating a very lightweight os meant to be as a virtual machine with checkpoint / restore. Or could we rather instead of Criu , actually try to do this without Criu , right in the decompression software tooling ? I am somewhat confused about this , and I would really like it if someone with experience could simplify where I should try to put my efforts into doing such project
2 points · Open discussion
mxmlnkn·Sep 4, 2023Submission

Show HN: Rapidgzip – Truly Parallel Gzip Decompression with 10 GB/s

I have posted a much earlier version of this over a year ago [0]. Since then a lot has changed. Obviously, the name has changed. This happened for the paper publication [1]. I have also optimized the speed, integrated ISA-L for special cases, limited the compression-ratio-dependent maximum memory consumption, and finally added parallelized CRC32 computation, which adds ~5% overhead no matter the number of cores used. At this point, I am leaning towards calling it production-ready although there are still many ideas for improvements. Redoing the benchmarks of the older Show HN, would look like this: time pigz -d -c 4GiB-base64.gz | wc -c # real ~13.4 s -> ~320 MB/s time rapidgzip -d -c 4GiB-base64.gz | wc -c # real ~1.26 s -> ~3.4 GB/s However, at this point, the piping itself becomes a problem. Rapidgzip is actually
Read the rest
slightly faster than cat when comparing the piped bandwidth! E.g., compare these additional benchmarks: time cat 4GiB-base64.gz | wc -c # real ~1.06 s -> ~3.1 GB/s time fcat 4GiB-base64.gz | wc -c # real ~0.41 s -> ~8.0 GB/s time rapidgzip -o /dev/null -d 4GiB-base64.gz # real ~0.68 s -> ~6.5 GB/s fcat is an alternative cat implementation that uses vmsplice to speed up piping. According to the ReadMe it currently is broken, but it works fine on my system and piping it to md5sum yields consistent results [2]. So, at this point, I/O and actually also allocations have become a limiting factor and if you want full speed, you would have to interface with the rapidgzip library interface directly (in C++ or via the Python bindings) and process the decompressed data in memory. The project ReadMe contains further benchmarks with Silesia and FASTQ data and scaling up to 128 cores, for which rapidgzip achieves 12 GB/s for Silesia and 24 GB/s when an index has been created with --export-index and is used with --import-index. It can also be tested with ratarmount 0.14.0, which now uses rapidgzip as a backend by default for .gz and .tar.gz files [3]. [0] https://news.ycombinator.com/item?id=32366959 [1] https://dl.acm.org/doi/10.1145/3588195.3592992 [2] https://github.com/mre/fcat [3] https://github.com/mxmlnkn/ratarmount
35 points · Open discussion
This is basically the same reason why I started with ratarmount (https://github.com/mxmlnkn/ratarmount) but the focus was more on runtime performance and random access and as the name suggests it started out with access to recursive tar archives. The current version should also work for your use case with recursive zips. Recursive loading must be enabled with `--recursive`. It can also be used as a Python library without FUSE.
In Ask HN: Most interesting tech you built for just yourself?
Pragzip actually decompress in parallel and also access at random. I did a Show HN here: https://news.ycombinator.com/item?id=32366959 indexed_gzip https://github.com/pauldmccarthy/indexed_gzip can also do random access but is not parallel. Both have to do a linear scan first though. The implementations however can do the linear scan on-demand, i.e., they scan only as far as needed. bzip2 works very well with this approach. xz only works with this approach when compressed with multiple blocks. Similar is true for zstd. For zstd, there also exists a seekable variant, which stores the block index at the end as metadata to avoid the linear scan. indexed_zstd offers random access to those files https://github.com/martinellimarco/indexed_zstd I wrote pragzip and also combined all of the other random access compression backends in ratarmount to
Read the rest
offer random access to TAR files that is magnitudes faster than archivemount: https://github.com/mxmlnkn/ratarmount
In How much faster is making a tar archive without gzip?

Showing the 15 most recent of 18 sources. Enable JavaScript to search and browse every indexed mention.

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.