Skip to content
forked from openzfs/zfs

CAS Data Engine - User Space implementation of a popular COW Data Engine - ZFS

Notifications You must be signed in to change notification settings

mayadata-io/cstor

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Repository files navigation

img

ZFS on Linux is an advanced file system and volume manager which was originally developed for Solaris and is now maintained by the OpenZFS community.

codecov

Official Resources

Installation

Full documentation for installing ZoL on your favorite Linux distribution can be found at our site.

Contribute & Develop

We have a separate document with contribution guidelines.

Building

In addition to standard dependencies of ZFS on Linux project following packages need to be installed:

sudo apt-get install libaio-dev libgtest-dev cmake libjemalloc-dev

Google test framework library does not have a binary package so it needs to be compiled manually:

cd /usr/src/gtest
sudo cmake -DBUILD_SHARED_LIBS=ON CMakeLists.txt
sudo make

# copy or symlink libgtest.a and libgtest_main.a to your /usr/lib folder
sudo cp *.so /usr/lib

Special configure option --enable-debug should be used in order to create zfs and zpool commands which don't call into the kernel using ioctls, but instead call into uZFS process for serving "ioctls" using tcp connection. Other than that the build steps are the same as for ZoL:

./autogen.sh
CFLAGS="-g -O0" ./configure --enable-debug --enable-uzfs=yes
make

Running uzfs

This assumes that you have configured zfs with --enable-uzfs=yes option. To try zpool and zfs commands, start cmd/tgt/tgt binary with sudo and leave it running. Now zpool and zfs commands from cmd/ directory can be used in usual way.

Caveats

Disk write cache must be disabled for any device not managed by linux sd driver. Cache flush is not supported for other drivers than sd.

Contributing

Make sure to run cstyle on your changes before you submit a pull request:

make cstyle

And assure that the tests are passing. For possible tests to run see .travis.yml file in root directory. Here is an example of running a couple of available tests:

cmd/ztest/ztest -V
tests/cbtest/gtest/test_uzfs
sudo tests/cbtest/script/test_uzfs.sh

About

CAS Data Engine - User Space implementation of a popular COW Data Engine - ZFS

Topics

Resources

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C 75.8%
  • Shell 18.1%
  • C++ 1.5%
  • Assembly 1.4%
  • M4 1.3%
  • Makefile 0.8%
  • Other 1.1%