全球主机交流论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

IP归属甄别会员请立即修改密码
查看: 11317|回复: 40
打印 上一主题 下一主题

[疑问] Debian 10/Ubuntu 20.04 安装 qBitTorrent

  [复制链接]
跳转到指定楼层
1#
发表于 2021-6-23 22:55:36 | 只看该作者 回帖奖励 |正序浏览 |阅读模式
本帖最后由 zxxx 于 2021-6-23 23:23 编辑

查看版本

  1. # lsb_release -a
  2. No LSB modules are available.
  3. Distributor ID: Ubuntu
  4. Description:    Ubuntu 20.04.2 LTS
  5. Release:        20.04
  6. Codename:       focal
复制代码


升级系统

  1. apt update && apt upgrade
  2. apt install automake build-essential libtool pkg-config
复制代码


安装 libtorrent

https://github.com/arvidn/libtorrent/releases

https://github.com/arvidn/libtorrent/releases/download/v2.0.4/libtorrent-rasterbar-2.0.4.tar.gz


  1. apt install libssl-dev libgeoip-dev libboost-dev libboost-system-dev libboost-chrono-dev libboost-random-dev

  2. cd /usr/local/src

  3. wget https://github.com/arvidn/libtorrent/releases/download/v1.2.14/libtorrent-rasterbar-1.2.14.tar.gz
  4. tar zxvf libtorrent-rasterbar-1.2.14.tar.gz
  5. cd libtorrent-rasterbar-1.2.14
  6. ./configure --disable-debug --enable-encryption --with-libgeoip=system
  7. make -j $(nproc)
  8. make install
  9. ldconfig
复制代码


安装 qbittorrent

https://github.com/qbittorrent/qBittorrent/releases

  1. apt install qtbase5-dev qttools5-dev-tools libqt5svg5-dev zlib1g-dev
  2. cd /usr/local/src
  3. wget https://github.com/qbittorrent/qBittorrent/archive/refs/tags/release-4.3.5.tar.gz
  4. tar zxvf release-4.3.5.tar.gz
  5. cd qBittorrent-release-4.3.5
  6. ./configure --disable-gui --disable-debug
  7. make -j$(nproc)
  8. make install
复制代码



启动 qbittorrent

  1. qbittorrent-nox
复制代码


首次启动 请安 y 接受确认,接着按 Ctrl+c 退出,启动后台运行

创建服务

  1. cat << "EOF" > /etc/systemd/system/qbittorrent.service
  2. [Unit]
  3. Description=qBittorrent Daemon Service
  4. After=network.target

  5. [Service]
  6. LimitNOFILE=512000
  7. User=root
  8. ExecStart=/usr/local/bin/qbittorrent-nox
  9. ExecStop=/usr/bin/killall -w qbittorrent-nox

  10. [Install]
  11. WantedBy=multi-user.target
  12. EOF
复制代码


启用服务

  1. systemctl enable qbittorrent.service
复制代码


启动服务

  1. systemctl start qbittorrent.service
复制代码


访问 WebUI:

http://你的IP:8080/

默认用户名:admin
默认密码:adminadmin



推荐
发表于 2021-6-23 23:09:43 | 只看该作者
使用 docker 方便, 不是KVM才要自己编译
一键脚本 ,选择 7 自动安装,而且支持 ARM64 甲骨文这些
  1. wget git.io/autopt.sh && bash autopt.sh
复制代码


推荐
发表于 2021-6-24 00:03:18 | 只看该作者
太复杂了,直接下载编译好的版本就行了:https://github.com/userdocs/qbittorrent-nox-static/releases
比如
  1. wget https://github.com/userdocs/qbittorrent-nox-static/releases/download/release-4.3.5_v2.0.4/x86_64-qbittorrent-nox
  2. chmod +x x86_64-qbittorrent-nox
  3. ./x86_64-qbittorrent-nox -d
复制代码
40#
发表于 2021-7-13 15:46:56 | 只看该作者
来自未来的家伙 发表于 2021-7-13 15:42
这个就是不知道用什么命令重启有大佬知道么?

自己写成 service 用 systemctl 管理
39#
发表于 2021-7-13 15:42:45 | 只看该作者
这个就是不知道用什么命令重启有大佬知道么?
38#
发表于 2021-7-13 15:42:25 | 只看该作者
zxxx 发表于 2021-6-23 23:12
我是 OpenVZ 的机器

OVZ 7 版本是可以 docker 的
37#
发表于 2021-7-13 15:41:21 | 只看该作者
hostloc8888 发表于 2021-6-24 00:03
太复杂了,直接下载编译好的版本就行了:https://github.com/userdocs/qbittorrent-nox-static/releases
比 ...

下载放到公用目录 /usr/bin,就可以全局使用了
36#
 楼主| 发表于 2021-7-13 15:38:25 | 只看该作者
马化滕 发表于 2021-7-13 15:30
这样写吗:./x86_64-qbittorrent-nox --webui-port=  好像不太行 我试了
            

防火墙方形 2018 了么
35#
发表于 2021-7-13 15:30:40 | 只看该作者
zxxx 发表于 2021-7-11 12:16
./x86_64-qbittorrent-nox --help
使用:
    ./x86_64-qbittorrent-nox [options] [( | )...]


这样写吗:./x86_64-qbittorrent-nox --webui-port=<2018>  好像不太行 我试了
            

  Windows 10 专业预览版 【Win Next ◆ 20161.1000.rs

Google Chrome【Chromium 86.0.4193.0

Intel(R)Core(TM)CPU【I9-9900ks @ 4.50 GHz】
34#
 楼主| 发表于 2021-7-11 15:02:47 | 只看该作者
bbsbbs 发表于 2021-7-11 14:48
可以的,很方便。迁移过很多次,备份好下面的目录文件即可,下载路径需要保持一致。
SCP命令简单粗暴。

好的,我找找qb的路径和文件。
33#
发表于 2021-7-11 14:48:45 | 只看该作者
本帖最后由 bbsbbs 于 2021-7-11 14:49 编辑
zxxx 发表于 2021-7-11 12:56
请教那个方便迁移?

把一个机器上的种子和文件迁移到另外一个机器上,不用重新下载就可以继续做种。 ...


可以的,很方便。迁移过很多次,备份好下面的目录文件即可,下载路径需要保持一致。
SCP命令简单粗暴。
  1. drwxr-xr-x    2 root     root          4096 Apr 17 17:09 blocklists
  2. -rw-------    1 transmis root           610 Mar 12  2019 dht.dat
  3. drwxr-xr-x    2 root     root        122880 Jul 11 14:43 resume
  4. -rw-------    1 root     root          2387 Jul  2 16:17 settings.json
  5. -rw-------    1 root     root           164 Jul 11 14:43 stats.json
  6. drwxr-xr-x    2 root     root        155648 Jul  5 17:35 torrents
复制代码

32#
 楼主| 发表于 2021-7-11 12:56:47 | 只看该作者
bbsbbs 发表于 2021-7-11 12:38
我比较喜欢transmisssion-daemon

请教那个方便迁移?

把一个机器上的种子和文件迁移到另外一个机器上,不用重新下载就可以继续做种。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|手机版|小黑屋|全球主机交流论坛

GMT+8, 2025-11-2 22:58 , Processed in 0.079058 second(s), 11 queries , Gzip On, MemCache On.

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表