Skip to content

jaylogue/retro-fuse

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

retro-fuse

A user-space filesystem (FUSE) for accessing ancient Unix filesystems.

retro-fuse provides a way to mount filesystems created by ancient Unix systems on modern OSes. The current version of retro-fuse supports mounting filesystems created by fifth, sixth and seventh-edition research Unix, as well as 2.9BSD and 2.11BSD. It can also initialize such filesystems.

The design of retro-fuse is novel in that it incorporates original source code from the historic Unix kernels. The ancient code has been "lightly modernized" to be palatable to current compilers and adapted to run in userspace. This approach (made possible by Caldera’s generous open source license for ancient Unix) allows retro-fuse to support both reading and writing of ancient filesystems, while ensuring the historical fidelity of on-disk structures.

retro-fuse provides support for a broad array of modern filesystem operations on top of the basic capabilities of the original code. This includes support for modern rename(2) semantics, filesystem statistics gathering (e.g. via statfs(2) / df(1)) and symlinks (where appropriate). The code also provides a C API with semantics that match modern Unix syscalls, making it possible to incorporate ancient filesystem access directly into other projects.

The current version of retro-fuse runs on Linux and MacOS.


Information on how to use retro-fuse can be found on the project’s Usage page.

Practical examples on how to use retro-fuse for common tasks are shown on the project’s Examples page.

To understand the retro-fuse architecture and code structure, see the Design page.

For latest information on retro-fuse development, see the project’s Development Blog


Building

Building retro-fuse on Linux requires the libfuse-dev package, which can be installed on Ubuntu/debian-based systems as follows:

$ sudo apt install libfuse-dev

On MacOS, retro-fuse requires the macFUSE sofware package, an installer for which can be downloaded from the macFUSE website.

After the prerequisites have been installed, run make to build the filesystem handler programs:

$ make

Testing

retro-fuse includes a set of functionality tests for each of the filesystem handlers. These tests perform various I/O operations on a mounted test filesystem to confirm the correct behavior as observed from the modern system. Additionally, the tests verify the fidelity of the generated filesystem images by mounting them in a simulated historic Unix system and checking filesystem’s integrity (using legacy tools such as icheck and fsck) and contents.

The functionality tests rely on simh and python3. Additionally, the tests use the Pexpect python module, which must be installed separately.

simh can be installed on Ubuntu/debian-based systems as follows:

$ sudo apt install simh

The Pexpect python module can be installed using pip:

$ pip3 install --user pexpect

To run the functionality tests, use the test make target:

$ make test

Individual filesystem handlers can be tested by directly running the retro-fuse-test.py driver script and passing a path to the handler program. Pass the -v option to see details about the tests being performed:

$ ./test/retro-fuse-test.py -v ./bsd29fs

License

The modern portions of retro-fuse are licensed under the Apache 2.0 license.

Code derived from ancient Unix source is licensed under Caldera open source license.

Release Notes

Version 8 / 2022/08/23 — Support for 32-bit RPi OS, minor bug fixes.

Version 7 / 2022/01/25 — Added support for initializing and mounting 2.11BSD filesystems. Fixed various bugs, big and small, in v6, v7 and 2.9BSD support. Improved functionality tests. Improved support for macOS.

Version 6 / 2021/12/19 — Added support for 2.9BSD filesystems. Implemented functionality tests for v6, v7 and 2.9BSD filesystem drivers. Fixed various bugs reported by users and uncovered by functionality tests.

Version 5 / 2021/11/10 — Various code restructuring and clean up. Fixed a few minor bugs. Improved Makefile.

Version 4 / 2021/11/06 — Added support for seventh-edition Unix filesystems.

Version 3 / 2021/03/27 — Added support for MacOS.

Version 2 / 2021/03/02 — Fixed bug in link(), unlink(), chmod() and chown() that caused the files modified time to be updated (this fixes problems with rsync). Minor modifications to error handling.

Version 1 / 2021/02/23 — Initial release.