Howto: RTorrent with Webinterface

Questions regarding modifying the torrent engine or download station may go here.
Forum rules
Please note the disclaimer before modifying your Synology Product.

Re: Howto: RTorrent with Webinterface

Postby siliconix » Mon May 19, 2008 7:17 pm

JohnnyCanuck wrote:Looks interesting. I tried to install rtGui but could only get a blank screen. Any tips on what slight modifications you needed to do?

I tried to .rtorrent.rc for scgi_local, but couldn't seem to get it working.

Is xmlrpc etc working for you with other web UIs for rtorrent ?
Just a completely blank screen in the browser or ?
The modifications are just related to different directory structure and the xml rpc package being different on Qnap. I followed the guide in the start of this thread, then skipped the wtorrent part, extracted rtgui to the docroot of lighttpd, so its more or less the same.
siliconix
I'm New!
I'm New!
 
Posts: 9
Joined: Mon May 19, 2008 1:34 pm

Re: Howto: RTorrent with Webinterface

Postby JohnnyCanuck » Mon May 19, 2008 7:45 pm

Yes. Other UI's work fine.

But, with rtGui I get a completely blank screen in the browser.

Here's my config.php for rtGui:
Code: Select all
<?php
//
// rtGui - Simon Hall 2007
//
// http://rtgui.googlecode.com/
//

// Connect string for your local RPC/rTorrent connection:
$rpc_connect="http://localhost:8081/RPC2";

// rtorrent 'watch' directory (used for upload torrent)
$watchdir="/volumeUSB1/usbshare/rWatch/";

// Time between ajax calls - default 5000 (5 secs).   Disable with 0
$defaultrefresh=5000;
?>


Here's my last few lines of .rtorrent.rc:
Code: Select all
scgi_port = 127.0.0.1:5000
encoding_list = UTF-8


And, the relevant portion of lighttpd.conf:
Code: Select all
scgi.server = (
               "/RPC2" =>
                 ( "127.0.0.1" =>
                   (
                     "socket" => "/root/.rtorrent/rpc.socket",
                     "host" => "127.0.0.1",
                     "port" => 5000,
                     "check-local" => "disable",
                     "disable-time" => 0,
                   )
                 )
             )


Is there something obvious I've done wrong?
JohnnyCanuck
Trainee
Trainee
 
Posts: 15
Joined: Fri May 02, 2008 6:23 pm

Re: Howto: RTorrent with Webinterface

Postby siliconix » Mon May 19, 2008 7:54 pm

JohnnyCanuck wrote:Yes. Other UI's work fine.

But, with rtGui I get a completely blank screen in the browser.

And, the relevant portion of lighttpd.conf:
Code: Select all
scgi.server = (
               "/RPC2" =>
                 ( "127.0.0.1" =>
                   (
                     "socket" => "/root/.rtorrent/rpc.socket",
                     "host" => "127.0.0.1",
                     "port" => 5000,
                     "check-local" => "disable",
                     "disable-time" => 0,
                   )
                 )
             )


Is there something obvious I've done wrong?


I use only host/port based rpc, not socket one. I'd try to comment out the ""socket" => "/root/.rtorrent/rpc.socket"," in lighttpd.conf and restart lighttpd. Besides that it looks pretty normal.
siliconix
I'm New!
I'm New!
 
Posts: 9
Joined: Mon May 19, 2008 1:34 pm

Re: Howto: RTorrent with Webinterface

Postby JohnnyCanuck » Mon May 19, 2008 8:09 pm

Now I'm getting can't start rTorrent because address (5000) already in use. So, I've tried 5555 (and editing lighttpd to match) and still no go.

Siliconx, would it be too much trouble to ask you to post you config.php and the relevant lines from lighttpd.conf and .rtorrent.rc?

Thanks!
JohnnyCanuck
Trainee
Trainee
 
Posts: 15
Joined: Fri May 02, 2008 6:23 pm

Re: Howto: RTorrent with Webinterface

Postby siliconix » Mon May 19, 2008 9:34 pm

JohnnyCanuck wrote:Now I'm getting can't start rTorrent because address (5000) already in use. So, I've tried 5555 (and editing lighttpd to match) and still no go.

Siliconx, would it be too much trouble to ask you to post you config.php and the relevant lines from lighttpd.conf and .rtorrent.rc?

Thanks!


Sure
Did you copy the xmlrpc.inc and xmlrpc_extension_api.inc to rtgui dir ?
Config.php
Code: Select all
<?php
//
// rtGui - Simon Hall 2007
//
// http://rtgui.googlecode.com/
//

// Connect string for your local RPC/rTorrent connection:
$rpc_connect="http://localhost:80/RPC2";

// rtorrent 'watch' directory (used for upload torrent)
$watchdir="/volume1/data/_incoming//_watch/";

// Time between ajax calls - default 5000 (5 secs).   Disable with 0
$defaultrefresh=30000;
?>


.rtorrent.rc
Code: Select all
scgi_port = 127.0.0.1:4000
encoding_list = UTF-8

lighttpd.conf
I have these modules enabled (think you'd just need fastcgi and scgi for this purpose) :
Code: Select all
"mod_fastcgi",
"mod_auth",
"mod_scgi",
"mod_accesslog"

server.port                = 80

scgi.server = (
"/RPC2" =>
( "127.0.0.1" =>
(
"host" => "127.0.0.1", # Ip where rtorrent is listening
"port" => 4000, # Port specified in .rtorrent.rc
# or use native unix socket
#"socket" => "/root/.rtorrent/rpc.socket",
"check-local" => "disable",
"disable-time" => 0 # don't disable scgi if connection fails
)
)
)


Think thats all that has been changed.
siliconix
I'm New!
I'm New!
 
Posts: 9
Joined: Mon May 19, 2008 1:34 pm

Re: Howto: RTorrent with Webinterface

Postby JohnnyCanuck » Mon May 19, 2008 10:17 pm

siliconix wrote:
Sure
Did you copy the xmlrpc.inc and xmlrpc_extension_api.inc to rtgui dir ?



That was it ... missed that piece. Now it's working. So far, it looks like the best of the web UI's.

Thanks siliconix!
JohnnyCanuck
Trainee
Trainee
 
Posts: 15
Joined: Fri May 02, 2008 6:23 pm

Re: Howto: RTorrent with Webinterface

Postby siliconix » Tue May 20, 2008 5:13 am

JohnnyCanuck wrote:
siliconix wrote:
Sure
Did you copy the xmlrpc.inc and xmlrpc_extension_api.inc to rtgui dir ?



That was it ... missed that piece. Now it's working. So far, it looks like the best of the web UI's.

Thanks siliconix!


Glad you got it working :)
siliconix
I'm New!
I'm New!
 
Posts: 9
Joined: Mon May 19, 2008 1:34 pm

Re: Howto: RTorrent with Webinterface

Postby dimip » Tue May 20, 2008 11:59 pm

nice guide good work .... i have followed the guide and i am almost done. i have stuck to this point any ideas what might be wrong?

Image

Code: Select all
# This is an example resource file for rTorrent. Copy to
# ~/.rtorrent.rc and enable/modify the options as needed. Remember to
# uncomment the options you wish to enable.

# Maximum and minimum number of peers to connect to per torrent.
min_peers = 40
max_peers = 100

# Same as above but for seeding completed torrents (-1 = same as downloading)
min_peers_seed = 10
max_peers_seed = 50

# Maximum number of simultanious uploads per torrent.
max_uploads = 15

# Global upload and download rate in KiB. "0" for unlimited.
download_rate = 0
upload_rate = 72

# Default directory to save the downloaded torrents.
directory = /volume1/public/rt/
session = /root/.rtorrent
# Default session directory. Make sure you don't run multiple instance
# of rtorrent using the same session directory. Perhaps using a
# relative path?
#session = ./session

# Watch a directory for new torrents, and stop those that have been
# deleted.
#schedule = watch_directory,5,5,load_start=./watch/*.torrent
#schedule = untied_directory,5,5,stop_untied=

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

# Stop torrents when reaching upload ratio in percent,
# when also reaching total upload in bytes, or when
# reaching final upload ratio in percent.
# example: stop at ratio 2.0 with at least 200 MB uploaded, or else ratio 20.0
schedule = ratio,60,60,"stop_on_ratio=200,200M,2000"
# The ip address the listening socket and outgoing connections is
# bound to.
#bind = 127.0.0.1
#bind = rakshasa.no

# Port range to use for listening.
port_range = 45789

# Start opening ports at a random position within the port range.
#port_random = no

# Check hash for finished torrents. Might be usefull until the bug is
# fixed that causes lack of diskspace not to be properly reported.
#check_hash = no
# The ip address reported to the tracker.
#ip = 127.0.0.1
#ip = rakshasa.no

# The ip address the listening socket and outgoing connections is
# bound to.
#bind = 127.0.0.1
#bind = rakshasa.no

# Port range to use for listening.
port_range = 45789

# Start opening ports at a random position within the port range.
#port_random = no

# Check hash for finished torrents. Might be usefull until the bug is
# fixed that causes lack of diskspace not to be properly reported.
#check_hash = no

# Set whetever the client should try to connect to UDP trackers.
#use_udp_trackers = yes

# Alternative calls to bind and ip that should handle dynamic ip's.
#schedule = ip_tick,0,1800,ip=rakshasa
#schedule = bind_tick,0,1800,bind=rakshasa

# Encryption options, set to none (default) or any combination of the following:
# Port range to use for listening.
port_range = 45789

# Start opening ports at a random position within the port range.
#port_random = no

# Check hash for finished torrents. Might be usefull until the bug is
# fixed that causes lack of diskspace not to be properly reported.
#check_hash = no

# Set whetever the client should try to connect to UDP trackers.
#use_udp_trackers = yes

# Alternative calls to bind and ip that should handle dynamic ip's.
#schedule = ip_tick,0,1800,ip=rakshasa
#schedule = bind_tick,0,1800,bind=rakshasa

