Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

xv6::file_system re-implemented in Rust and FUSE.

License

NotificationsYou must be signed in to change notification settings

foreverbell/xv6fs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Reimplementation of the file system used byxv6in Rust and FUSE.

xv6's file system follows the early design of Linux's journaling file system(namely, extfs2), which supports recovery in presence of crash. For details,please refer to thexv6 book.

Normally, a file system should be abstracted into these layers.

  • disk
  • block cache
  • logging (journaling, transaction)
  • inode
  • directory
  • path resolution
  • file object / descriptor

We use FUSE's low level API, which manages these last two layers conforming withUnix. The remaining work is to implement the top five layers and cooperatethem with FUSE interface.

Notice: for convenience, we mock the disk with an array of contiguous 512 bytesin memory, with an interface providing synchronized atomic block read / write.This disk acts as a service running in a separated thread, and communicate withthe file system in a Go routine fashion (which should be similar to IDEinterruption implemented in xv6).

Quick Start

Preparations.

  • a nightly Rust compiler (known to compile withrustc 1.27.0-nightly).
  • libfuse-dev (ubuntu, find substitution for yourself if using other Linux distros).
$ make run

Then we have a mounted file system at./mnt/.

$cd mnt$ touch foobar

License

Conforming with xv6 (seeLICENSE).

About

xv6::file_system re-implemented in Rust and FUSE.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp