beta 4 torrent client testing

A nice, warm, and cozy place for all third-party developers to congregate.

Moderator: chirpa

Similar topics


Postby ykf » Mon Dec 10, 2007 3:52 am

tristan wrote:Wow that looks sweet! How is the performance of Torrentflux and the NV+ in general, when downloading torrents?

Would it be possible to post a quick howto for the Torrentflux installation btw?


The max is two simultaneous download I guess... CPU will get more than 70% usually when having 2 downloads:

Image

But when it's not downloading, the UI speed is quite good.. considering that it's just a NAS box the performance is more than enough I think.
ykf
ReadyNAS Newbie
 
Posts: 38
Joined: Wed Nov 28, 2007 3:13 am
Location: Hong Kong

Postby Evadman » Sun Dec 23, 2007 10:17 pm

Thats awesome ykf! Feel like posting a how-to? Please? :)
Evadman
ReadyNAS Newbie
 
Posts: 28
Joined: Sat Jan 27, 2007 2:01 am

Postby lalaw » Thu Jan 03, 2008 9:55 am

Any new reports since the release of p1c2? I'd love to see a torrent client available as an add-on package one day (maybe I'm dreaming...)
lalaw
ReadyNAS Newbie
 
Posts: 33
Joined: Tue Aug 22, 2006 8:09 am

Postby blazingice » Tue Jan 08, 2008 12:42 am

Hey all,

I spent quite a bit of time getting the most recent rtorrent (0.7.9) working on my nas, so I've documented the process here for any of you wanting the same. Also, I am too new a user to post urls, so please correct them appropriately.

First, make sure you have gained root shell access and have installed at least libc6-dev and gcc. Follow the instructions here: www_infrant_com/forum/viewtopic.php?t=14903

Second, we'll need to install quite a few packages. This should be all you need, please let me know if I've forgotten any.
Code: Select all
$ apt-get install coreutils pkg-config g++ libncurses-dev libssl-dev libsigc++-2.0-dev curl libcurl3-dev screen

Also, due to a failure in one of the install scripts, we need to create the file /usr/lib/pkg-config/libcurl.pc. It should look like this:
Code: Select all
prefix=/usr
exec_prefix=${prefix}
libdir=${exec_prefix}/lib
includedir=${prefix}/include

Name: libcurl
Description: Get files from online servers
Version: 7.13.2
Libs: -L${libdir} -lcurl
Cflags: -I${includedir}/curl

Now we should be ready to download and install libtorrent and rtorrent. Compiling libtorrent takes about a half hour; rtorrent itself takes over an hour, so be prepared. To install, run these commands:
Code: Select all
$ wget libtorrent_rakshasa_no/downloads/libtorrent-0.11.9.tar.gz
$ tar -xvvzf libtorrent-0.11.9.tar.gz
$ cd libtorrent-0.11.9
$ ./configure sparc-linux
$ make
$ make install
$ cd ..

$ wget libtorrent_rakshasa_no/downloads/rtorrent-0.7.9.tar.gz
$ tar -xvvzf rtorrent-0.7.9.tar.gz
$ cd rtorrent-0.7.9
$ ./configure sparc-linux
$ make
$ make install
$ cd ..

At this point, you should have rtorrent installed and ready to go. To allow easy torrent management, however, you'll have to do a bit more work. Decide which share you want the torrents to be on ("media" in my case), and create directories (we'll configure rtorrent later).

Code: Select all
$ mkdir /c/media/bt
$ mkdir /c/media/bt/torrents
$ mkdir /c/media/bt/incomplete/

Now, create a new user (blazingice, for example) under which to run rtorrent.
Code: Select all
$ useradd -g nogroup blazingice
$ mkdir /home/blazingice
$ chown blazingice:nogroup /home/blazingice /c/media/bt /c/media/bt/torrents /c/media/bt/incomplete

Now, all files created by this user will be owned by blazingice and the "nogroup" group. Since the shares themselves run in the "nogroup" group, you should be able to read, move, or delete the newly created files from the network share.

Finally, we can set up rtorrent. We will do this by creating /home/blazingice/.rtorrentrc. Mine looks like this:
Code: Select all
# Watch a directory for new torrents, restart torrents that have been
# copied back and stop those that have been deleted.
schedule = watch_directory,10,10,"load_start=/c/media/bt/torrents/*.torrent,d.set_directory=/c/media/bt/incomplete"
schedule = tied_directory,10,10,start_tied=
schedule = untied_directory,10,10,close_untied=

# When the torrent finishes, it executes "mv -n <base_path> ~/Download/"
# and then sets the destination directory to "~/Download/". (0.7.7+)
on_finished = move_complete,"execute=mv,-u,$d.get_base_path=,/c/media/bt/ ;d.set_directory=/c/media/bt/"