# Encryption options, set to none (default) or any combination of the following:
# allow_incoming, try_outgoing, require, require_RC4, enable_retry, prefer_plaintext
#
# The example value allows incoming encrypted connections, starts unencrypted
# outgoing connections but retries with encryption if they fail, preferring
# plaintext to RC4 encryption after the encrypted handshake
#
# encryption = allow_incoming,enable_retry,prefer_plaintext

# Enable DHT support for trackerless torrents or when all trackers are down.
# May be set to "disable" (completely disable DHT), "off" (do not start DHT),
# "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
# The default is "off". For DHT to work, a session directory must be defined.
# The ip address reported to the tracker.
#ip = 127.0.0.1
#ip = rakshasa.no

# The ip address the listening socket and outgoing connections is
# bound to.
#bind = 127.0.0.1
#bind = rakshasa.no
# Port range to use for listening.
port_range = 45789

# Start opening ports at a random position within the port range.
#port_random = no

# Check hash for finished torrents. Might be usefull until the bug is
# fixed that causes lack of diskspace not to be properly reported.
#check_hash = no

# Set whetever the client should try to connect to UDP trackers.
#use_udp_trackers = yes

# Alternative calls to bind and ip that should handle dynamic ip's.
#schedule = ip_tick,0,1800,ip=rakshasa
#schedule = bind_tick,0,1800,bind=rakshasa

# Encryption options, set to none (default) or any combination of the following:
# allow_incoming, try_outgoing, require, require_RC4, enable_retry, prefer_plaintext
# Enable DHT support for trackerless torrents or when all trackers are down.
# May be set to "disable" (completely disable DHT), "off" (do not start DHT),
# "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
# The default is "off". For DHT to work, a session directory must be defined.

# Set whetever the client should try to connect to UDP trackers.
#use_udp_trackers = yes

# Alternative calls to bind and ip that should handle dynamic ip's.
#schedule = ip_tick,0,1800,ip=rakshasa
#schedule = bind_tick,0,1800,bind=rakshasa

# Encryption options, set to none (default) or any combination of the following:
# allow_incoming, try_outgoing, require, require_RC4, enable_retry, prefer_plaintext
#
# The example value allows incoming encrypted connections, starts unencrypted
# outgoing connections but retries with encryption if they fail, preferring
# plaintext to RC4 encryption after the encrypted handshake
#
# encryption = allow_incoming,enable_retry,prefer_plaintext

# Enable DHT support for trackerless torrents or when all trackers are down.
# May be set to "disable" (completely disable DHT), "off" (do not start DHT),
# "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
# The default is "off". For DHT to work, a session directory must be defined.
#
# dht = auto

# UDP port to use for DHT.
#
# dht_port = 6881

# Enable peer exchange (for torrents not marked private)
#
# peer_exchange = yes

#
# Do not modify the following parameters unless you know what you're doing.
#

# Hash read-ahead controls how many MB to request the kernel to read
# ahead. If the value is too low the disk may not be fully utilized,
# while if too high the kernel might not be able to keep the read
# pages in memory thus end up trashing.
#hash_read_ahead = 10

# Interval between attempts to check the hash, in milliseconds.
#hash_interval = 100

# Number of attempts to check the hash while using the mincore status,
# before forcing. Overworked systems might need lower values to get a
# decent hash checking rate.
#hash_max_tries = 10
scgi_local = /tmp/rpc.socket
dimip
Beginner
Beginner
 
Posts: 25
Joined: Fri Feb 22, 2008 12:22 am

Re: Howto: RTorrent with Webinterface

Postby beagleboy » Wed May 21, 2008 6:52 am

hey dimip

here is a copy of my .rtorrent.rc file if you want to copy and use. I have added your ip range and I have also included a line for a watch folder that you can unhash if you need to use (you will need to remember to add the folder on you DS). Hope it works for you.

BB

Code: Select all
# This is an example resource file for rTorrent. Copy to
# ~/.rtorrent.rc and enable/modify the options as needed. Remember to
# uncomment the options you wish to enable.

# Maximum and minimum number of peers to connect to per torrent.
min_peers = 40
max_peers = 100

# Same as above but for seeding completed torrents (-1 = same as downloading)
min_peers_seed = 10
max_peers_seed = 50

# Maximum number of simultanious uploads per torrent.
max_uploads = 15

# Global upload and download rate in KiB. "0" for unlimited.
download_rate = 0
upload_rate = 72

# Default directory to save the downloaded torrents.
directory = /volume1/public/rt/

# Default session directory. Make sure you don't run multiple instance
# of rtorrent using the same session directory. Perhaps using a
# relative path?
session = /root/.rtorrent

# Watch a directory for new torrents, and stop those that have been
# deleted.
#schedule = watch_directory,5,5,load_start=/volume1/torrentwatch/*.torrent
#schedule = untied_directory,5,5,stop_untied=

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

# Stop torrents when reaching upload ratio in percent,
# when also reaching total upload in bytes, or when
# reaching final upload ratio in percent.
# example: stop at ratio 2.0 with at least 200 MB uploaded, or else ratio 20.0
schedule = ratio,60,60,"stop_on_ratio=200,200M,2000"
#schedule = ratio,60,60,"stop_on_ratio=150,"

