this post was submitted on 19 Jan 2025
27 points (96.6% liked)

Piracy: ꜱᴀɪʟ ᴛʜᴇ ʜɪɢʜ ꜱᴇᴀꜱ

55789 readers
562 users here now

⚓ Dedicated to the discussion of digital piracy, including ethical problems and legal advancements.

Rules • Full Version

1. Posts must be related to the discussion of digital piracy

2. Don't request invites, trade, sell, or self-promote

3. Don't request or link to specific pirated titles, including DMs

4. Don't submit low-quality posts, be entitled, or harass others



Loot, Pillage, & Plunder

📜 c/Piracy Wiki (Community Edition):


💰 Please help cover server costs.

Ko-Fi Liberapay
Ko-fi Liberapay

founded 2 years ago
MODERATORS
 

i want to remove specific trackers from all my torrents (they're discontinued), it's not doable with a per-torrent method as i would never finish.

I'm using qbittorrent v5.0.3 WebUI, i cannot just select the trackers i wish to remove under the "trackers" pane in the left side as it only allows me to remove all torrents with this tracker (i do not wish to remove the torrents), and not remove the tracker.

how can i remove these trackers from all my torrents easily, while keeping the torrents for seeding?

top 8 comments
sorted by: hot top controversial new old
[–] 12510198@lemmy.blahaj.zone 10 points 1 week ago

Heres a python script I made up from just modifying another script I use, it depends on qbittorrent-api, but to use just fill out the connection info and add all the trackers you want to remove in the TRACKERS array, I've included 2 rarbg trackers just as an example.

#!/usr/bin/env python3
import qbittorrentapi
import sys

TRACKERS = [
        "udp://9.rarbg.to:2770/announce",
        "udp://9.rarbg.me:2730/announce"
 ]

conn_info = dict(
    host     = "qbittorrent.localhost",
    port     = 80,
    username = "admin",
    password = "PASSWORD"
)

def main (argv, argc):
    qbt_client = qbittorrentapi.Client(**conn_info)

    try:
        qbt_client.auth_log_in()
    except qbittorrentapi.LoginFailed as e:
        print(e)
        return 1

    for torrent in qbt_client.torrents_info():
        #urls = []
        #for tracker in torrent.trackers:
            #print(tracker)
            #urls.append(tracker.url)
        
        torrent.remove_trackers(urls=TRACKERS)

        #torrent.add_trackers(urls=TRACKERS)

    qbt_client.auth_log_out()
    return 0

if __name__ == "__main__":
    sys.exit(main(sys.argv, len(sys.argv)))
[–] unknowing8343@discuss.tchncs.de 9 points 1 week ago (2 children)

Is there any benefit to that aside from cleanliness?

[–] ExcessShiv@lemmy.dbzer0.com 7 points 1 week ago* (last edited 1 week ago) (2 children)

I'm not entirely sure TBH, it's on a private tracker so I'm not sure I should be using them when they've chosen to discontinue them? Either way, if just for cleanliness it would still be nice.

[–] gila@lemm.ee 4 points 1 week ago

How were the trackers added to these torrents? Assuming either a) you added them manually, or b) the tracker you downloaded the torrent files from bundled them into the torrent file?

If b), if you downloaded the torrent file again now that one of its trackers is defunct, would it still be bundled?

If no, or if a), you could remove the torrents without touching the downloaded data, then locate your "snatch list" on the private tracker (a list of all torrents you've downloaded), batch download them all and add them to qbt, assuming same output folder they will detect the downloaded files and go to 100% without downloading anything.

If yes, there isnt a way I can think of to remove the trackers as a batch, but aside from tidiness of your client there shouldn't be any actual problem resulting from them being there.

[–] kate@lemmy.uhhoh.com -1 points 1 week ago

Red new url?

[–] N0x0n@lemmy.ml 3 points 1 week ago

Yeah :) I recently switched to a private tracker and qbittorrent was way to much cluttered with public trackers.

If you are on different private trackers and try to keep it clean and easier to find what torrent belongs to what private tracker, its better ton only have those tracker in your list.

[–] LodeMike@lemmy.today 3 points 1 week ago

I would also like to know this.

[–] N0x0n@lemmy.ml 2 points 1 week ago

I had the same question and somehow found a way to clear all trackers but on the client... So I have no idea if this is going to work in the web UI.

Select all your torrents => right click => trackers => and remove all the lines you want to remove.