emoncms RaspPi image torrent

Hi all,

I saw on Twitter that the project was having trouble with bandwidth on Dropbox due to the popularity of the RaspPi EmonCMS image, and I wondered if torrents might help?

Glyn suggested I posted here, as he himself wasn't overly familiar with torrent server setup, so here's a quick torrent 101 to start a discussion :)

  • Torrents are a useful way of distributing large files (such as disk images)
  • Everyone involved in a torrent swaps pieces of the file with others, everyone uploads as they download
  • The group of peers uploading and downloading the pieces of a torrent are referred to as a swarm
  • The larger the swarm, the more reliable (and faster) the download for everyone
  • The general idea is that the load and reliance on a single central server is removed

The person who wants to share an image makes a small info file (a .torrent file) which can be shared on their website. Usually, they would also run a torrent client *somewhere* which was sharing this torrent and had a full copy of the image to be shared; this is the initial seed server. Initially, everyone else joining the swarm would find only the initial seed server had the pieces they wanted, but over time, copies would spread over the swarm and the demand on the initial seed server would fall.

An additional trick which could be used here would be to use Dropbox as the initial seed server. This would mean when the number of swarm members was low, it would pretty much end up being a HTTP download again. But when demand was high, bandwidth draw on Dropbox would go right down. If people are willing to leave their torrent clients running after their download completes, then this will continue to benefit others in the swarm, and also keep the Dropbox load down. The image file hosted on Dropbox in this scenario is not special in anyway, it's the same file as used for a normal HTTP download.

Here's a link from a quick search on Dropbox and torrents:

https://sites.google.com/site/torrenttricks/use-dropbox-as-a-free-websee...

I can't think of any reason why Dropbox would object to being used in this way, it saves them bandwidth after all, but it would be worth checking their T&Cs.

One final thing. For peers in the swarm to find one another they need to exchange IPs. Usually, this is done by using a 'tracker server', which is a central server where where swarm members can advertise their existence and discover others. A tracker server hosts no content itself and so its bandwidth requirements are typically low. It is also possible to make a tracker-less torrent, but their effectiveness varies and I wouldn't recommend relying on them exclusively for this project.

I hope maybe this can help with the bandwidth issues. Please let me know if you have any questions or if I can be of help in setting this up should you wish to try it.

Cheers,

    Mark

mharizanov's picture

Re: emoncms RaspPi image torrent

Great idea, I have considered it before, but have never created a .torrent previously neither had time to further explore it.

 

jf1's picture

Re: emoncms RaspPi image torrent

Hi all,

Firstly, thanks to Trystan, Glyn and everyone else who's contributed to OEM - this really is a great project!

In an effort to contribute I've created a torrent of the 2013-04-19 R-Pi .img file, the .torrent file is attached to this post in a .zip file and also available as a .torrent from:
http://torcache.net/torrent/AED670234438B2DDB7FC4842F429041F31696693.tor...

I squashed the .img with 7-zip, this has made the filesize 727MB (vs 1.1GB for the .zip).
Free 7-zip unpackers are available at:
Win: http://www.7-zip.org/
Mac: http://www.kekaosx.com/en/
Linux: http://sourceforge.net/projects/p7zip/

If you need help downloading this torrent then post back here or have a look at one of the many available guides, eg: http://www.utorrent.com/help/guides/beginners-guide/

Looks like it will take about 3 hours for the initial seeding to finish, so don't expect it to download quickly until about 6pm today (UK time).

Cheers, Jonathan.

mtully's picture

Re: emoncms RaspPi image torrent

Great stuff thanks! Seeding now :)

I'd been pondering trying to setup a tracker for this... Do you think it would help or do you think DHT/tracker-less will suffice?

Cheers,

Mark

manicmoddin's picture

Re: emoncms RaspPi image torrent

I have downloaded and am seeding, but on boot I get a message starting there's been a problem mounting the file system. I have left it seasoning incase it is just my card/pi.

Attached is a photo of the boot.

Any help would be great

Jimmy

jf1's picture

Re: emoncms RaspPi image torrent

@Mark

The .torrent is already being tracked at:
udp://tracker.openbittorrent.com:80/announce
udp://tracker.publicbt.com:80/announce

You're welcome to setup or add it to an existing HTTP tracker (to support older tracker clients) but I'm not sure if it's that necessary.

Cheers, Jonathan.

jf1's picture

Re: emoncms RaspPi image torrent

@Jimmy

You can't just copy the file onto an SD card, you need to extract the .img from the 7zip file (using one of the tools listed above), then transfer the .img onto the SD card using a tool like win32diskimager.

There are some Linux instructions here.

Cheers, Jonathan.

manicmoddin's picture

Re: emoncms RaspPi image torrent

lol

I got that bit copied over fine, I used dd in ubuntu and it copied at 2Mb/s (log time) and died.

Personally, not sure if it was my copy, as I have used the one from dropbox 2 and this worked fine, but copied over using win32diskimager . Need to get a card reader that supports SDHC cards at a reasonable speed, as the things I have are USB 1.1 lol

Cheers though, I have re downloaded and seeding again.

Jimmy

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.