# The ip address reported to the tracker.
#ip = 127.0.0.1
#ip = rakshasa.no

# The ip address the listening socket and outgoing connections is
# bound to.
#bind = 127.0.0.1
#bind = rakshasa.no

# Port range to use for listening.
port_range = 45789-45789


# Start opening ports at a random position within the port range.
port_random = no

# Check hash for finished torrents. Might be usefull until the bug is
# fixed that causes lack of diskspace not to be properly reported.
check_hash = no

# Set whetever the client should try to connect to UDP trackers.
#use_udp_trackers = yes

scgi_local = /root/.rtorrent/rpc.socket
#scgi_port = 127.0.0.1:5000

# Alternative calls to bind and ip that should handle dynamic ip's.
#schedule = ip_tick,0,1800,ip=rakshasa
#schedule = bind_tick,0,1800,bind=rakshasa

# Encryption options, set to none (default) or any combination of the following:
# allow_incoming, try_outgoing, require, require_RC4, enable_retry, prefer_plaintext
#
# The example value allows incoming encrypted connections, starts unencrypted
# outgoing connections but retries with encryption if they fail, preferring
# plaintext to RC4 encryption after the encrypted handshake
#
 encryption = allow_incoming,try_outgoing,enable_retry

# Enable DHT support for trackerless torrents or when all trackers are down.
# May be set to "disable" (completely disable DHT), "off" (do not start DHT),
# "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
# The default is "off". For DHT to work, a session directory must be defined.
#
# dht = auto

# UDP port to use for DHT.
#
# dht_port = 6881

# Enable peer exchange (for torrents not marked private)
#
# peer_exchange = yes

#
# Do not modify the following parameters unless you know what you're doing.
#

# Hash read-ahead controls how many MB to request the kernel to read
# ahead. If the value is too low the disk may not be fully utilized,
# while if too high the kernel might not be able to keep the read
# pages in memory thus end up trashing.
#hash_read_ahead = 10

# Interval between attempts to check the hash, in milliseconds.
#hash_interval = 100

# Number of attempts to check the hash while using the mincore status,
# before forcing. Overworked systems might need lower values to get a
# decent hash checking rate.
#hash_max_tries = 10
User avatar
beagleboy
Beginner
Beginner
 
Posts: 21
Joined: Fri Feb 08, 2008 10:34 pm

Re: Howto: RTorrent with Webinterface

Postby pableu » Wed May 21, 2008 9:17 am

dimip wrote:nice guide good work .... i have followed the guide and i am almost done. i have stuck to this point any ideas what might be wrong?

The rtorrent.rc you posted looks pretty screwed up.. the "Port Range" option for example appears multiple times, this shouldn't be.

Is rTorrent running correctly if you start it manually? Does it give you any error messages?

What do you have at the end of the lighttpd.conf, in the part where it says "scgi-server"?
pableu
Sharp
Sharp
 
Posts: 162
Joined: Wed May 09, 2007 9:33 pm

Re: Howto: RTorrent with Webinterface

Postby dimip » Wed May 21, 2008 12:04 pm

i fixed it like this but still the same error
Code: Select all
    # This is an example resource file for rTorrent. Copy to
    # ~/.rtorrent.rc and enable/modify the options as needed. Remember to
    # uncomment the options you wish to enable.

    # Maximum and minimum number of peers to connect to per torrent.
    min_peers = 40
    max_peers = 100

    # Same as above but for seeding completed torrents (-1 = same as downloading)
    min_peers_seed = 10
    max_peers_seed = 50

    # Maximum number of simultanious uploads per torrent.
    max_uploads = 15

    # Global upload and download rate in KiB. "0" for unlimited.
    download_rate = 0
    upload_rate = 72

    # Default directory to save the downloaded torrents.
    directory = /volume1/public/rt/

    # Default session directory. Make sure you don't run multiple instance
    # of rtorrent using the same session directory. Perhaps using a
    # relative path?
    session = /root/.rtorrent

    # Watch a directory for new torrents, and stop those that have been
    # deleted.
    #schedule = watch_directory,5,5,load_start=/volume1/torrentwatch/*.torrent
    #schedule = untied_directory,5,5,stop_untied=

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

    # Stop torrents when reaching upload ratio in percent,
    # when also reaching total upload in bytes, or when
    # reaching final upload ratio in percent.
    # example: stop at ratio 2.0 with at least 200 MB uploaded, or else ratio 20.0
    schedule = ratio,60,60,"stop_on_ratio=200,200M,2000"
    #schedule = ratio,60,60,"stop_on_ratio=150,"

    # The ip address reported to the tracker.
    #ip = 127.0.0.1
    #ip = rakshasa.no

    # The ip address the listening socket and outgoing connections is
    # bound to.
    #bind = 127.0.0.1
    #bind = rakshasa.no

    # Port range to use for listening.
    port_range = 45789-45789


    # Start opening ports at a random position within the port range.
    port_random = no

    # Check hash for finished torrents. Might be usefull until the bug is
    # fixed that causes lack of diskspace not to be properly reported.
    check_hash = no

    # Set whetever the client should try to connect to UDP trackers.
    #use_udp_trackers = yes

    scgi_local = /root/.rtorrent/rpc.socket
    #scgi_port = 127.0.0.1:5000

    # Alternative calls to bind and ip that should handle dynamic ip's.
    #schedule = ip_tick,0,1800,ip=rakshasa
    #schedule = bind_tick,0,1800,bind=rakshasa

    # Encryption options, set to none (default) or any combination of the following:
    # allow_incoming, try_outgoing, require, require_RC4, enable_retry, prefer_plaintext
    #
    # The example value allows incoming encrypted connections, starts unencrypted
    # outgoing connections but retries with encryption if they fail, preferring
    # plaintext to RC4 encryption after the encrypted handshake
    #
    encryption = allow_incoming,try_outgoing,enable_retry

    # Enable DHT support for trackerless torrents or when all trackers are down.
    # May be set to "disable" (completely disable DHT), "off" (do not start DHT),
    # "auto" (start and stop DHT as needed), or "on" (start DHT immediately).
    # The default is "off". For DHT to work, a session directory must be defined.
    #
    # dht = auto

    # UDP port to use for DHT.
    #
    # dht_port = 6881

    # Enable peer exchange (for torrents not marked private)
    #
    # peer_exchange = yes

    #
    # Do not modify the following parameters unless you know what you're doing.
    #

    # Hash read-ahead controls how many MB to request the kernel to read
    # ahead. If the value is too low the disk may not be fully utilized,
    # while if too high the kernel might not be able to keep the read
    # pages in memory thus end up trashing.
    #hash_read_ahead = 10

    # Interval between attempts to check the hash, in milliseconds.
    #hash_interval = 100

    # Number of attempts to check the hash while using the mincore status,
    # before forcing. Overworked systems might need lower values to get a
    # decent hash checking rate.
    #hash_max_tries = 10


