軟體的設定重點只有兩步:
1. 主機 IP 位址
2. 與 torrent 溝通使用的 SCGI 名稱:通常是 RPC2
在 Server 上與這個參數有關的地方共兩處:
(a) web server 裡面 scgi 設定項目
(b) .rtorrent.rc 檔內的 scgi_port 參數


在 Server 上與這個參數有關的地方共兩處:
(a) web server 裡面 scgi 設定項目
(b) .rtorrent.rc 檔內的 scgi_port 參數
User / Browser -->Web Server-->rutorrent--scgi:5000--> rtorrent一、安裝 web server、php、rtorrent、screen
前端叫:rutorrent (這是 php 寫成的網頁)
後端叫:rtorrent (兩者差一個"u"字 別搞錯了)
使用者用瀏覽器操作 UI 介面,訊號透過 SCGI 傳到後端的 rtorrent 程式。
Reading package lists... Done Building dependency tree Reading state information... Done The following NEW packages will be installed: lighttpd php5-cgi php5-common rtorrent spawn-fcgi After this operation, 23.4 MB of additional disk space will be used.
server.modules += ( "mod_fastcgi" ) fastcgi.server += ( ".php" => (( "bin-path" => "/usr/bin/php-cgi", "socket" => "/var/run/lighttpd/php.socket", "max-procs" => 1, "bin-environment" => ( "PHP_FCGI_CHILDREN" => "0", "PHP_FCGI_MAX_REQUESTS" => "10000" ), "bin-copy-environment" => ( "PATH", "SHELL", "USER" ), "broken-scriptfilename" => "enable" )) )
server.modules += ( "mod_scgi" ) scgi.server = ( "/RPC2"=> ( "127.0.0.1" => ( "host" => "127.0.0.1", "port" => 5000, "check-local" => "disable" ) ) )
* Stopping web server lighttpd [ OK ] * Starting web server lighttpd [ OK ]
# Maximum and minimum number of peers to connect to per torrent. min_peers = 20 max_peers = 60 # Same as above but for seeding completed torrents min_peers_seed = 1 max_peers_seed = 1 # Maximum number of simultanious uploads per torrent. max_uploads = 1 # Global upload and download rate in KiB. "0" for unlimited. download_rate = 1500 upload_rate = 1 # Default directory to save the downloaded torrents. directory = ./ # Default session directory. session = ./session # For Web UI (Rutorrent @ SCGI port 5000) scgi_port = localhost:5000 encoding_list = UTF-8 # Watch a directory for new torrents schedule = watch_directory,5,5, "load_start=./*.torrent, d.set_custom1=./../tmp" system.method.set_key = event.download.finished,move_complete,"execute=mv,-u,$d.get_base_path=,$d.get_custom1=;" # Enable DHT. dht = on dht_port = 6778 # Enable peer exchange peer_exchange = yes
(a) 透過網頁 http://x.x.x.x/jack/rutorrent/ 進行種子上傳。九、請記得:rtorrent 一定要在 screen 裡面執行,才能確保 torrent 運作不中斷。
(b) 透過 FTP 將種子上傳到 ~/bt/ 目錄下。