Переглянути джерело

Rewrote the README with changes for 0.8..

master
Richard Nyberg 19 роки тому
джерело
коміт
4382442f11
1 змінених файлів з 119 додано та 40 видалено
  1. +119
    -40
      README

+ 119
- 40
README Переглянути файл

@@ -1,59 +1,138 @@
+ PROGRAMS The BitTorrent Protocol Daemon


btpd consists of the following programs: README
* btpd - The BitTorrent client.
* btcli - Command line interface to btpd.
* btinfo - Shows information from a torrent file.


All programs take the "--help" option. Contents
1 Introduction
1.a What is btpd?
1.b The programs
2. Using btpd
2.a Typical usage pattern
2.b Starting btpd
2.c Sharing torrents
2.d Information on active torrents
2.e Murder
3 Building
3.a Requirements
3.b Standard build


+ DIRECTORY STRUCTURE 1. Introduction


foo.torrent 1.a What is btpd?
The torrent metainfo file.


foo.torrent.d btpd is a BitTorrent client consisting of a daemon and client commands,
Content will be downloaded to, and uploaded from, this dir. which can be used to read and/or manipulate the daemon state. The daemon
It and its subdirectories and files will be created by is capable of running several torrents simultaneously and only uses one
btpd as it downloads them. tcp port. It's fairly low on resource usage and should be perfect for a
torrent distribution site. Efficient downloads and ease of use makes this
client a good choice for the casual user as well.


foo.torrent.i 1.b The programs
Created by 'btcli add'. Contains info on downloaded pieces.


+ SAMPLE USAGE btpd consists of the following programs:
* btpd - The BitTorrent client.
* btcli - Command line interface to btpd.
* btinfo - Shows information from a torrent file.


NOTE: Don't start one instance of btpd per torrent. You should only All programs accept the helpful "--help" option.
need one instance regardless of how many torrents you want to share.


Start btpd: 2. Using btpd
# btpd


Start downloading or seeding bar.torrent: 2.a Typical usage pattern
# btcli add /path/to/bar.torrent


List active torrents (only bar.torrent atm): When you use this client you will mostly use the btcli tool. With btcli
# btcli list you can tell btpd which torrents to run, list the active torrents and
display stats for them. You can even tell btpd to exit if you're so in-
clined. Before you can use this tool however, btpd must be started. The
typical usage pattern goes something like this:
1. start btpd.
2. add one or more torrents to btpd.
3. any of many different actions: display stats, add more or remove
torrents, go drink coffe, etc...
666. tell btpd to exit.


Show some stats: 2.b Starting btpd
# btcli stat


Stop downloading/seeding bar.torrent: NOTE: As described in the section above, you should only need one instance
# btcli del /path/to/bar.torrent of btpd regardless of how many torrents you want to share.


Shut down btpd (Why would you do such a thing?): To start btpd with default settings you only need to run it. There are
# btcli die however, many useful options you may want to use. To see a full list run
'btpd --help'.


+ BUILDING btdp will store information and write its log in $HOME/.btpd. Therefore
it needs to be able to write there during its execution. You can specify
another directory via the '-d' option or the $BTPD_HOME variable.


Make sure you have recent versions of the following software: I recommend specifiying the maximum number of uploads. BitTorrent employs a
* curl - Get at <URL:http://curl.haxx.se/> tit for tat algorithm, so uploading at good rates allows for downloading.
* openssl - Get at <URL:http://www.openssl.org/> Try to find a balance between uploads/outgoing bandwidth and the number of
* libevent - Get at <URL:http://www.monkey.org/~provos/libevent/> active torrents.


You also need a c99 compiler. A non antique GCC should do. 2.c Sharing torrents


# ./configure To make btpd start leeching or seeding a torrent you use the 'btcli add'
# make command. In similar vein the 'btcli del' command will make btpd stop shar-
# make install ing the torrent.


See ./configure --help for options if it fails. The first time you add a torrent you must specify where btpd should put
its content. This is not needed on subsequent add's of the same torrent
since btpd stores that information. Of course, if you move the content
directory between runs you need to specify it again.

Examples:
Add foo.torrent and download its content to the foo.content directory.
# btcli add -d foo.content foo.torrent

Stop sharing foo.torrent.
# btcli del foo.torrent

Start it again. Notice the absence of '-d foo.content'.
# btcli add foo.torrent

Add bar.torrent and place the content like the mainline client.
# btcli add --topdir -d . bar.torrent

2.d Information on active torrents

In case you're not happy only guessing about your torrents progress, or
can't remember which torrents are active, you may want to take a look at
the 'btcli stat' and 'btcli list' commands. 'btcli list' will, not totally
surprisingly, display a list of active torrents. 'btcli stat' will display
information such as rates and MBs uploaded and downloaded. See
'btcli --help stat' to make sense of it.

Each line 'btcli list' shows is prefixed by either '+', '-', 'S' or 'L'.
+ means the torrent hasn't been started yet, because btpd is checking
the content of either this or another torrent with '+'.
- means the torrent is being stopped.
S means btpd is seeding the torrent.
L means btpd is leeching the torrent.

2.e Murder

Too slay the innocent btpd process issue the command 'btcli kill'.
Horrible user!

3. Building

3.a Requirements

You should have a *BSD, Linux or sufficiently similar system with pthread
support.

Make sure you have recent versions of the following software:
* curl - Get at <URL:http://curl.haxx.se/>
* openssl - Get at <URL:http://www.openssl.org/>
* libevent - Get at <URL:http://www.monkey.org/~provos/libevent/>

You also need a c99 compiler. A non antique GCC should do.

3.b Standard build

# ./configure
# make
# make install

See './configure --help' for options if the above fails or you're overcome
by curiousity.

||||||
x
 
000:0
Завантаження…
Відмінити
Зберегти