Code: Select all
# lighttpd configuration file
#
# use it as a base for lighttpd 1.0.0 and above
#
# $Id: lighttpd.conf 8127 2008-04-03 05:13:22Z rwhitby $

############ Options you really have to take care of ####################

## modules to load
# at least mod_access and mod_accesslog should be loaded
# all other module should only be loaded if really neccesary
# - saves some time
# - saves memory
server.modules              = (
#                               "mod_rewrite",
#                               "mod_redirect",
#                               "mod_alias",
                                "mod_access",
#                               "mod_cml",
#                               "mod_trigger_b4_dl",
                                "mod_auth",
#                               "mod_status",
#                               "mod_setenv",
                                "mod_fastcgi",
                                "mod_scgi",
#                               "mod_proxy",
#                               "mod_simple_vhost",
#                               "mod_evhost",
#                               "mod_userdir",
                                "mod_cgi",
#                               "mod_compress",
#                               "mod_ssi",
#                               "mod_usertrack",
#                               "mod_expire",
#                               "mod_secdownload",
#                               "mod_rrdtool",
                                "mod_accesslog" )

## a static document-root, for virtual-hosting take look at the
## server.virtual-* options
server.document-root        = "/opt/share/www/"

## where to send error-messages to
server.errorlog             = "/opt/var/log/lighttpd/error.log"

# files to check for if .../ is requested
index-file.names            = ( "index.php", "index.html",
                                "index.htm", "default.htm",
            "lighttpd/index.html" )

## set the event-handler (read the performance section in the manual)
# server.event-handler = "freebsd-kqueue" # needed on OS X

# mimetype mapping
mimetype.assign             = (
  ".pdf"          =>      "application/pdf",
  ".sig"          =>      "application/pgp-signature",
  ".spl"          =>      "application/futuresplash",
  ".class"        =>      "application/octet-stream",
  ".ps"           =>      "application/postscript",
  ".torrent"      =>      "application/x-bittorrent",
  ".dvi"          =>      "application/x-dvi",
  ".gz"           =>      "application/x-gzip",
  ".pac"          =>      "application/x-ns-proxy-autoconfig",
  ".swf"          =>      "application/x-shockwave-flash",
  ".tar.gz"       =>      "application/x-tgz",
  ".tgz"          =>      "application/x-tgz",
  ".tar"          =>      "application/x-tar",
  ".zip"          =>      "application/zip",
  ".mp3"          =>      "audio/mpeg",
  ".m3u"          =>      "audio/x-mpegurl",
  ".wma"          =>      "audio/x-ms-wma",
  ".wax"          =>      "audio/x-ms-wax",
  ".ogg"          =>      "application/ogg",
  ".wav"          =>      "audio/x-wav",
  ".gif"          =>      "image/gif",
  ".jpg"          =>      "image/jpeg",
  ".jpeg"         =>      "image/jpeg",
  ".png"          =>      "image/png",
  ".xbm"          =>      "image/x-xbitmap",
  ".xpm"          =>      "image/x-xpixmap",
  ".xwd"          =>      "image/x-xwindowdump",
  ".css"          =>      "text/css",
  ".html"         =>      "text/html",
  ".htm"          =>      "text/html",
  ".js"           =>      "text/javascript",
  ".asc"          =>      "text/plain",
  ".c"            =>      "text/plain",
  ".cpp"          =>      "text/plain",
  ".log"          =>      "text/plain",
  ".conf"         =>      "text/plain",
  ".text"         =>      "text/plain",
  ".txt"          =>      "text/plain",
  ".dtd"          =>      "text/xml",
  ".xml"          =>      "text/xml",
  ".mpeg"         =>      "video/mpeg",
  ".mpg"          =>      "video/mpeg",
  ".mov"          =>      "video/quicktime",
  ".qt"           =>      "video/quicktime",
  ".avi"          =>      "video/x-msvideo",
  ".asf"          =>      "video/x-ms-asf",
  ".asx"          =>      "video/x-ms-asf",
  ".wmv"          =>      "video/x-ms-wmv",
  ".bz2"          =>      "application/x-bzip",
  ".tbz"          =>      "application/x-bzip-compressed-tar",
  ".tar.bz2"      =>      "application/x-bzip-compressed-tar"
 )

