BT服务器搭建

系统:Ubuntu16.04
IP:192.168.64.130
环境:python 2.7

安装bittorrent

此处有提供
https://blog.csdn.net/qq_25672665/article/details/81586640
下载并安装
https://pan.baidu.com/s/1GKjGawhvZeSlEvJ5fTVgkg 密码:cef5

python setup.py install 
启动tracker
bttrack.py --port 6969 --dfile /tmp/bttrack.log &
制作种子
btmaketorrent.py http://192.168.64.130:6969/announce /root/resource/BitTorrent-4.0.3.tar.gz
发布种子

使用apache或者bt自带工具

btlaunchmany.py --data_dir /root/resource --torrent_dir  /root/resource
下载

注意防火墙和权限,下载种子并用bt客户端(如迅雷)下载测试。

查看其他信息

查看种子详情:

root@ubuntu:~/resource# btshowmetainfo.py BitTorrent-4.0.3.tar.gz.torrent 
btshowmetainfo 20021207 - decode BitTorrent metainfo files

metainfo file.: BitTorrent-4.0.3.tar.gz.torrent
info hash.....: 6656a3bcc84c63dfe3eb461b21b147439e7c2f5b
file name.....: BitTorrent-4.0.3.tar.gz
file size.....: 157027 (0 * 262144 + 157027)
announce url..: http://192.168.64.130:6969/announce

可以从此处http://192.168.64.130:6969/查看bt下载的详情
在这里插入图片描述

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值