BTPD(1)

πŸ“¦ version 0.16, in ubuntu jammy, ubuntu noble, ubuntu resolute

✨ BTPD(1) β€” User Commands ✨

okay bestie, buckle UP, because this is the manual for btpd, aka the BitTorrent Protocol Daemon πŸ’… it's a User Commands situation and honestly it's giving "set it and forget it" energy fr fr


πŸŽ€ NAME πŸŽ€

btpd β€” BitTorrent Protocol Daemon


🌸 SYNOPSIS 🌸

btpd [-d dir] [-p port] [OPTIONS...]

πŸ¦‹ DESCRIPTION πŸ¦‹

So btpd is a utility for sharing files over the BitTorrent network protocol, no cap. The way it works is it runs in daemon mode, which means it needs literally no controlling terminal and no GUI. It just vibes in the background doing its thing 🌈

Instead of you tapping at it directly, the daemon gets controlled by btcli, its control utility, or by any other program that's capable of sending commands and queries on the control socket. iykyk πŸ”₯

btpd is actually a whole little squad of programs:

  • btpd β€” the bittorrent client.
  • btcli β€” command line interface to btpd.
  • btinfo β€” shows information from a torrent file.

And listen: all of these programs accept the --help option. every single one. go off kings πŸ‘‘


πŸ’– OPTIONS πŸ’–

  • -d dir β€” the path for the btpd directory. default is $HOME/.btpd.
  • -p n, --port n β€” listen at port n. default is 6881.
  • --help [mode] β€” show this text, or help for the specified mode.
  • -4 β€” use IPv4. if you give this in conjunction with -6, both versions are used.
  • -6 β€” use IPv6. by default IPv4 is used. unfortunately, enabling both IPv6 and IPv4 in btpd is less useful than it should be 😭 the problem is that some sites have trackers for both versions and it's likely that the IPv6 one, which probably has less peers, will be used in favour of the IPv4 one. not the serve we wanted.
  • --bw-in n β€” limit incoming BitTorrent traffic to n kB/s. default is 0, which means unlimited.
  • --bw-out n β€” limit outgoing BitTorrent traffic to n kB/s. default is 0, which means unlimited.
  • --empty-start β€” start btpd without any active torrents. clean slate, fresh era ✨
  • --ip addr β€” let the tracker distribute the given address instead of the one it sees btpd connect from.
  • --ipcprot mode β€” set the protection mode of the command socket. the mode is specified by an octal number. default is 0600.
  • --logfile file β€” where to put the logfile. by default it's put in the btpd dir.
  • --max-peers n β€” limit the amount of peers to n.
  • --max-uploads n β€” controls the number of simultaneous uploads. the possible values are:
    • n < -1 : choose n >= 2 based on --bw-out (default).
    • n = -1 : upload to every interested peer.
    • n = 0 : don't upload to anyone.
    • n > 0 : upload to at most n peers simultaneously.
  • --no-daemon β€” keep the btpd process in the foreground and log to std{out,err}. this option is intended for debugging purposes. yes, it's a debugging thing, don't make it your whole personality 🫢
  • --prealloc n β€” preallocate disk space in chunks of n kB. default is 2048. note that n will be rounded up to the closest multiple of the torrent piece size. if n is zero, no preallocation will be done.

πŸ‘‘ STARTING BTPD πŸ‘‘

To start btpd with default settings you literally only need to run it. no thoughts, head empty, just run it. but there are many useful options you may want to use, and to see a full list you run btpd --help. if you didn't specify otherwise, btpd starts with the same set of active torrents as it had the last time it was shut down. it remembers. it's loyal like that πŸ’œ

btpd 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.

It is recommended to specify the maximum number of uploads. BitTorrent employs a tit for tat algorithm, so uploading at good rates allows for downloading. try to find a balance between uploads/outgoing bandwidth and the number of active torrents.

Note: you should only need one instance of btpd regardless of how many torrents you want to share. one queen, many torrents, that's the vibe πŸ’…


⭐ EXAMPLES ⭐

Start btpd with all options set to their default values.

$ btpd

Start btpd as above, but with torrent data in the directory /var/torrents

$ btpd -d /var/torrents

Start btpd and make it listen on port 12345, limit outgoing bandwidth to 200kB/s, limit the number of peers to 40 and not start any torrents that were active the last time btpd was shut down.

$ btpd -p 12345 --bw-out 200 --max-peers 40 --empty-start

πŸ” TROUBLESHOOTING πŸ”

If btpd has shut down for some unknown reason, check the logfile for possible clues. the logfile is the group chat β€” it knows everything πŸ™ˆ


πŸ’€ BUGS πŸ’€

Known bugs are listed at http://github.com/queueRAM/btpd/issues

Before submitting a bug report, please verify that you are running the latest version of btpd. fr fr, check your version first, we're not doing that today 😭


🧚 AUTHORS 🧚

Current maintainers:

  • Marq Schneider <queueRAM@gmail.com>

Past contributors:

  • Richard Nyberg <btpd@murmeldjur.se>

🌈 SEE ALSO 🌈

btcli(1) btinfo(1)


and that's the whole page bestie πŸ’– this was BitTorrent Protocol Daemon 0.16, dated 2010-07-31 β€” yes it's an elder but it still ate, and it's still serving BTPD(1) energy. slay, go share some files, periodt πŸ‘‘βœ¨

πŸ“¦ where this page comes from