# Use the "Content-Type" extended attribute to obtain mime type if possible
#mimetype.use-xattr        = "enable"


## send a different Server: header
## be nice and keep it at lighttpd
# server.tag                 = "lighttpd"

#### accesslog module
accesslog.filename          = "/opt/var/log/lighttpd/access.log"

## deny access the file-extensions
#
# ~    is for backupfiles from vi, emacs, joe, ...
# .inc is often used for code includes which should in general not be part
#      of the document-root
url.access-deny             = ( "~", ".inc" )

$HTTP["url"] =~ "\.pdf$" {
  server.range-requests = "disable"
}

##
# which extensions should not be handle via static-file transfer
#
# .php, .pl, .fcgi are most often handled by mod_fastcgi or mod_cgi
static-file.exclude-extensions = ( ".fcgi", ".php", ".pl", ".py", ".rb" )

######### Options that are good to be but not neccesary to be changed #######

## bind to port (default: 80)
server.port                = 8081

## bind to localhost (default: all interfaces)
#server.bind                = "grisu.home.kneschke.de"

## error-handler for status 404
#server.error-handler-404   = "/error-handler.html"
#server.error-handler-404   = "/error-handler.php"

## to help the rc.scripts
server.pid-file            = "/var/run/lighttpd.pid"


###### virtual hosts
##
##  If you want name-based virtual hosting add the next three settings and load
##  mod_simple_vhost
##
## document-root =
##   virtual-server-root + virtual-server-default-host + virtual-server-docroot
## or
##   virtual-server-root + http-host + virtual-server-docroot
##
#simple-vhost.server-root   = "/home/weigon/wwwroot/servers/"
#simple-vhost.default-host  = "grisu.home.kneschke.de"
#simple-vhost.document-root = "/pages/"


##
## Format: <errorfile-prefix><status-code>.html
## -> ..../status-404.html for 'File not found'
#server.errorfile-prefix    = "/home/weigon/projects/lighttpd/doc/status-"

## virtual directory listings
#dir-listing.activate       = "enable"

## enable debugging
#debug.log-request-header   = "enable"
#debug.log-response-header  = "enable"
#debug.log-request-handling = "enable"
#debug.log-file-not-found   = "enable"

### only root can use these options
#
# chroot() to directory (default: no chroot() )
#server.chroot              = "/"

## change uid to <uid> (default: don't care)
#server.username            = "nobody"

## change uid to <uid> (default: don't care)
#server.groupname           = "nobody"

#### compress module
#compress.cache-dir         = "/tmp/lighttpd/cache/compress/"
#compress.filetype          = ("text/plain", "text/html")

#### proxy module
## read proxy.txt for more info
#proxy.server               = ( ".php" =>
#                               ( "localhost" =>
#                                 (
#                                   "host" => "192.168.0.101",
#                                   "port" => 80
#                                 )
#                               )
#                             )

#### fastcgi module
## read fastcgi.txt for more info
#fastcgi.server             = ( ".php" =>
#                               ( "localhost" =>
#                                 (
#                                   "socket" => "/tmp/php-fcgi.sock",
#                                   "bin-path" => "/opt/bin/php-fcgi",
#                                   "bin-environment" => (
#                                      "PHP_FCGI_MAX_REQUESTS" => "4000"
#                                   )
#                                 )
#                               )
#                            )

#### CGI module
#cgi.assign                 = ( ".pl"  => "/opt/bin/perl",
#                               ".cgi" => "/opt/bin/perl" )
#

#### SSL engine
#ssl.engine                 = "enable"
#ssl.pemfile                = "server.pem"
#ssl.ca-file                = "ca.crt"
#ssl.verifyclient.activate  = "enable"
#ssl.verifyclient.enforce   = "enable"
#ssl.verifyclient.depth     = 1

#### status module
#status.status-url          = "/server-status"
#status.config-url          = "/server-config"

#### auth module
## read authentication.txt for more info
#auth.backend               = "plain"
#auth.backend.plain.userfile = "lighttpd.user"
#auth.backend.plain.groupfile = "lighttpd.group"