# Close torrents when diskspace is low.
schedule = low_diskspace,5,60,close_low_diskspace=100M

# Stop torrents after seeding to 100%
schedule = ratio,60,60,"stop_on_ratio=100,50M,300"

Now rtorrent will watch media//bt/torrents for new torrents and begin downloading them immediately. The incomplete files will be in media//bt/incomplete/, and when done, rtorrent will move the files to media//bt/. If you're wanting to customize further, go visit rtorrent's site at libtorrent_rakshasa_no/. We, however, are almost done!

We want the files created by rtorrent to be readable and writable by both blazingice and anyone in the torrents group. To do this, create a shell script (/home/blazingice/start-rtorrent) that we'll use to launch rtorrent. It should look like this:
Code: Select all
#!/bin/bash
umask 002
rtorrent

Now make it executable:
Code: Select all
$ chmod +x start-rtorrent

Now, we're ready to launch rtorrent! We'll use screen to detach from the terminal:
Code: Select all
$ screen
$ su - blazingice
$ /home/blazingice/start-rtorrent

You're done! Simply drop torrents onto bt/torrents/ on the share and rtorrent will snap them up, download them, and place the completed files in media//bt/! You will be able to move, copy, and delete the final files through the network share from there.

I hope this howto has cleared up some things... My NAS seems to still be working fine, but I'm not responsible if yours breaks horribly while following this guide. Please let me know if you run into any problems!

blazingice

Edit: Removed some complexity in the user setup.
blazingice
ReadyNAS Newbie
 
Posts: 6
Joined: Sun Jan 06, 2008 11:02 pm

Postby deadmeat » Mon Jan 21, 2008 5:06 pm

ykf wrote:The max is two simultaneous download I guess... CPU will get more than 70% usually when having 2 downloads:

But when it's not downloading, the UI speed is quite good.. considering that it's just a NAS box the performance is more than enough I think.



I've got TorrentFlux running and i've noticed that the CPU utilization is directly correlated to the the amount of peer connections/download speed.

I've throttled my download to 100KB/s and 25 peer connections. I have seen no real problems with CPU utilization going over 50% at any time.

I did install gallery2 and THAT will kill your CPU utilization, thumbnailing jpgs and such. :)
deadmeat
ReadyNAS Newbie
 
Posts: 18
Joined: Fri Jul 27, 2007 7:26 am

Postby lalaw » Thu Jan 24, 2008 2:20 pm

deadmeat wrote:
I've got TorrentFlux running and i've noticed that the CPU utilization is directly correlated to the the amount of peer connections/download speed.

I've throttled my download to 100KB/s and 25 peer connections. I have seen no real problems with CPU utilization going over 50% at any time.

I did install gallery2 and THAT will kill your CPU utilization, thumbnailing jpgs and such. :)



Deadmeat--how did you throttle your peer connections to 25? I tried adding "--max_connections 25" to my Extra BitTornado Commandline Options, but I kept failing with a h.failed() error. Once I removed this, I was in good shape.

BTW, for all interested, getting TorrentFlux up and running wasn't too much trouble. Just followed the "Install PHP" thread, installed curl, installed php5-mysql, and was pretty much set up.

Thanks!
lalaw
ReadyNAS Newbie
 
Posts: 33
Joined: Tue Aug 22, 2006 8:09 am

Postby deadmeat » Fri Jan 25, 2008 3:05 am

http://www.torrentflux.com/forum/index. ... 341.0.html

and i actually used:
max_initiate=number of peers at which to stop initiating new connections

"--max_initiate 25"

when i get 25 connected peers it stops asking for more

does the same thing

***EDIT***
also, there is a bug in TF2.3, fix here:
http://www.torrentflux.com/forum/index. ... 727.0.html
***EDIT***
deadmeat
ReadyNAS Newbie
 
Posts: 18
Joined: Fri Jul 27, 2007 7:26 am

Postby lalaw » Fri Jan 25, 2008 11:34 am

deadmeat wrote:http://www.torrentflux.com/forum/index.php/topic,341.0.html

and i actually used:
max_initiate=number of peers at which to stop initiating new connections

"--max_initiate 25"

when i get 25 connected peers it stops asking for more

does the same thing

***EDIT***
also, there is a bug in TF2.3, fix here:
http://www.torrentflux.com/forum/index. ... 727.0.html
***EDIT***


Thanks for the tip. In the end, I changed to the torrentflux-b4rt install, which had some nice features (including configurable 'nice' threading) on the gui. So far so good!

As an aside, has anyone figured out how to use apt-get to install packages after they've done a force install via dpkg? I keep having to remove the "unmet dependencies" and reinstalling in order to get apt-get to cooperate.

