Almost all of us, at some point in time, have heard about the term “Torrent” and might be using it on a daily basis. But most of us may not be knowing about how a torrent works even though they are responsible for consuming a considerable amount of data all over the world.
Torrent download is based on the Peer-to-Peer network where all downloadable files are stored in different machines/nodes rather on a dedicated host.
Torrent download has revolutionized the way people are downloading files from the internet. Let us see how it works and what happens when you start downloading one.
But before understanding how torrent download works, lets quickly touch upon torrents itself and why do they exist.
Why do torrents exist?
Torrents were introduced to ease file sharing amongst users. A large amount of data can be transferred and shared with millions of users simultaneously without the need of maintaining a file-server.
It also provides one-click pause and resume functionality which helps users download and pause their favorite movies, softwares, music, videos and other content whenever they want to.
How is torrent download different from a regular download?
This is the part where torrents excel over regular downloads, also called direct download.
Instead of downloading a file from a single source (usually a dedicated file server), a user connects to multiple users who already have the file downloaded or are in the process of downloading.
Basic Terminologies related to the torrent functioning
Before we dive into how torrents work, let us try to understand some basic terminologies which we will come across. It will help us understand torrent functioning.
A seed or a seeder is someone who is finished downloading the file and is currently sharing the same on the network. They are basically like servers on the web.
A Peer is a person who is currently downloading a file. When they are in the process of downloading, they might also act as a server by sharing the pieces of the file they are downloading.
True to its name, a leech is an individual who is just downloading a file but isn’t interested in uploading the same. In short, they don’t want others to download the file from them.
Indexers are just like directories. Just like a phone directory provides phone numbers, indexers give information about how to find or download torrents.
Swarms are merely a collection of peers who are downloading or uploading a particular torrent at a given time.
A tracker is the most critical part of a torrent. Trackers help find seeds and peers on a network. They are responsible for interconnection of users who are interested in downloading the same torrent.
Software applications which help users download data from torrents. They handle the torrent file, extract data required and are merely file downloaders which assist in the transfer process.
Okay, so how do they work?
A torrent is some chunk of data which hold information on how to further download a particular file or files.
They don’t contain the actual data but metadata such as the file location, a list of trackers and relevant information such as file name, size, and the directory structure.
Torrent is based on the Peer to Peer network to help users share the required files or resources.
Instead of relying on the Publisher-Server system used in applications like Kazaa, they use the popular peer to peer file sharing mechanism.
This peer to peer mechanism is widely known for its robustness and the ability to lower costs associated with the maintenance and operation.
For security purposes, torrent files contain cryptographic hash values, which help verify the integrity of a particular file, to discourage the modification of the file originally shared over the network.
This ensures that the file is free of any corruption or injection of any adware, malware or a backdoor.
Torrents usually have the .torrent extension. These files range anywhere from 15kb to 150kb depending on various factors.
However, after the recent crackdown on torrent websites by multiple government agencies and companies all over the world, .magnet files are preferred.
These files do away with the need to download a separate torrent file and are links pointing to hash code for a torrent.
How do I download a torrent?
The first you will need is a .torrent or .magnet file which will point to the file you want to download.
The torrent community has a large user base so you won’t any much problem finding a torrent containing your favorite movie, song or a particular application or anything you want.
To initiate a torrent download, you will need a torrent download client.
There are a lot of torrent clients which offer different functionalities such as sequential download, inbuilt torrent search engines, upload, and download limit and much more.
We have reviewed each one of these and many others so if you want to find a torrent client which will match your needs, feel free to do so by clicking on respective hyperlinks in the previous line.
What happens after I add a torrent to the client?
This is where the downloading process begins. Instead of directly downloading from a single source like a file-server, a torrent downloads from many users which act both as seeds as well as peers simultaneously.
The torrent client starts to scour the trackers present in the .torrent file for swarms available on the internet.
After finding and listing all the available users connected to the network, the client starts categorizing them into two archetypes, namely, seeds and peers.
This is done by searching for people with the exact torrent as you.
After the creation of this swarm list, which contains the IP addresses and many other things used to identify a machine connected to the network, the downloading begins.
A file is downloaded not sequentially but in chunks which are chosen according to availability.
When all the pieces of the file are downloaded, the torrent segregates them into one.
Incomplete downloads cannot be opened and act as corrupt files except when downloading videos which can be played in pieces.
Some clients offer the ability to request pieces in a sequential manner so that the first chunk gets downloaded first.
Although, it should be noted that this affects the health of a torrent negatively because if everyone starts downloading sequentially, getting the last piece of the torrent will be rare.
Torrent health and file availability
The availability of a particular file or resource depends entirely on the Seed to Peer ratio, though it is not necessarily the case.
An ideal scenario where you will get good download speeds is when the number of seeds exceeds the number of peers.
In other words, people who have completed the download and are sharing the torrent should be more than the number of people trying to download the same. A healthy torrent has a seed: peer ratio higher than one.
But it is not always the case. Sometimes, all you might need is one seed which isn’t limiting his upload speed thereby acting as a file-server.
Even the opposite might be true. There may be multiple seeds available for a torrent who are sharing at lower (sometimes limited) speeds, thus causing the peers to download it at a lower speed than that provided by lesser high-speed seeds.
What is torrent chunk size? Does a torrent get downloaded as a whole?
The entire file or files are download in chunks which depend on the block size used by the torrent client used or the torrent itself. Each piece, when downloaded, is checked for data integrity using the SHA1 algorithm.
Smaller pieces are preferred because they are easier to get and ensure that the downloaded data isn’t corrupt. According to a Vuze, a torrent should contain 1000-1500 all in all to generate a reasonably small torrent file as well as swarm download.
Large pieces (greater than 4 MB) are also responsible for the slow down in distribution since a single will contain 256 or more 16 kB “blocks,” which are the smallest units used in the torrent protocol.
Even when downloading large files, one should always avoid pieces greater than 1 MB in size since they might stagnate the entire process resulting in an unfinished download and bandwidth wastage.
Over to you on torrent download
Even though torrents themselves are not illegal, there are various countries which have made torrent downloading illegally. One should always check if the content being downloaded is illegal or not.
That being said, torrents are the best way to share and download a large amount of data amongst users with millions of users using the technology all over the world.
A great way to secure yourselves from people spying on you while downloading torrent is to use a paid VPN solution which will help you anonymize your IP address and identity.