Mount a tar file – not possible

mounttarunix

It seems one cannot mount a tar file (read only), similarly as one mounts an ISO image file. At least, I have not found any implementation.

It would be useful, for example to run a find command inside.

Is this really (or practically) impossible to implement? Why?

UPDATE By accepted answered, this is indeed possible, though a program (not included in present distributions) must be instaled. It worked for me. I copy the installation and use steps in my scenario (Fedora 12).

  # yum install fuse fuse-libs fuse-devel 
  # yum install libarchive libarchive-devel
  # cd /tmp && wget http://www.cybernoia.de/software/archivemount/archivemount-0.6.0.tar.gz
  # tar xzf archivemount-0.6.0.tar.gz && cd archivemount-0.6.0
  # ./configure && make && make install
  # man archivemount
  #  archivemount -o ro /tmp/mytar.tgz /mnt/tt

Best Answer

Traditionally, no it's not possible.

However, you can do so using the FUSE filesystem archivemount under Linux.

IMNSHO this is a bit of a novelty and not usually necessary, but I can see a few edge cases for it.