I'm assuming I'm just a Debian noob, but any commentary would be nice.
lalaw
ReadyNAS Newbie
 
Posts: 33
Joined: Tue Aug 22, 2006 8:09 am

Postby FredLens » Thu Feb 14, 2008 5:57 am

blazingice wrote:Hey all,

I spent quite a bit of time getting the most recent rtorrent (0.7.9) working on my nas, so I've documented the process here for any of you wanting the same. Also, I am too new a user to post urls, so please correct them appropriately.


Dear Blazingice,
Can't say anything else than THANK YOU for the superbly written, and easy to use how-to. Works like a charm !!!

Note for other torrent users : it seems that rtorrent is definitely the client using the less CPU power. I've tested it with 20 torrents (all downloading) and couldn't get it to use more than 50% CPU. Usually, it runs at something like 5 to 10% CPU, and even not at all time !

I'm working on getting wTorrent installed on the NAS box. I just need to figure out how to get PHP to work on the box easily... and mod_scgi and to install wTorrent.
Anybody already did it ?
Cheers,
Fred
FredLens
ReadyNAS Newbie
 
Posts: 7
Joined: Tue Jan 29, 2008 5:52 am

Speed issues

Postby DougLorenz » Tue Feb 19, 2008 9:09 am

I've set up rtorrent to work on my NV+, and it seems to be running very slow. I've never used rtorrent before, so it could be a simple issue. I'm used to using utorrent on my PC system up to now.

Any tuning issues? I'm not entirely sure that I am connecting properly to the tracker, but I don't know how to verify this...
DougLorenz
ReadyNAS Newbie
 
Posts: 23
Joined: Fri Mar 30, 2007 7:21 am

Postby chirpa » Tue Feb 19, 2008 10:32 am

Have many of you used the built-in bittorrent client included in the latest beta firmware?
User avatar
chirpa
Jedi Council
 
Posts: 11174
Joined: Mon Sep 24, 2007 11:52 am
Location: T.A.R.D.I.S.
ReadyNAS: Repertoire

Postby DougLorenz » Tue Feb 19, 2008 10:41 am

chirpa wrote:Have many of you used the built-in bittorrent client included in the latest beta firmware?


There's a bittorrent client in the latest beta firmware?

(Does that answer your question?)
DougLorenz
ReadyNAS Newbie
 
Posts: 23
Joined: Fri Mar 30, 2007 7:21 am

Postby chirpa » Tue Feb 19, 2008 10:47 am

DougLorenz wrote:There's a bittorrent client in the latest beta firmware?
:D
http://www.infrant.com/forum/viewtopic. ... 5777#85777
User avatar
chirpa
Jedi Council
 
Posts: 11174
Joined: Mon Sep 24, 2007 11:52 am
Location: T.A.R.D.I.S.
ReadyNAS: Repertoire

Postby frejac » Tue Feb 19, 2008 1:30 pm

I've tried it once, and it seems to work nice - but until you implement a drop-folder for .torrents, I'll stick with rtorrent. :)


btw...I've limited my rtorrent with these entries in the .rtorrent.rc-file
max_open_sockets = 128
max_open_files = 64
max_memory_usage = 536870912 (I have 1GB in my NV+)

Before my limitation, rtorrent took over the NV+ completely, it stopped responding to ping for example as it did all it could to download files :)
Now it isnt rocket fast, but fast enough and it doesnt impact the other dutys....

apart from that, my rtorrent runs with a nice-value of 19.
frejac
ReadyNAS Expert
 
Posts: 265
Joined: Tue Nov 28, 2006 5:59 am

Postby derek » Thu Feb 21, 2008 12:55 am

frejac wrote:but until you implement a drop-folder for .torrents, I'll stick with rtorrent. :)
I can post my bash script in a day or two once I clean it up. Basically running a crontab every X minutes, if .torrents exist in a dir, import them to the daemon and remove them.

Right now I use curl to do it, probably can use wget as well. Curl does a formdata POST using the file var to /api/torrent-add?start=yes. Then the daemon imports the file, same as using the web interface if you view source on what it is doing. Can either do a POST with data, or a GET to http://localhost:8080/api/torrent-add?start=yes&url= with the URL of a .torrent the daemon will download and add it.
- What's in your NAS? ReadyNAS 600, 256MB, 4x Maxtor 300GB, 3x Maxtor 300GB USB
User avatar
derek
ReadyNAS Addict
 
Posts: 1193
Joined: Wed Dec 08, 2004 6:29 pm
Location: Igloo, Canada
ReadyNAS: 600

PreviousNext

Return to ReadyNAS Developers Network

Similar topics


Who is online

Users browsing this forum: No registered users and 0 guests