Search for:   in       
  




  Login / Signup  
 
Username:
Password:
Duration:
Log me out after 15 minutes
Note:
Enable Cookies To Log In.
Forgotten Your Password? - Click Here
Don't Have An Account? Sign Up For Free Now!
   Home
   Rules
 

Anatomy of a torrent session

(Updated to reflect the tracker changes. 14-04-2004)

There seems to be a lot of confusion about how the statistics updates work. The following is a capture of a full session to see what's going on behind the scenes. The client communicates with the tracker via simple http GET commands. The very first in this case was:

GET /announce.php?info_hash=c%97%91%C5jG%951%BE%C7M%F9%BFa%03%F2%2C%ED%EE%0F& peer_id=S588-----gqQ8TqDeqaY&port=6882&uploaded=0&downloaded=0&left=753690875 &event=started

Let's dissect this:

info_hash is just the hash identifying the torrent in question;
peer_id, as the name suggests, identifies the client (the s588 part identifies Shad0w's 5.8.8, the rest is random);
port just tells the tracker which port the client will listen to for incoming connections;
uploaded=0; (this and the following are the relevant ones, and are self-explanatory)
downloaded=0;
left=753690875 (how much left);
event=started (telling the tracker that the client has just started).

Notice that the client IP doesn't show up here (although it can be sent by the client if it configured to do so). It's up to the tracker to see it and associate it with the user_id.
(Server replies will be omitted, they're just lists of peer ips and respective ports.)
At this stage the user's profile will be listing this torrent as being leeched.

>From now on the client will keep send GETs to the tracker. We show only the first one as an example,

GET /announce.php?info_hash=c%97%91%C5jG%951%BE%C7M%F9%BFa%03%F2%2C%ED%EE%0F& peer_id=S588-----gqQ8TqDeqaY&port=6882&uploaded=67960832&downloaded=40828928& left=715417851&numwant=0

("numwant" is how the client tells the tracker how many new peers it wants, in this case 0.)

As you can see at this stage the user had uploaded approx. 68MB and downloaded approx. 40MB. Whenever the tracker receives these GETs it updates both the stats relative to the 'currently leeching/seeding' boxes and the total user upload/download stats. These intermediate GETs will be sent either periodically (every 15 min or so, depends on the client and tracker) or when you force a manual announce in the client.

Finally, when the client was closed it sent

GET /announce.php?info_hash=c%97%91%C5jG%951%BE%C7M%F9%BFa%03%F2%2C%ED%EE%0F& peer_id=S588-----gqQ8TqDeqaY&port=6882&uploaded=754384896&downloaded=754215163 &left=0&numwant=0&event=completed

Notice the all-important "event=completed". It is at this stage that the torrent will be removed from the user's profile. If for some reason (tracker down, lost connection, bad client, crash, ...) this last GET doesn't reach the tracker this torrent will still be seen in the user profile until some tracker timeout occurs. It should be stressed that this message will be sent only when closing the client properly, not when the download is finished. (The tracker will start listing a torrent as 'currently seeding' after it receives a GET with left=0).

There's a further message that causes the torrent to be removed from the user's profile, namely"event=stopped". This is usually sent when stopping in the middle of a download, e.g. by pressing 'Cancel' in Shad0w's.

One last note: some clients have a pause/resume option. This will not send any message to the server. Do not use it as a way of updating stats more often, it just doesn't work. (Checked for Shad0w's 5.8.11 and ABC 2.6.5.)

Disclaimer: None of the files shown here are actually hosted on this server. The links are provided solely by this site's users. These BitTorrent files are meant for the distribution of DVD backup files. By downloading the BitTorrent file, you are claiming that you own the original DVD backup file. The administrator of this site abetterplace2b.org, holds NO RESPONSIBILITY if these files are misused in any way. For controversial reasons, if you are affiliated with any government, ANTI-Piracy group or any other related group, or were formally a worker of one you CANNOT download any of these BitTorrent files. If you download these files you are not agreeing to these terms and you are violating code 431.322.12 of the Internet Privacy Act signed by Bill Clinton in 1995 and that means that you CANNOT threaten our ISP(s) or any person(s) or company storing these files, and cannot prosecute any person(s) affiliated with this page which includes family, friends or individuals who run or enter this web site. If you do not agree to these terms, please do not use this service or you will face consequences.
It is your own responsibility to adhere to these terms.

Tracker and some mods from TBDEV
Forums rewritten by Sparks
Shoutbox, Jukebox, UserCP and other mods written by Sparks
Banner and clock, as well as most avatars and siggys by Siduk