question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Client randomly doesn't get a sole seed from the tracker

See original GitHub issue

Tracker and sole seeder are hosted on the server, both using monotorrent. The client receives a torrent file that uses this tracker and tries to start downloading it. Seemingly randomly the tracker will report 0 peers. The seed seems to always get at least 1 peer from the tracker (itself). Using an external application to download the torrent instead of monotorrent seems to always receive the peer properly. The download is forever stuck at 0 since there are no peers. Even waiting for a very long time doesn’t seem to do anything.

These are the only events being fired after starting the torrent when it fails (hash is pre-checked).

[09:54:46] ScrapeComplete Successful=True Tracker=http://.../announce
[09:54:46] AnnounceComplete Successful=True Tracker=http://.../announce PeersCount=0
[09:54:46] PeersFound ExistingPeers=0 NewPeers=0

This is what happens when it works properly:

[11:05:06] ScrapeComplete Successful=True Tracker=http://.../announce
[11:05:07] AnnounceComplete Successful=True Tracker=http://.../announce PeersCount=1
[11:05:07] PeersFound ExistingPeers=-1 NewPeers=2
[11:05:08] PeerConnected Peer=ipv4://.../

Looks like there’s a bunch of http/tracker exceptions being thrown when querying the tracker, but they seem to happen even if it succeedes. image

Tested on latest master build on both client and server, but I believe it kept happening on latest beta build on nuget as well as the stable build.

This is pretty critical since I’m using private torrents so no DHT which would probably be able to sidestep the issue.

Edit: When there are multiple torrents running at the same time (all using that same tracker), it seems like some of them can succeed and some can fail to get the seed from the tracker.

Issue Analytics

  • State:closed
  • Created 8 months ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
ManlyMarcocommented, Feb 2, 2023

Confirming the issue is fixed.

1reaction
alanmcgoverncommented, Feb 2, 2023

I wonder if this will shed some light on the problem: https://github.com/alanmcgovern/monotorrent/pull/620

If you don’t have logging enabled/redirected, you can redirect logging to a file by replacing Console.Out with a regular filestream/something and registering a function here. Note: You should do this right at the start of your app so everything initialises correctly.

https://github.com/alanmcgovern/monotorrent/blob/master/src/Samples/SampleClient/StandardDownloader.cs#L35

I have moderate hope this will identify the issue you’re hitting 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Torrenting client won't seed after download : r/trackers
The client worked fine to download, but once completed, it will not seed! When I go to preferences, it shows “port check site...
Read more >
Torrent client: question on seeds and why many are shown ...
I think seeds is reported from the trackers, but downloads may come from DHT which might be pulling from seeds not on the...
Read more >
Upload not seeding (windows, private tracker) · Issue #14378
The private tracker on my first torrent kindly informs me that i'm only allowed to seed given my current ratio, but none of...
Read more >
Seeding priority by tracker
We already have seeding priority by ratio, peers, etc. What VUZE doesn't have (and other clients do) is an assignable IMPORTANCE value for...
Read more >
Why refresh to tracker must have - Help and Support
I've always on seed DVDs 800 in total. Tixati client check every torrent file every 30/40min to report on tracker.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found