#auth.backend.ldap.hostname = "localhost"
#auth.backend.ldap.base-dn  = "dc=my-domain,dc=com"
#auth.backend.ldap.filter   = "(uid=$)"

#auth.require               = ( "/server-status" =>
#                               (
#                                 "method"  => "digest",
#                                 "realm"   => "download archiv",
#                                 "require" => "user=jan"
#                               ),
#                               "/server-config" =>
#                               (
#                                 "method"  => "digest",
#                                 "realm"   => "download archiv",
#                                 "require" => "valid-user"
#                               )
#                             )

#### url handling modules (rewrite, redirect, access)
#url.rewrite                = ( "^/$"             => "/server-status" )
#url.redirect               = ( "^/wishlist/(.+)" => "http://www.123.org/$1" )
#### both rewrite/redirect support back reference to regex conditional using %n
#$HTTP["host"] =~ "^www\.(.*)" {
#  url.redirect            = ( "^/(.*)" => "http://%1/$1" )
#}

#
# define a pattern for the host url finding
# %% => % sign
# %0 => domain name + tld
# %1 => tld
# %2 => domain name without tld
# %3 => subdomain 1 name
# %4 => subdomain 2 name
#
#evhost.path-pattern        = "/home/storage/dev/www/%3/htdocs/"

#### expire module
#expire.url                 = ( "/buggy/" => "access 2 hours", "/asdhas/" => "access plus 1 seconds 2 minutes")

#### ssi
#ssi.extension              = ( ".shtml" )

#### rrdtool
#rrdtool.binary             = "/opt/bin/rrdtool"
#rrdtool.db-name            = "/var/www/lighttpd.rrd"

#### setenv
#setenv.add-request-header  = ( "TRAV_ENV" => "mysql://user@host/db" )
#setenv.add-response-header = ( "X-Secret-Message" => "42" )

## for mod_trigger_b4_dl
# trigger-before-download.gdbm-filename = "/home/weigon/testbase/trigger.db"
# trigger-before-download.memcache-hosts = ( "127.0.0.1:11211" )
# trigger-before-download.trigger-url = "^/trigger/"
# trigger-before-download.download-url = "^/download/"
# trigger-before-download.deny-url = "http://127.0.0.1/index.html"
# trigger-before-download.trigger-timeout = 10

## for mod_cml
## don't forget to add index.cml to server.indexfiles
# cml.extension               = ".cml"
# cml.memcache-hosts          = ( "127.0.0.1:11211" )

#### variable usage:
## variable name without "." is auto prefixed by "var." and becomes "var.bar"
#bar = 1
#var.mystring = "foo"

## integer add
#bar += 1
## string concat, with integer cast as string, result: "www.foo1.com"
#server.name = "www." + mystring + var.bar + ".com"
## array merge
#index-file.names = (foo + ".php") + index-file.names
#index-file.names += (foo + ".php")

#### include
#include /etc/lighttpd/lighttpd-inc.conf
## same as above if you run: "lighttpd -f /etc/lighttpd/lighttpd.conf"
#include "lighttpd-inc.conf"

#### include_shell
#include_shell "echo var.a=1"
## the above is same as:
#var.a=1

# Configuration from other optware packages
include_shell "cat /opt/etc/lighttpd/conf.d/*.conf"
scgi.server = (
               "/RPC2" =>
                 ( "127.0.0.1" =>
                   (
                     "socket" => "/root/.rtorrent/rpc.socket",
                     "check-local" => "disable",
                     "disable-time" => 0,
                   )
                 )
             )
dimip
Beginner
Beginner
 
Posts: 25
Joined: Fri Feb 22, 2008 12:22 am

Re: Howto: RTorrent with Webinterface

Postby pableu » Wed May 21, 2008 3:56 pm

pableu wrote:Is rTorrent running correctly if you start it manually? Does it give you any error messages?
:?:
pableu
Sharp
Sharp
 
Posts: 162
Joined: Wed May 09, 2007 9:33 pm

Re: Howto: RTorrent with Webinterface

Postby dimip » Thu May 22, 2008 1:01 am

pableu wrote:
pableu wrote:Is rTorrent running correctly if you start it manually? Does it give you any error messages?
:?:


