Bit torrent
-
Upload
himanil-gupta -
Category
Technology
-
view
723 -
download
5
description
Transcript of Bit torrent
![Page 1: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/1.jpg)
Submitted To:-
Mr. Nayyar Khan
Miss Suhani Agarwal
Submitted By:-
Ankit Malvi CSE-16
Ankit Chauhan CSE-14
Himanil Gupta CSE-39
![Page 2: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/2.jpg)
Contents… Simple Solution: One BIG Server (but a problem too…)
How server Works…?
Solution Of the problem
Entering “BIT TORRENT”..
-Something about creator……
-Definition
-Basic Component
-Basic Idea
![Page 3: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/3.jpg)
Simple Solution: One Big Server Make the file available on a central server
Each client downloads file from this server
Problems
Solution does not scale very well
With a large number of clients, the server’s resources get overwhelmed
![Page 4: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/4.jpg)
![Page 5: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/5.jpg)
How SERVER works?
![Page 6: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/6.jpg)
Problem Being Solved Here? Sharing a fairly large file
Involves making a replica
Problem is somewhat similar to, but not the same as, replication in a distributed file system, a Content Delivery Network or a Distributed Hash Table overlay network
![Page 7: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/7.jpg)
Entering Bit Torrent Released in the summer of 2001
Uses basic ideas from game theory to largely eliminate the free-rider problem All previous systems could not deal with this problem
well
Makes no strong guarantees unlike DHTs
It is working extremely well in practice, unlike DHTs
![Page 8: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/8.jpg)
Bram Cohen – the creator of Bit Torrent:
Something About Creator…..
![Page 9: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/9.jpg)
What is BitTorrent?
Efficient content distribution system using
file swarming. Usually does not perform
all the functions of a typical p2p system,
like searching.
![Page 10: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/10.jpg)
Basic Components Seed
Peer that has the entire file
Leeches Peer that has an incomplete copy of the file
A Torrent file Passive component Files are typically fragmented into 256KB pieces The torrent file lists SHA1 hashes of all the pieces to allow peers to
verify integrity Typically hosted on a web server
A Tracker Active component Allows peers to find each other Returns a random list of peers
![Page 11: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/11.jpg)
Basic Idea Initial seeder chops file into many pieces.
Leecher first locates the .torrent file that directs it to a tracker, which tells which other peers are downloading that file. As a leecher downloads pieces of the file, replicas of the pieces are created. More downloads mean more replicas available
As soon as a leecher has a complete piece, it can potentially share it with other downloaders. Eventually each leecher becomes a seeder by obtaining all the pieces, and assembles the file. Verifies the checksum.
![Page 12: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/12.jpg)
BitTorrent LingoSeeder = a peer that provides the complete file.
Initial seeder = a peer that provides the initial copy.
Initial seeder
Seeder
Leecher
One who is downloading(not a derogatory term)
Leecher
![Page 13: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/13.jpg)
Pieces & Sub-Pieces
A piece is broken into sub-pieces ... typically 16KB in size
Policy: Until a piece is assembled, only download sub-pieces for that piece
This policy lets complete pieces assemble quickly
![Page 14: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/14.jpg)
File sharingLarge files are broken into pieces of size between
64 KB and 1 MB
1 2 3 4 5 6 7 8
![Page 15: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/15.jpg)
Simple example
Seeder: A
Downloader B
{1,2,3,4,5,6,7,8,9,10}
Downloader C
{1,2,3}{1,2,3,4,5}
![Page 16: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/16.jpg)
![Page 17: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/17.jpg)
How delay is avoided between pieces..??
When transferring data over TCP, it is critical to always have several requests pending at once, to avoid a delay between pieces being sent
Bit Torrent breaks pieces into sub-pieces
At any point in time, some number, typically 5, are requested simultaneously
Every time a sub-piece arrives, a new request is sent
This scheme has been found to saturate most connections in practice
![Page 18: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/18.jpg)
BT: internal mechanism
Built-in incentive mechanism (where all the
magic happens):
Choking Algorithm
Optimistic Unchoking
![Page 19: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/19.jpg)
Choking Choking is a temporary refusal to upload. It is one
of BitTorrent’s most powerful idea to deal with free
riders (those who only download but never
upload).
Tit-for-tat strategy is based on game-theoretic
concepts.
![Page 20: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/20.jpg)
Choking Algorithm Goal is to have several bidirectional connections
running continuously
Upload to peers who have uploaded to you recently
Unutilized connections are uploaded to on a trial basis to see if better transfer rates could be found using them
![Page 21: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/21.jpg)
Choking Specifics A peer always unchokes a fixed number of its peers
(default of 4) Decision to choke/unchoke done based on current
download rates, which is evaluated on a rolling 20-second average
Evaluation on who to choke/unchoke is performed every 10 seconds This prevents wastage of resources by rapidly choking/unchoking
peers Supposedly enough for TCP to ramp up transfers to their full
capacity
Which peer is the optimistic unchoke is rotated every 30 seconds
![Page 22: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/22.jpg)
Optimistic unchoking
A BitTorrent peer has a single “optimistic unchoke” to which it uploads regardless of the current download rate from it. This peer rotates every 30s
Reasons: To discover currently unused connections are
better than the ones being used
To provide minimal service to new peers
![Page 23: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/23.jpg)
Endgame Mode Policy: When all the sub-pieces that a peer doesn’t
have are actively being requested, these are requested from EVERY peer
When the sub-piece arrives, the replicated requests are cancelled
This ensures that a download doesn’t get prevented from completion due to a single peer with a slow transfer rate
Some bandwidth is wasted, but in practice, this is not too much
![Page 24: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/24.jpg)
![Page 25: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/25.jpg)
Bit Torrent p2p file-sharing
system
Aspects important for the acceptance of a p2p system :1. High availability;2. Users always receive a
good version of the content they are requesting;
3. Ability to deal with flashcrowds;
4. High download speed.
![Page 26: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/26.jpg)
Upload-Only mode Once download is complete, a peer has no
download rates to use for comparison nor has any need to use them
The question is, which nodes to upload to?
Policy: Upload to those with the best upload rate.
This ensures that pieces get replicated faster
Also, peers that have good upload rates are probably not being served by others
![Page 27: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/27.jpg)
conclusion
![Page 28: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/28.jpg)
Open any torrent client say BitTorrent ,BitLord..
![Page 29: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/29.jpg)
![Page 30: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/30.jpg)
![Page 31: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/31.jpg)
![Page 32: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/32.jpg)
![Page 33: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/33.jpg)
![Page 34: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/34.jpg)
![Page 35: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/35.jpg)
![Page 36: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/36.jpg)
That’s all …..
You are done……
You got your torrent file……….
![Page 37: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/37.jpg)
Next What ??? Now you need to share it! You can upload it to a forum,
or a BitTorrent site, like www.MiniNova.com etc……
Make sure your client is ready to seed to those who want the file before you upload, though, or else no one will get it.
![Page 38: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/38.jpg)
Conclusion BitTorrent was conceived as a way of distributing
large files more quickly, efficiently, and reliably. Thanks to BitTorrent though, the download of large files has become more feasible, and people have become accustomed to acquiring video through the net. At this point it is virtually impossible for anyone to bring an end to illegal downloads. whether or not BitTorrent will continue to play a role in this is yet to be seen.
![Page 39: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/39.jpg)
References Google Search…
www.en.wikipedia.com.com
www.howstuffsworks.com
www.what-is-torrent.com
Torrent s/w official websites
![Page 40: Bit torrent](https://reader034.fdocument.pub/reader034/viewer/2022052120/55851717d8b42aff298b4f8a/html5/thumbnails/40.jpg)
Thank You…..
Questions…??