2007-05-02 04:03:23 +00:00
|
|
|
Welcome to the AllMyData "tahoe" project. This project implements a secure,
|
|
|
|
distributed, fault-tolerant storage grid.
|
2007-03-28 17:48:29 +00:00
|
|
|
|
2007-04-30 20:06:09 +00:00
|
|
|
The basic idea is that the data in this storage grid is spread over all
|
2007-04-05 00:55:35 +00:00
|
|
|
participating nodes, using an algorithm that can recover the data even if a
|
|
|
|
majority of the nodes are no longer available.
|
|
|
|
|
2007-04-30 20:06:09 +00:00
|
|
|
The interface to the storage grid allows you to store and fetch files, either
|
2007-04-28 00:13:25 +00:00
|
|
|
by self-authenticating cryptographic identifier or by filename and path.
|
2007-03-28 17:48:29 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
See the web site for all kinds of information, news, and community
|
|
|
|
contributions, including prebuilt packages for Debian-like systems:
|
|
|
|
|
|
|
|
http://allmydata.org
|
|
|
|
|
2007-04-27 05:16:13 +00:00
|
|
|
|
2007-05-02 05:34:33 +00:00
|
|
|
LICENCE:
|
|
|
|
|
|
|
|
Tahoe is offered under the GNU General Public License (v2 or later), with
|
|
|
|
the added permission that, if you become obligated to release a derived work
|
|
|
|
under this licence (as per section 2.b), you may delay the fulfillment of
|
|
|
|
this obligation for up to 12 months. See the COPYING file for details.
|
|
|
|
|
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
GETTING THE SOURCE CODE:
|
2007-05-02 05:04:58 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
The code is available via darcs by running the following command:
|
2007-05-02 05:04:58 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
darcs get http://allmydata.org/source/tahoe/trunk tahoe
|
2007-04-30 05:16:33 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
Tarballs of sources are available at:
|
2007-04-30 05:16:33 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
http://allmydata.org/source/tahoe/
|
2007-04-30 05:16:33 +00:00
|
|
|
|
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
DEPENDENCIES:
|
2007-04-27 20:47:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
Note: All of the following dependencies can probably be installed through
|
|
|
|
your standard package management tool if you are running on a modern Unix
|
|
|
|
operating system.
|
2007-04-27 20:47:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
For example, on an debian-like system, you can do "sudo apt-get install
|
|
|
|
gcc make python-dev python-twisted python-nevow python-pyopenssl".
|
2007-04-27 20:47:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
+ a C compiler (language)
|
2007-03-28 17:48:29 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
+ GNU make (build tool)
|
2007-04-27 05:16:13 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
+ Python 2.4 or newer (tested against 2.4, and 2.5.1, but v2.5 or higher
|
|
|
|
is required on Windows-native), including development headers (language)
|
2007-04-27 05:16:13 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
http://python.org/
|
2007-04-27 04:00:49 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
+ Python Twisted (tested against both 2.4 and 2.5) (network and operating
|
|
|
|
system integration library)
|
2007-04-30 04:56:23 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
http://twistedmatrix.com/
|
2007-04-26 21:28:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
You need the following subpackages, which are included in the default
|
|
|
|
Twisted distribution:
|
2007-04-26 21:28:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
* core (the standard Twisted package)
|
|
|
|
* web, trial, conch
|
2007-04-30 04:56:23 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
Twisted requires zope.interface, a copy of which is included in the
|
|
|
|
Twisted distribution.
|
2007-04-26 21:28:15 +00:00
|
|
|
|
2007-05-16 15:34:33 +00:00
|
|
|
+ Python Nevow (0.9.0 or later) (web presentation language)
|
2007-04-26 21:28:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
http://divmod.org/trac/wiki/DivmodNevow
|
2007-04-26 21:28:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
+ Python setuptools (build and distribution tool)
|
2007-04-30 04:56:23 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
Note: The build process will automatically download and install
|
|
|
|
setuptools if it is not present. However, if an old, incompatible
|
|
|
|
version of setuptools (< v0.6c3) is present, then the build will fail.
|
|
|
|
Therefore, if the build fails due to setuptools not being compatible,
|
|
|
|
you can either upgrade or uninstall your version of setuptools and try
|
|
|
|
again.
|
2007-04-26 21:28:15 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
http://peak.telecommunity.com/DevCenter/EasyInstall#installation-instructions
|
2007-04-30 04:56:23 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
+ Python PyOpenSSL (0.6 or later) (secure transport layer)
|
2007-04-27 04:00:49 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
http://pyopenssl.sourceforge.net
|
2007-05-01 19:41:35 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
To install PyOpenSSL on Windows-native, download this:
|
|
|
|
http://allmydata.org/source/pyOpenSSL-0.6.win32-py2.5.exe
|
2007-04-26 21:28:15 +00:00
|
|
|
|
2007-05-16 15:34:33 +00:00
|
|
|
To install PyOpenSSL on Windows-cygwin, install the OpenSSL development
|
|
|
|
libraries with the cygwin package management tool, then get the pyOpenSSL
|
|
|
|
source code, cd into it, and run "python ./setup.py install".
|
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
+ the pywin32 package: only required on Windows
|
2007-04-30 04:56:23 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
http://sourceforge.net/projects/pywin32/
|
2007-04-30 19:48:30 +00:00
|
|
|
|
2007-04-27 05:16:13 +00:00
|
|
|
|
2007-05-16 01:13:02 +00:00
|
|
|
Tahoe uses a few additional libraries which are included in this source
|
|
|
|
distribution for convenience. These will be automatically built when you type
|
|
|
|
'make', but if you have separate installations of them you may wish to modify
|
|
|
|
the makefile to use those in preference to the included versions. They
|
|
|
|
include Foolscap (a secure remote-object-invocation library), zfec (erasure
|
|
|
|
coding), and a modified version of PyCrypto (enhanced to provide a faster
|
|
|
|
CTR-mode API).
|
|
|
|
|
|
|
|
|
2007-03-28 17:48:29 +00:00
|
|
|
BUILDING:
|
|
|
|
|
2007-05-02 05:40:24 +00:00
|
|
|
Just type 'make' in the top-level tahoe directory. This works on Windows
|
2007-05-02 05:37:35 +00:00
|
|
|
too, provided that you have the dependencies mentioned above (either a
|
2007-05-02 05:44:33 +00:00
|
|
|
normal cygwin build or a mingw-style native build will be done by the
|
|
|
|
makefile, depending on whether the version of python that you have installed
|
|
|
|
is the Windows-native python or the cygwin python.)
|
2007-04-09 23:14:44 +00:00
|
|
|
|
|
|
|
If the desired version of 'python' is not already on your PATH, then type
|
|
|
|
'make PYTHON=/path/to/your/preferred/python'.
|
2007-03-28 17:48:29 +00:00
|
|
|
|
2007-05-02 05:52:40 +00:00
|
|
|
'make test-all' runs the unit test suites. (This can take a long time on
|
|
|
|
slow computers. There are a lot of tests and some of them do a lot of
|
|
|
|
public-key cryptography.)
|
2007-03-28 17:48:29 +00:00
|
|
|
|
2007-04-27 05:16:13 +00:00
|
|
|
|
2007-04-05 00:55:35 +00:00
|
|
|
INSTALLING:
|
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
There are three ways to do it. Choose one:
|
|
|
|
|
2007-04-30 05:16:33 +00:00
|
|
|
The Debian Way:
|
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
The Debian Way is to build .deb files which you can then install with
|
|
|
|
"dpkg".
|
|
|
|
|
2007-05-02 06:38:39 +00:00
|
|
|
This requires the debian packages build-essential, fakeroot, devscripts,
|
|
|
|
and the packages listed as "Build-Depends" in the DIST/debian/control in
|
|
|
|
the top-level tahoe directory, replacing the word DIST with etch, dapper,
|
|
|
|
edgy, or feisty as appropriate:
|
2007-05-02 06:11:05 +00:00
|
|
|
|
2007-05-02 05:11:49 +00:00
|
|
|
If you're running on a debian system, run 'make deb-dapper', 'make
|
|
|
|
deb-sid', 'make deb-edgy', or 'make deb-feisty', from within the tahoe
|
|
|
|
top-level directory, to construct two debian packages named
|
2007-05-02 06:38:39 +00:00
|
|
|
'allmydata-tahoe' and 'python-foolscap' which you can then install with
|
|
|
|
dpkg.
|
2007-04-30 05:16:33 +00:00
|
|
|
|
|
|
|
The Python Way:
|
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
The Python Way is to execute "setup.py install" for each Python package.
|
|
|
|
|
|
|
|
You'll need to run "setup.py install" four separate times, one for each of
|
|
|
|
the four subpackages (allmydata, allmydata.Crypto, foolscap, and zfec). If
|
|
|
|
you use GNU stow, add the options "--prefix=." and
|
2007-04-30 05:16:33 +00:00
|
|
|
"--root=/usr/local/stow/${PACKAGE}" to the "setup.py install" command.
|
2007-04-05 00:55:35 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
for PACKAGE in zfec Crypto foolscap ; do
|
|
|
|
cd src/${PACKAGE} && python setup.py install && cd ../..
|
|
|
|
done
|
2007-04-05 00:55:35 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
# the tahoe subpackage's setup.py script is in the root directory
|
|
|
|
PACKAGE=tahoe
|
|
|
|
python setup.py install
|
2007-04-05 00:55:35 +00:00
|
|
|
|
2007-04-30 05:16:33 +00:00
|
|
|
The Running-In-Place Way:
|
2007-04-05 00:55:35 +00:00
|
|
|
|
2007-05-02 19:54:26 +00:00
|
|
|
The Running-In-Place Way is to add a directory to your PYTHONPATH.
|
|
|
|
|
2007-04-30 05:16:33 +00:00
|
|
|
To run from a source tree (without installing first), type 'make', which
|
|
|
|
will put all the necessary libraries into a local directory named
|
2007-05-01 00:49:10 +00:00
|
|
|
"./instdir/lib", which you can then add to your PYTHONPATH . (It will put
|
|
|
|
executables into "./instdir/bin".)
|
2007-04-30 04:56:23 +00:00
|
|
|
|
2007-04-05 00:55:35 +00:00
|
|
|
|
2007-05-02 06:42:01 +00:00
|
|
|
TESTING THAT IT IS PROPERLY INSTALLED
|
|
|
|
|
|
|
|
To test that all the modules got installed properly, start a python
|
2007-05-02 19:54:26 +00:00
|
|
|
interpreter and import modules as follows. If each one imports successfully
|
|
|
|
instead of raising ImportError then it is correctly installed.
|
|
|
|
|
|
|
|
% python
|
|
|
|
Python 2.4.4 (#2, Jan 13 2007, 17:50:26)
|
|
|
|
[GCC 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)] on linux2
|
|
|
|
Type "help", "copyright", "credits" or "license" for more information.
|
|
|
|
>>> import zfec
|
|
|
|
>>> import allmydata.Crypto
|
|
|
|
>>> import foolscap
|
|
|
|
>>> import allmydata.interfaces
|
2007-04-05 00:55:35 +00:00
|
|
|
|
2007-03-28 17:48:29 +00:00
|
|
|
|
|
|
|
RUNNING:
|
|
|
|
|
2007-05-02 04:03:23 +00:00
|
|
|
If you installed one of the debian packages constructed by "make deb-*",
|
|
|
|
then it creates an 'allmydata-tahoe' executable, usually in /usr/bin . If
|
|
|
|
you didn't install a package you can find allmydata-tahoe in ./instdir/bin/
|
|
|
|
. This tool is used to create, start, and stop nodes. Each node lives in a
|
2007-05-01 00:49:10 +00:00
|
|
|
separate base directory, inside of which you can add files to configure and
|
2007-05-02 04:03:23 +00:00
|
|
|
control the node. Nodes also read and write files within that directory.
|
2007-04-20 00:30:21 +00:00
|
|
|
|
2007-04-30 20:06:09 +00:00
|
|
|
A grid consists of a single central 'introducer and vdrive' node and a large
|
2007-05-02 04:03:23 +00:00
|
|
|
number of 'client' nodes. If you are joining an existing grid, the
|
2007-04-30 16:57:52 +00:00
|
|
|
introducer-and-vdrive node will already be running, and you'll just need to
|
2007-05-02 04:03:23 +00:00
|
|
|
create a client node. If you're creating a brand new grid, you'll need to
|
2007-04-30 16:57:52 +00:00
|
|
|
create both an introducer-and-vdrive and a client (and then invite other
|
2007-04-30 20:06:09 +00:00
|
|
|
people to create their own client nodes and join your grid).
|
2007-04-30 16:57:52 +00:00
|
|
|
|
|
|
|
The introducer (-and-vdrive) node is constructed by running 'allmydata-tahoe
|
2007-05-02 04:03:23 +00:00
|
|
|
create-introducer --basedir $HERE'. Once constructed, you can start the
|
2007-04-20 00:30:21 +00:00
|
|
|
introducer by running 'allmydata-tahoe start --basedir $HERE' (or, if you
|
|
|
|
are already in the introducer's base directory, just type 'allmydata-tahoe
|
2007-05-02 04:03:23 +00:00
|
|
|
start'). Inside that base directory, there will be a pair of files
|
|
|
|
'introducer.furl' and 'vdrive.furl'. Make a copy of these, as they'll be
|
2007-04-20 00:30:21 +00:00
|
|
|
needed on the client nodes.
|
2007-03-28 17:48:29 +00:00
|
|
|
|
|
|
|
To construct a client node, pick a new working directory for it, then run
|
2007-05-02 04:03:23 +00:00
|
|
|
'allmydata-tahoe create-client --basedir $HERE'. Copy the two .furl files
|
2007-04-20 00:30:21 +00:00
|
|
|
from the introducer into this new directory, then run 'allmydata-tahoe start
|
2007-05-02 04:03:23 +00:00
|
|
|
--basedir $HERE'. After that, the client node should be off and running.
|
|
|
|
The first thing it will do is connect to the introducer and introduce itself
|
|
|
|
to all other nodes on the grid. You can follow its progress by looking at
|
|
|
|
the $HERE/twistd.log file.
|
2007-03-28 17:48:29 +00:00
|
|
|
|
|
|
|
To actually use the client, enable the web interface by writing a port
|
|
|
|
number (like "8080") into a file named $HERE/webport and then restarting the
|
2007-05-02 04:03:23 +00:00
|
|
|
node with 'allmydata-tahoe restart --basedir $HERE'. This will prompt the
|
2007-03-28 17:48:29 +00:00
|
|
|
client node to run a webserver on the desired port, through which you can
|
|
|
|
view, upload, download, and delete files.
|
|
|
|
|
2007-04-27 03:16:48 +00:00
|
|
|
A client node directory can also be created without installing the code
|
2007-05-02 04:03:23 +00:00
|
|
|
first. Just use 'make create-client', and a new directory named 'CLIENTDIR'
|
|
|
|
will be created inside the top of the source tree. Copy the relevant .furl
|
2007-04-27 03:16:48 +00:00
|
|
|
files in, set the webport, then start the node by using 'make start-client'.
|
2007-05-02 04:03:23 +00:00
|
|
|
To stop it again, use 'make stop-client'. Similar makefile targets exist
|
|
|
|
for making and running an introducer node.
|
2007-04-27 03:16:48 +00:00
|
|
|
|
2007-05-02 04:03:23 +00:00
|
|
|
There is a public grid available for testing. Look at the wiki page
|
2007-04-27 03:16:48 +00:00
|
|
|
(http://allmydata.org) for the necessary .furl data.
|
2007-04-28 00:13:25 +00:00
|
|
|
|