Skip to content

Commit 801dd32

Browse files
author
Fletcher Aksel
committed
add README
Signed-off-by: Fletcher Aksel <[email protected]>
1 parent decf15d commit 801dd32

File tree

1 file changed

+85
-0
lines changed

1 file changed

+85
-0
lines changed

README.md

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
# gettrackers
2+
3+
## Purpose
4+
5+
Fetches, filters, and structures public torrent tracker lists,
6+
grouping them into **priority tiers** optimized for use in qBittorrent and
7+
other compatible clients.
8+
9+
such as [ngosang's trackerslist](https://github.com/ngosang/trackerslist)
10+
11+
## Usage
12+
13+
```
14+
> gettrackers --help
15+
gettrackers is a CLI tool that downloads tracker URLs from configurable sources, filters them using a blocklist, and outputs them grouped by domain.
16+
17+
Usage:
18+
gettrackers [flags]
19+
gettrackers [command]
20+
21+
Available Commands:
22+
block Add a pattern to the blocklist
23+
completion Generate the autocompletion script for the specified shell
24+
config Manage configuration
25+
fetch Force download/update the cached sources file
26+
groups Output grouped tracker URLs (default command)
27+
help Help about any command
28+
show Show cached sources or blocklist
29+
30+
Flags:
31+
-h, --help help for gettrackers
32+
-o, --output string Write output to file instead of stdout
33+
-p, --start-priority int Output N blank lines before tracker groups (default: 0)
34+
35+
Use "gettrackers [command] --help" for more information about a command.
36+
```
37+
38+
note the source download file is cached for 24h.
39+
40+
## Backstory
41+
42+
found myself reviving a bunch of very old torrents, most of which no
43+
longer had working trackers listed in them. Some trackers were
44+
rejecting the client contacting too quickly, and realized this was because sometimes the all lists have http, https, and udp variants of the same tracker
45+
46+
so this program groups those into the same tier
47+
48+
## Tracker Tiering (Based on libtorrent)
49+
50+
in th underlying **libtorrent** library, which powers qBittorrent. Trackers are
51+
organized into **priority tiers**
52+
53+
### Tracker Tiers Redundancy and Announcement Logic
54+
55+
libtorrent use of tracker tiers are controlled by [two
56+
settings](https://www.libtorrent.org/reference-Settings.html#announce_to_all_trackers).
57+
58+
> `announce_to_all_trackers` controls how multi tracker torrents are treated.
59+
If this is set to true, all trackers in the same tier are announced to in
60+
parallel. If all trackers in tier 0 fails, all trackers in tier 1 are
61+
announced as well. If it's set to false, the behavior is as defined by the
62+
multi tracker specification.
63+
64+
> `announce_to_all_tiers` also controls how multi tracker torrents are
65+
treated. When this is set to true, one tracker from each tier is announced
66+
to. This is the uTorrent behavior. To be compliant with the Multi-tracker
67+
specification, set it to false.
68+
69+
this tool groups trackers with the same hostname, into the same priority
70+
tier, with the assumption that qBittorrent's default configuration is
71+
`announce_to_all_trackers` false, and `announce_to_all_tiers` true.
72+
73+
so `udp://` `http://` `https://` or different port numbers, with the same hostname all get grouped into the same tier.
74+
75+
### Defining Tiers in Tracker Lists
76+
77+
When a multi-line list of trackers is added to a torrent, qBittorrent
78+
interprets the structure as follows:
79+
80+
* **Same Tier (Group):** All consecutive trackers (each on a new line) areassigned to the **same priority tier**.
81+
82+
* **Next Tier (Priority Fallback):** A single **empty line** separates the
83+
current group, assigning the subsequent block of trackers to the **next
84+
priority level** (e.g., Tier 0, then Tier 1, etc.).
85+

0 commit comments

Comments
 (0)