linux安装使用transmission下载器

linux安装使用transmission下载器

1. Transmission简介

Transmission是一个强大的BT工具,懂的自然懂哈。目前官网发布了多个版本可供下载使用,包括:Mac、GTK+、QT版本,还有Daemon版本。
Transmission支持DHT、Magnet Link、uTP以及PEX等特性。尤其是支持Magnet Link磁力链接下载十分重要,因为目前网上很多资源都是采用这种方式来分享的,而不是传统的.torrent文件,例如TPB、BTDigg。
linux下,Transmission软件包下面包含多个套件:

transmission-gtk: GTK+界面客户端。
transmission-qt: QT界面客户端。
transmission-cli: 命令行BT客户端。
transmission-daemon: 是一个Transmission的后台守护程序,本身不具备操作指令,只能通过Web客户端或者transmission-remote-cli来进行控制。这个程序特别适合安装在服务器上或者嵌入式系统中,以及一些没有显示器的设备上。
transmission-remote-cli: 用来控制transmission-daemon的命令套件,本身不具备下载BT的功能,只能够配合daemon使用。
根据需求只需要安装transmission-daemon即可。

2. Transmission安装

sudo apt-get install transmission-daemon

3.Transmission出现403的解决办法

403: Forbidden
Unauthorized IP Address.

Either disable the IP address whitelist or add your address to it.

If you're editing settings.json, see the 'rpc-whitelist' and 'rpc-whitelist-enabled' entries.

If you're still using ACLs, use a whitelist instead. See the transmission-daemon manpage for details.

编辑://etc/transmission-daemon/setting.json

rpc-whitelist

    "rpc-authentication-required": true,
    "rpc-bind-address": "0.0.0.0",
    "rpc-enabled": true,
    "rpc-host-whitelist": "*.*.*.*",	//白名单列表,英文逗号分隔
    "rpc-host-whitelist-enabled": false,	//白名单,禁用

要在进程停止情况下编辑保存才可用。

4.更换管理面板

下载第三方webUI:https://github.com/ronggang/transmission-web-control/releases

tar -zxvf XXX.tar.gz
sudo mv /usr/share/transmission/web /usr/share/transmission/web2
sudo cp ./src /usr/share/transmission/web

登陆:

192.168.1.*:9091

默认用户名密码:transmission transmission

用户名可在 /etc/transmission-daemon/setting.json中改名,当然也是要在进程停止情况下改

5、配置文件

{
    "alt-speed-down": 50,
    "alt-speed-enabled": false,
    "alt-speed-time-begin": 540,
    "alt-speed-time-day": 127,
    "alt-speed-time-enabled": false,
    "alt-speed-time-end": 1020,
    "alt-speed-up": 50,
    "bind-address-ipv4": "0.0.0.0",
    "bind-address-ipv6": "::",
    "blocklist-enabled": false,
    "blocklist-url": "http://www.example.com/blocklist",
    "cache-size-mb": 4,
    "dht-enabled": true,
    "download-dir": "/D",	//下载目录
    "download-limit": 100,
    "download-limit-enabled": 0,
    "download-queue-enabled": true,
    "download-queue-size": 10,	//下载线程数
    "encryption": 1,
    "idle-seeding-limit": 30,
    "idle-seeding-limit-enabled": false,
    "incomplete-dir": "/var/lib/transmission-daemon/Downloads",		//下载临时目录
    "incomplete-dir-enabled": false,
    "lpd-enabled": false,
    "max-peers-global": 200,
    "message-level": 1,
    "peer-congestion-algorithm": "",
    "peer-id-ttl-hours": 6,
    "peer-limit-global": 200,
    "peer-limit-per-torrent": 50,
    "peer-port": 51413,
    "peer-port-random-high": 65535,
    "peer-port-random-low": 49152,
    "peer-port-random-on-start": false,
    "peer-socket-tos": "default",
    "pex-enabled": true,
    "port-forwarding-enabled": false,
    "preallocation": 1,
    "prefetch-enabled": true,
    "queue-stalled-enabled": true,
    "queue-stalled-minutes": 30,
    "ratio-limit": 2,
    "ratio-limit-enabled": false,
    "rename-partial-files": true,
    "rpc-authentication-required": true,
    "rpc-bind-address": "127.0.0.1",
    "rpc-enabled": true,
    "rpc-host-whitelist": "*.*.*.*",	//rpc主机白名单
    "rpc-host-whitelist-enabled": false,	//是否启用白名单
    "rpc-password": "{7d79385f96477153e710580b1b990feec26786c3unVUt30h",	//webUI密码,可以是名文
    "rpc-port": 9091,
    "rpc-url": "/transmission/",
    "rpc-username": "admin",	//webUI用户名
    "rpc-whitelist": "127.0.0.1",	//白名单
    "rpc-whitelist-enabled": false,	//是否启用白名单
    "scrape-paused-torrents-enabled": true,
    "script-torrent-done-enabled": false,
    "script-torrent-done-filename": "",
    "seed-queue-enabled": false,
    "seed-queue-size": 10,
    "speed-limit-down": 100,
    "speed-limit-down-enabled": false,
    "speed-limit-up": 100,
    "speed-limit-up-enabled": false,
    "start-added-torrents": true,
    "trash-original-torrent-files": false,
    "umask": 18,
    "upload-limit": 100,
    "upload-limit-enabled": 0,
    "upload-slots-per-torrent": 14,
    "utp-enabled": true
}

二、Docker安装

docker hub :
https://hub.docker.com/r/linuxserver/transmission

sudo docker pull linuxserver/transmission

启动

docker run -d \
  --name=transmission \
  -e PUID=1000 \
  -e PGID=1000 \
  -e TZ=Asia/Shanghai \
  -e TRANSMISSION_WEB_HOME=/transmission-web-control/ \
  -e USER=root \
  -e PASS=sakurato \
  -p 9091:9091 \
  -p 51413:51413 \
  -p 51413:51413/udp \
  -v /root/transmission/config:/config \
  -v /root/transmission/downloads:/downloads \
  -v /root/transmission/watch:/watch \
  --restart unless-stopped \
  ghcr.io/linuxserver/transmission

docker-compose

docker-compose.yaml:
```yaml

version: “2.1”
services:
transmission:
image: lscr.io/linuxserver/transmission:latest
container_name: transmission
environment:
- PUID=1000
- PGID=1000
- TZ=Europe/London
- TRANSMISSION_WEB_HOME=/combustion-release/
- USER=admin
- PASS=123456
- WHITELIST=iplist #optional
- PEERPORT=peerport #optional
- HOST_WHITELIST=dnsname list #optional
volumes:
- /path/to/data:/config
- /path/to/downloads:/downloads
- /path/to/watch/folder:/watch
ports:
- 9091:9091
- 51413:51413
- 51413:51413/udp
restart: unless-stopped

运行:

docker-compose up -d


访问:
http://IP:9091

转载请注明来源,欢迎对文章中的引用来源进行考证,欢迎指出任何有错误或不够清晰的表达。可以在下面评论区评论,也可以邮件至 vault@coolxy.cn

×

喜欢就点赞,疼爱就打赏

github