Page 175 of 227 FirstFirst ... 75125165173174175176177185225 ... LastLast
Results 2,611 to 2,625 of 3396

Thread: Еще раз про rTorrent и web-морду к нему.

  1. #2611
    Неделю бьюсь над этим решил уже форматнуть винт но думаю врдуг тут помогут? Спасибо!

    s99rtorrent:

    Code:
    #!/bin/sh
    
    user="p2p"
    prefix="/opt"
    config="/opt/etc/rtorrent.conf"
    options="-n -o import=/opt/etc/rtorrent.conf,http_cacert=/opt/etc/ssl/certs/cacert.pem"
    base="/opt/share/torrent"
    
    # name of screen session
    srnname="rtorrent"
    
    # file to log to (makes for easier debugging if something goes wrong)
    logfile="/opt/var/log/rtorrentInit.log"
    #######################
    ###END CONFIGURATION###
    #######################
    PATH=/opt/bin:/opt/sbin:/usr/bin:/sbin:/bin:/usr/sbin
    DESC="rtorrent"
    NAME=rtorrent
    DAEMON=$NAME
    SCRIPTNAME=/etc/init.d/$NAME
    
    # Do not proceed unless some apps are available.
    test -x /opt/bin/screen || ( echo "screen not found." | tee -a "$logfile" >&2 ; exit 2 )
    test -x /opt/bin/su -o -x /bin/su || ( echo "su not found." | tee -a "$logfile" >&2 ; exit 2 )
    
    checkcnfg() {
    <------>exists=0
    <------>for i in `echo "$PATH" | tr ':' '\n'` ; do
    <------><------>if [ -f $i/$NAME ] ; then
    <------><------><------>exists=1
    <------><------><------>break
    <------><------>fi
    <------>done
    <------>if [ $exists -eq 0 ] ; then
    <------><------>echo "cannot find rtorrent binary in PATH $PATH" | tee -a "$logfile" >&2
    <------><------>exit 3
    <------>fi
    <------>if ! [ -r "${config}" ] ; then.
    <------><------>echo "cannot find readable config ${config}. check that it is there and permissions are appropriate" | tee -a "$logfile" >&2
    <------><------>exit 3.
    <------>fi.
    <------>session=`getsession "$config"`.
    <------>if ! [ -d "${session}" ] ; then
    <------><------>echo "cannot find readable session directory ${session} from config ${config}. check permissions" | tee -a "$logfile" >&2
    <------><------>exit 3
    <------>fi
    }
    
    d_start() {
      [ -d "${base}" ] && cd "${base}"
      stty stop undef && stty start undef
      su -c "screen -ls | grep -sq "\.${srnname}[[:space:]]" " ${user} || su -c "screen -dm -S ${srnname} 2>&1 1>/dev/null" ${user} | tee -a "$logfile" >&2
      # this works for the screen command, but starting rtorrent below adopts screen session gid
      # even if it is not the screen session we started (e.g. running under an undesirable gid
      #su -c "screen -ls | grep -sq "\.${srnname}[[:space:]]" " ${user} || su -c "sg \"$group\" -c \"screen -fn -dm -S ${srnname} 2>&1 1>/dev/null\"" ${user} | tee -a "$logfile" >&2
      su -c "screen -S "${srnname}" -X screen rtorrent ${options} 2>&1 1>/dev/null" ${user} | tee -a "$logfile" >&2
    }
    d_stop() {
    <------>session=`getsession "$config"`
    <------>if ! [ -s ${session}/rtorrent.lock ] ; then
    <------><------>return
    <------>fi
    <------>pid=`cat ${session}/rtorrent.lock | awk -F: '{print($2)}' | sed "s/[^0-9]//g"`
    <------>if ps -A | grep -sq ${pid}.*rtorrent ; then # make sure the pid doesn't belong to another process
    <------><------>kill -s INT ${pid}
    <------>fi
    }
    
    getsession() {.
    <------>session=`awk '/^[[:space:]]*session[[:space:]]*=[[:space:]]*/{print($3)}' "$config"`
    <------>echo $session
    }
    
    checkcnfg
    
    case "$1" in
      start)
    <------>echo -n "Starting $DESC: $NAME"
    <------>d_start
    <------>echo "."
    <------>;;
      stop)
    <------>echo -n "Stopping $DESC: $NAME"
    <------>d_stop
    <------>echo "."
    <------>;;
      restart|force-reload)
    <------>echo -n "Restarting $DESC: $NAME"
    <------>d_stop
    <------>sleep 1
    <------>d_start
    <------>echo "."
    <------>;;
      *)
    <------>echo "Usage: $SCRIPTNAME {start|stop|restart|force-reload}" >&2
    <------>exit 1
    <------>;;
    esac
    
    exit 0
    Last edited by selon81; 27-09-2009 at 12:30.

  2. #2612
    access.log:

    Code:
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/da.gif HTTP/1.1" 200 1164 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET C
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/nl.gif HTTP/1.1" 200 915 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CL
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/fi.gif HTTP/1.1" 200 941 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CL
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/it.gif HTTP/1.1" 200 1091 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET C
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/lv.gif HTTP/1.1" 200 379 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CL
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/pl.gif HTTP/1.1" 200 915 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CL
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/fr.gif HTTP/1.1" 200 927 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CL
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/de.gif HTTP/1.1" 200 1037 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET C
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/hu.gif HTTP/1.1" 200 928 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CL
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/br.gif HTTP/1.1" 200 1209 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET C
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/sk.gif HTTP/1.1" 200 1052 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET C
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/uk.gif HTTP/1.1" 200 1054 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET C
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/lang/images/es.gif HTTP/1.1" 200 643 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CL
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:12 +0700] "GET /rtorrent/palette/0/images/bul_f.gif HTTP/1.1" 200 45 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1;
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:13 +0700] "GET /rtorrent/palette/0/images/bul.gif HTTP/1.1" 200 51 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .N
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:13 +0700] "GET /rtorrent/palette/0/images/bul_l.gif HTTP/1.1" 200 46 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1;
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:14 +0700] "POST /rtorrent/getplugins.php HTTP/1.1" 200 71 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:32:14 +0700] "POST /rtorrent/getsettings.php HTTP/1.1" 200 1109 "http://192.168.3.1:8081/rtorrent/" "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR
    192.168.3.2 192.168.3.1:8081 - [27/Sep/2009:08:35:24 +0700] "POST /rtorrent/getplugins.php HTTP/1.1" 200 71 "http://192.168.3.1:8081/rtorrent/" "Mozilla/5.0 (Windows; U; Windows NT 5.1; ru; rv:1.9.0.13) Geck

  3. #2613
    config.php:

    Code:
    <?php
        // configuration parameters
    
        define('HTTP_USER_AGENT', 'Mozilla/5.0 (Windows; U; Windows NT 5.1; pl; rv:1.9) Gecko/2008052906 Firefox/3.0');
        define('HTTP_TIME_OUT', 30);
        define('HTTP_USE_GZIP', true);
    
        define('RPC_TIME_OUT', 15);><------>// in seconds
        define('DO_DIAGNOSTIC', true);<---->
    
        $uploads = './torrents';<--><------>// temp directory for uploaded torrents, without tail slash
        $settings = './settings';<-><------>// settings directory, without tail slash
    
        $scgi_port = 5000;
        $scgi_host = "127.0.0.1";
    
        $pathToPHP = '';<--><------><------>// Something like /bin/php. If empty, will be founded in PATH.
        $pathToCurl = '';<-><------><------>// Something like /bin/curl. If empty, will be founded in PATH.
    
        // For web->rtorrent link through unix domain socket.
        // (scgi_local in rtorrent conf file), change variables.
        // above to something like this:
        //
        // $scgi_port = 0;
        // $scgi_host = "unix:///tmp/rpc.socket";
    ?>

  4. #2614
    lighttpd.conf:

    Code:
    # lighttpd configuration file
    #
    # use it as a base for lighttpd 1.0.0 and above
    #
    # $Id: lighttpd.conf 8860 2008-08-05 10:56:16Z engy $
    
    ############ 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_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.activate  = "enable"
    #ssl.verifyclient.enforce   = "enable"
    #ssl.verifyclient.depth     = 1
    
    #### status module
    #status.status-url          = "/server-status"
    #status.config-url          = "/server-config"
    
    
    
    # Configuration from other optware packages
    include_shell "cat /opt/etc/lighttpd/conf.d/*.conf"
    Last edited by selon81; 27-09-2009 at 12:49.

  5. #2615
    rtorrent.conf:

    Code:
    # 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.
    scgi_port = 127.0.0.1:5000
    enable_trackers = yes
    session_save = yes
    encoding_list = UTF-8
    # Minumum amount of peers to connect per torrent, if available.
    min_peers = 10
    # Minumum amount of peers to connect per torrent.
    max_peers = 400
    
    # Same as above but for seeding completed torrents (-1 = same as downloading)
    min_peers_seed = 100
    #max_peers_seed = 20
    
    # Maximum number of simultanious uploads per torrent.
    max_uploads = 50
    
    # Global download rate in KiB. "0" for unlimited.
    download_rate = 0
    
    # Global upload rate in KiB. "0" for unlimited.
    upload_rate = 0
    
    # Default directory to save downloaded files. Note it doesn't support
    # space yet.
    directory = /opt/share/torrent/work/
    
    # Watch a directory for new torrents, and stop those that have been deleted.
    schedule = watch_directory,5,5,load_start=/opt/share/torrent/dl/*.torrent
    schedule = untied_directory,5,5,stop_untied=
    
    # Close torrents when diskspace is low.
    #schedule = low_diskspace,5,60,close_low_diskspace=100M
    
    # Default session directory. Make sure you don't run multiple instance
    # of rtorrent using the same session directory. Perhaps using a
    # relative path?
    session = /opt/share/torrent/session
    
    # The ip address reported to the tracker.
    #ip =.
    
    # The ip address the listening socket and outgoing connections is
    # bound to.
    #bind = rakshasa
    
    # Port range to use for listening.
    port_range = 51777-51780
    
    # 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 = yes
    
    # 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
    
    #
    # 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
    
    # Max number of files to keep open simultaniously.
    #max_open_files = 128
    
    # Number of sockets to simultaneously keep open.
    #max_open_sockets = <no default>
    
    
    # Example of scheduling commands: Switch between two ip's every 5
    # seconds.
    #schedule = "ip_tick1,5,10,ip=torretta"
    #schedule = "ip_tick2,10,10,ip=lampedusa"
    
    # Remove a scheduled event.
    #schedule_remove = "ip_tick1"
    
    # 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,30,60,stop_on_ratio=200
    
    
    # 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 = off
    
    # UDP port to use for DHT.
    #.
    dht_port = 51780
    
    # Enable peer exchange (for torrents not marked private)
    #
    peer_exchange = yes
    
    #
    # Do not modify the following parameters unless you know what you're doing.
    #
    max_memory_usage=2147483648

  6. #2616
    Подключение mod_scgi где?

  7. #2617
    Хотелось бы задать один вопрос относительно rtorrent.
    Когда он запущен в виде процесса, то обращается к внешнему винчестеру приблизительно раз в полчаса, даже если ничего не качается и не отдается. Я сначала грешил на опрос watching folder (что было бы логично), но даже когда я закомментировал соответствующую строчку в конфиге, ситуация не улучшилась.
    Проблема, само собой в том, что единоразовое обращение к винчестеру выводит его из спящего режима, и он начинает раскручиваться, и, соответственно, шуметь (особенно раздражает ночью). Кроме того, я подозреваю, что такое включение-выключение здоровья винчестеру не прибавит. Сейчас выхожу из положения тем, что просто использую два батника через putty, один из которых включает, а второй выключает rtorrent, когда он нужен или не нужен соответственно. Однако такое решение, конечно, тоже не самое удобное, учитывая, что я собираюсь сделать доступ к веб-морде извне.
    Может, у кого-то есть идеи, из-за чего идет регулярное обращение к винчестеру, и где нужно копать, чтобы его не было (когда торрент ничего не качает).

  8. #2618
    Quote Originally Posted by freeman_g View Post
    Может, у кого-то есть идеи, из-за чего идет регулярное обращение к винчестеру
    Сессию он сохраняет раз в полчаса.
    Quote Originally Posted by freeman_g View Post
    и где нужно копать, чтобы его не было
    Копать в сторону покупки менее шумного диска.

  9. #2619
    Да в общем-то черт с ним, с шумом. Меня больше беспокоит, что винт загнется такими темпами.

  10. #2620
    Quote Originally Posted by freeman_g View Post
    Да в общем-то черт с ним, с шумом. Меня больше беспокоит, что винт загнется такими темпами.
    У мене уже год работает, все штатно. А загнется - не велика беда, себя он окупил уже. Опять же - диск *должен* работать 24/7, ситуация, когда у Вас нет активных торрентов ненормальна, весь смысл держать качалку на роутере теряется. Т.к. с компьютера оно всяко быстрее работать будет.
    Варианты:
    1) Убрать поддержку сессии. Но в случае падения/рестарта могут быть проблемы, вообще, IMHO, без сессии работать нельзя.
    2) Увеличить интервал сохранения сессии. Проблемы те же, что и в 1.
    3) Включать/отключать качалку через крон, как, собственно, Вы и делаете.

  11. #2621
    Ну, на самом деле, смысл есть. К примеру, кино удаленно дома на закачку поставить, чтобы пришел - а оно уже на винте. Винт и шумит меньше, чем компьютер, так что можно пренебречь шумом, да и поставить на закачку на ночь.

  12. #2622

    Как настроить rtorrent+сессии и post-mount

    Помогите ответить на следующие вопросы:

    1. Бывает что rtorrent слитает вдруг - и потом приходится страртовать вручную (как лучше прописать cron) и все торренты перехешируются... я слsifk что можно пользоваться сессиями и тогда не будет повторного хеширования... Как это сделать или с какими ключами запускать rtorrent?

    2. При перезагрузке роутера, не запускаются команды выделенные красным цветом - как их правильно прописать, то приходится ручками стартовать??
    ---.post-mount----
    #!/bin/sh
    /sbin/swapon /dev/scsi/host0/bus0/target0/lun0/part2
    /bin/mount -o sync,noatime,rw /dev/discs/disc0/part2 /tmp/harddisk
    /bin/mount -o bind /tmp/harddisk/opt /opt
    /opt/etc/init.d/rc.unslung
    /sbin/route add default gw 192.168.1.1 dev br0
    /bin/echo "nameserver 192.168.1.1" >> /etc/resolv.conf
    killall -1 dnsmasq

    /opt/etc/init.d/S10cron
    /opt/etc/init.d/S80lighttpd
    /opt/etc/init.d/S99rtorrent start
    /opt/etc/init.d/S99ushare start
    /opt/etc/init.d/S60mt-daapd
    samba_active=1
    /opt/sbin/smbd -D
    /opt/sbin/nmbd -D
    ---------

  13. #2623
    Join Date
    Feb 2008
    Location
    Moscow, Tver
    Posts
    3,962
    Quote Originally Posted by mixazen View Post
    Помогите ответить на следующие вопросы:

    1. Бывает что rtorrent слитает вдруг - и потом приходится страртовать вручную (как лучше прописать cron) и все торренты перехешируются... я слsifk что можно пользоваться сессиями и тогда не будет повторного хеширования... Как это сделать или с какими ключами запускать rtorrent?

    2. При перезагрузке роутера, не запускаются команды выделенные красным цветом - как их правильно прописать, то приходится ручками стартовать??
    ---.post-mount----
    #!/bin/sh
    /sbin/swapon /dev/scsi/host0/bus0/target0/lun0/part2
    /bin/mount -o sync,noatime,rw /dev/discs/disc0/part2 /tmp/harddisk
    /bin/mount -o bind /tmp/harddisk/opt /opt
    /opt/etc/init.d/rc.unslung
    /sbin/route add default gw 192.168.1.1 dev br0
    /bin/echo "nameserver 192.168.1.1" >> /etc/resolv.conf
    killall -1 dnsmasq

    /opt/etc/init.d/S10cron
    /opt/etc/init.d/S80lighttpd
    /opt/etc/init.d/S99rtorrent start
    /opt/etc/init.d/S99ushare start
    /opt/etc/init.d/S60mt-daapd
    samba_active=1
    /opt/sbin/smbd -D
    /opt/sbin/nmbd -D
    ---------
    Про сессии тут читайте, чуть раньше было описано.
    А post-mount у Вас зачем такой извращенный????
    При наличии скрипта rc.unslung запускать еще и каждый софт по-отдельности зачем???
    И разве само все не отрабатывает, зачем ТАК извращаться с дефолт гейтвеем и локальным DNS сервером???

  14. #2624

    недокачиваются файлы

    коллеги, периодически бывает вот такая картина (1.7b). закачки замирают на 99,8-99,9%


    виндовым клиентом те же файлы докачиваются. диск на роутере живой, без ошибок.

    в чем проблема?
    спасибо.
    Last edited by Pablo Escobar; 28-09-2009 at 19:12.

  15. #2625
    А какого типа эти файлы? Я так понял что не видео. Так вот, образы, архивы и просто исполняемые файлы большого размера у меня ВСЕГДА замирают на 99,х% (или переходят на сидирование, но если слить на комп и запустить хеширование на utorrent, то имеем те же 99%). Приходится докачивать компом. А вот видео, любых форматов, докачивает полностью. Такая картина у меня с самого начала эксплуатации рторрента. Решения пока тут не нашел. Народ списывал все на винт, но на нем ошибок нет и также нет конфликтов с роутером.

Page 175 of 227 FirstFirst ... 75125165173174175176177185225 ... LastLast

Similar Threads

  1. [How to] rtorrent & ntorrent
    By mancub in forum WL-500gP Tutorials
    Replies: 101
    Last Post: 18-12-2008, 07:21
  2. older rtorrent version
    By FastJack in forum WL-500gP Q&A
    Replies: 1
    Last Post: 23-10-2007, 09:40

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •