Giter VIP home page Giter VIP logo

fatx's Introduction

fatxfs

fatxfs is a userspace filesystem driver for the FATX filesystem, a varient of FAT16/32 developed by Microsoft for the original Xbox console.

Status

Currently fatxfs provides only read access. Write functionality is in the works.

Platform Support

Currently targeting:

  • Linux-based systems, specifically Ubuntu 14.04, and
  • OS X 10.10.

Build via Docker

fatxfs can be easily built inside a Docker container. If you use this method, you can skip the prerequisites and build instructions below.

$ docker build -t fatxfs https://raw.githubusercontent.com/mborgerson/fatx/master/Dockerfile
$ docker run -it --rm fatxfs
# fatxfs --help

How to Build (Natively)

Prerequisites

Ubuntu

Assuming you already have typical build tools installed, install FUSE and CMake:

$ sudo apt-get install libfuse-dev cmake

OS X

Download Xcode (available from the App Store) to get command line tools.

Assuming you have homebrew installed, install pkgconfig and cmake:

$ brew install install pkgconfig cmake

Install FUSE for OS X:

  • Download the latest FUSE DMG image file at the FUSE for OS X homepage.
  • Mount the DMG and run the installer.
  • Restart your system.

Download Source

Clone the repository:

$ git clone https://github.com/mborgerson/fatx && cd fatx

Build

Create a build directory and run cmake to construct the Makefiles:

$ mkdir build && cd build
$ cmake ..

Finally, start the build:

$ make

How to Use

Firstly, you will need a raw disk image or block device to mount. Then, you can simply create a mountpoint and mount the "C drive" (default behavior). For example:

$ mkdir c_drive
$ ./fatxfs /dev/nbd0 c_drive
$ ls c_drive

You can specify the drive letter of the partition to mount:

$ ./fatxfs /dev/nbd0 e_drive --drive=e

Or, you can specify the offset and size of the partition manually:

$ ./fatxfs /dev/nbd0 c_drive --offset=0x8ca80000 --size=0x01f400000

Tips

Mounting a qcow Image

If your disk image is a qcow image, you can mount it as a network block device before mounting a partition on the device:

$ sudo apt-get install qemu-utils
$ sudo modprobe nbd max_part=8
$ sudo qemu-nbd --connect=/dev/nbd0 /path/to/your/image.qcow2
$ sudo chmod a+rwx /dev/nbd0

Unfortunately, on OS X, there is not a way to mount a qcow image like this (AFAIK). I recommend converting the qcow image to a raw disk image.

$ qemu-img convert /path/to/image.qcow /path/to/output.raw

Logging

For debug purposes, you can have fatxfs log operations to a file given by the --log option. You can control the amount of output using the --loglevel option.

License

Copyright (C) 2015  Matt Borgerson

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.

Credit

This project was made possible in part by the research done by Andrew de Quincey, Lucien Murray-Pitts, and Michael Steil. Thank you!

fatx's People

Contributors

mborgerson avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.