Jump to content

bittorrent from command line


Recommended Posts

I downloaded the bittorrent client today using "urpmi bittorrent" (sooo easy...)


*** What is Bittorrent? ***

Bittorrent is a distributed P2P file sharing client, used for "swarming [big] downloads across unreliable networks". When you download a file using Bittorrent, you also provide the parts you already downloaded for others to upload. You have to provide just as much upload as you've downloaded, so that everyone gets treated on an equal basis.


Advantages: you can get extremely high download rates and the file gets constantly checked for errors, so it will be extremely unlikely you will end up with a broken download. A 200MB-file could very well be finished within a couple of hours.


Disadvantages: This is mostly used for the newer/newest stuff, so chances are after a while you won't find previous versions of a file/series because everyone already downloaded it. This is why Bittorrent is mostly used for getting the latest movie/anime from the net. Also a lot of Linux ISO's are available. More info: http://bitconjurer.org/BitTorrent/

*** END ***


Anyway, it did not come with a GUI for me. So instead of looking for it, I gave the console command a shot. It's very easy in fact:




btdownloadheadless.py --url "http://www.fakeurl/fakefile.avi.torrent" --saveas newfilename.avi


Where btdownloadheadless.py is the name of the bittorrent executable, --url specifies that a URL will follow for the file, the filename between the brackets "[filename]" is the URL for the filename you will want to download (if you click on the link, It will probably display in a box or in your address bar). The brackets are there so the CLI will take note of spaces and weird characters.


Lastly, with --saveas [filename] you can specify where to save your file, meaning in which file to save it (your filename) and in which directory. If you do not specify a directory, this will go into the dir you are in currently.


Behold the power of a CLI bittorrent... Muhahaa!!




Link to comment
Share on other sites

Check out this client - it has a lot of really cool features!



What I usually do is run btdownloadcurses.py, which is an ncurses interface that looks nicer. Screen is really useful here. For example:



./btdownloadcurses.py --command_line_arguments

ctrl-a c (creates a new screen)

./btdownloadcurses.py --second_torrent

ctrl-a d (detaches screens)


You can check the progress by running screen -r to reattach the screens. It works over ssh connections as well, so you can start a download @ home, detach the screen, go somewhere else, ssh in, and see the progress. Very cool :-)


*Note: Edited for typos :oops:



Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...