In the BitTorrent file distribution system, a torrent file or meta-info file is a computer file that contains metadata about files and folders to be distributed, and usually also a list of the network locations of trackers, which are computers that help participants in the system find each other and form efficient distribution groups called swarms. A torrent file does not contain the content to be distributed; it only contains information about those files, such as their names, folder structure, sizes, and cryptographic hash values for verifying file integrity. The term torrent may refer either to the metadata file or to the files downloaded, depending on the context.
A torrent file acts like a table of contents (index) that allows computers to find information through the use of a BitTorrent client. With the help of a torrent file, one can download small parts of the original file from computers that have already downloaded it. These \"peers\" allow for downloading of the file in addition to, or in place of, the primary server.
Torrent files themselves and the method of using torrent files have been created to ease the load on central servers, as instead of sending a file to for request, it can crowd-source the bandwidth needed for the file transfer, and reduce the time needed to download large files. Many free/freeware programs and operating systems, such as the various Linux distributions offer a torrent download option for users seeking the aforementioned benefits. Other large downloads, such as media files, are often torrented as well.
Typically, Internet access is asymmetrical, supporting greater download speeds than upload speeds, limiting the bandwidth of each download, and sometimes enforcing bandwidth caps and periods where systems are not accessible. This creates inefficiency when many people want to obtain the same set of files from a single source; the source must always be online and must have massive outbound bandwidth. The BitTorrent protocol addresses this by decentralizing the distribution, leveraging the ability of people to network \"peer-to-peer\", among themselves.
Each file to be distributed is divided into small information chunks called pieces. Downloading peers achieve high download speeds by requesting multiple pieces from different computers simultaneously in the swarm. Once obtained, these pieces are usually immediately made available for download by others in the swarm. In this way, the burden on the network is spread among the downloaders, rather than concentrating at a central distribution hub or cluster. As long as all the pieces are available, peers (downloaders and uploaders) can come and go; no one peer needs to have all the chunks or to even stay connected to the swarm in order for distribution to continue among the other peers.
A small torrent file is created to represent a file or folder to be shared. The torrent file acts as the key to initiating downloading of the actual content. Someone interested in receiving the shared file or folder first obtains the corresponding torrent file, either by directly downloading it or by using a magnet link. The user then opens that file in a BitTorrent client, which automates the rest of the process. In order to learn the internet locations of peers who may be sharing pieces, the client connects to the trackers named in the torrent file, and/or achieves a similar result through the use of distributed hash tables. Then the client connects directly to the peers in order to request pieces and otherwise participate in a swarm. The client may also report progress to trackers, to help the tracker with its peer recommendations.
A torrent is uniquely identified by an infohash, a SHA-1 hash calculated over the contents of the info dictionary in bencode form. Changes to other portions of the torrent does not affect the hash. This hash is used to identify the torrent to other peers via DHT and to the tracker. It is also used in magnet links.
A torrent file can also contain additional metadata defined in extensions to the BitTorrent specification. These are known as \"BitTorrent Enhancement Proposals.\" Examples of such proposals include metadata for stating who created the torrent, and when.
The specification recommends that nodes \"should be set to the K closest nodes in the torrent generating client's routing table. Alternatively, the key could be set to a known good node such as one operated by the person generating the torrent.\"
This feature is very commonly used by open source projects offering software downloads. Web seeds allow smart selection and simultaneous use of mirror sites, P2P or HTTP(S), by the client. Doing so reducing the load on the project's servers while maximizing download speed. MirrorBrain [de] automatically generates torrents with web seeds.
Private torrents are to be used with a private tracker. Such a tracker restricts access to torrents it tracks by checking the peer's IP, refusing to provide a peer list if the IP is unknown. The peer itself is usually registered to the tracker via a gated online community; the private tracker typically also keep statistics of data transfer for use in the community.
Decentralized methods like DHT, PeX, LSD are disabled to maintain the centralized control. A private torrent can be manually edited to remove the private flag, but doing so will change the info-hash (deterministically), forming a separate \"swarm\" of peers. On the other hand, changing the tracker list will not change the hash. The flag does not offer true privacy, instead operating as a gentlemen's agreement. 1e1e36bf2d