i dont see any error
[Throttle off/off KB] [Rate 0.0/ 0.0 KB] [Port: 45789] [U 0/0] [D 0/0] [H 0/32] [S 0/3/768] [F 0/128]
*** rTorrent 0.8.2/0.12.2 - Cook:2580 ***
[View: main]
[Throttle off/off KB] [Rate 0.0/ 0.0 KB] [Port: 45789] [U 0/0] [D 0/0] [H 0/32] [S 0/3/768] [F 0

PID Uid VmSize Stat Command
1 root 304 S init
2 root SWN [ksoftirqd/0]
3 root SW< [events/0]
4 root SW< [khelper]
5 root SW< [kthread]
11 root SW< [kblockd/0]
36 root SW [pdflush]
37 root SW [pdflush]
39 root SW< [aio/0]
38 root SW [kswapd0]
106 root SW< [ata/0]
109 root SW< [scsi_eh_0]
110 root SW< [scsi_eh_1]
111 root SW< [scsi_eh_2]
112 root SW< [scsi_eh_3]
130 root SW [mtdblockd]
150 root SW< [md0_raid1]
152 root SW< [md1_raid1]
154 root SW< [md2_raid1]
279 root SW [kjournald]
536 root SW< [khubd]
997 root 304 S /sbin/syslogd -S
999 root 236 S /sbin/klogd
1125 root 1036 S < /usr/syno/bin/findhostd
1149 root SW [kjournald]
1196 root 1932 S /usr/syno/sbin/nmbd -D
1222 root 952 S /usr/syno/sbin/hotplugd
1256 root 596 S /usr/sbin/inetd
1264 root 652 S /usr/sbin/crond
1289 admin 2432 S /usr/syno/pgsql/bin/postgres -D /var/database/pgsql -
1291 admin 1856 S postgres: writer process
1292 admin 656 S postgres: stats collector process
1391 root 376 S /bin/sh /usr/syno/mysql/bin/mysqld_safe --datadir=/vo
1448 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1449 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1450 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1451 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1452 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1453 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1460 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1461 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1462 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1463 admin 13092 S /usr/syno/mysql/libexec/mysqld --basedir=/usr/syno/my
1498 root 1452 S /usr/syno/sbin/scheduler
1503 admin 2740 S postgres: admin download [local] idle
1509 root 1144 S /usr/syno/bin/scemd
1630 root 916 S lpd Waiting
1799 root 5008 S N /usr/syno/sbin/synoindexd
2019 root 704 S N /usr/syno/bin/synomkthumbd
2155 admin 6528 S postgres: admin photo [local] idle
2158 root 1316 S /opt/sbin/lighttpd -f /opt/etc/lighttpd/lighttpd.conf
2163 root 4736 S /opt/bin/php-fcgi
2173 root 5468 S /opt/bin/php-fcgi
2174 root 4732 S /opt/bin/php-fcgi
2175 root 188 R telnetd
2176 root 344 S -ash
2262 root 276 S /sbin/getty 115200 console
2338 root 1840 S /usr/syno/sbin/smbd -D
2347 root 860 S /usr/syno/sbin/smbd -D
2382 root 924 S N /usr/syno/sbin/synomkflvd
2411 root 448 S /usr/syno/sbin/synorcd
2429 root 2356 S /usr/syno/apache/bin/httpd -f /usr/syno/apache/conf/h
2477 root 2008 S /usr/syno/apache/bin/httpd -f /usr/syno/apache/conf/h
2478 root 1944 S /usr/syno/apache/bin/httpd -f /usr/syno/apache/conf/h
2479 root 5580 S /usr/syno/apache/bin/httpd
2533 root 1600 S /usr/syno/sbin/ftpd -D -z secure
2538 admin 4492 S /usr/syno/apache/bin/httpd
2539 admin 4492 S /usr/syno/apache/bin/httpd
2540 admin 4492 S /usr/syno/apache/bin/httpd
2577 root 848 S SCREEN -d -m rtorrent -n -o import=/root/.rtorrent.rc
2580 root 4536 S rtorrent -n -o import=/root/.rtorrent.rc
2691 root 1460 S /usr/syno/apache/bin/httpd -f /usr/syno/apache/conf/h
2693 root 1460 S /usr/syno/apache/bin/httpd -f /usr/syno/apache/conf/h
2694 root 1460 S /usr/syno/apache/bin/httpd -f /usr/syno/apache/conf/h
2703 root 3080 S /usr/syno/sbin/ftpd -D -z secure
2717 root 636 R ps


ps. i found also this by searching a solution but it didnt help also:
Also you should change the dir to something like /tmp/rpc.socket, since lighttpd is not able to access the /root folder

This is strange now:
Cook> /opt/etc/init.d/S99rtorrent stop
Stopping rtorrent: rtorrent.
Cook> /opt/etc/init.d/S99rtorrent start
Starting rtorrent: rtorrent/opt/etc/init.d/S99rtorrent: /opt/etc/init.d/S99rtorr ent: 176: root: not found
rtorrentInit.log is empty
dimip
Beginner
Beginner
 
Posts: 25
Joined: Fri Feb 22, 2008 12:22 am

Re: Howto: RTorrent with Webinterface

Postby PeTIKTeam » Thu May 22, 2008 12:44 pm

Veri gud, veri gud howto: http://petik.uw.hu/rtgui.html
PeTIKTeam
I'm New!
I'm New!
 
Posts: 1
Joined: Thu May 22, 2008 12:40 pm

Re: Howto: RTorrent with Webinterface

Postby dimip » Thu May 22, 2008 2:06 pm

finally it worked too much trouble and now from the only tracker i download i get this error '' could not parse bencoded it data and low disk space and i have more than 400gb free space
Image
dimip
Beginner
Beginner
 
Posts: 25
Joined: Fri Feb 22, 2008 12:22 am

PreviousNext

Return to Torrent Engines/Download Station Mods

Who is online

Users browsing this forum: No registered users and 3 guests