Bekijk de volledige versie : Настройка wtorrent
Раньше юзал rtorrent через консоль. Решил повысить юзабилити - скачал и поставил wtorrent.
поправил часть конфига home.conf.php
// SQLite database file (set folder permision 0777 or chmod to httpd server) (wTorrent will create database when running install.php)
define( 'DB_FILE', 'db/database.db');
// Host or IP to connect to rTorrent
define( 'RT_HOST', 'localhost');
/*define( 'RT_PORT', 65532);*/
define( 'RT_PORT', 8080);
define( 'RT_DIR', 'RPC2/');
define( 'RT_AUTH', false);
define( 'RT_USER', 'my_user');
define( 'RT_PASSWD', 'my_password');
// where to use multicall or not
// if wTorrent makes your rtorrent crash, set this to true
define( 'NO_MULTICALL', true);
// Directory in which to save uploaded .torrent files (set folder permision 0777 or chmod to httpd server)
define( 'DIR_TORRENTS', '/home/torrents/watch/');
// Full path to application directory (where index.php is)
define( 'DIR_EXEC', '/opt/share/www/wtorrent/');
// Permision to set for uploaded .torrent files (don't touch unless you know)
define( 'PERM_TORRENTS', 0777);
// Default location to save downloaded files (can be set for every uploaded .torrent on the ui)
define( 'DIR_DOWNLOAD', '/home/torrents/incoming/');
порт 8080 - на котором запущен lighttpd
/home/torrents/watch/ - каталог с .torrent-файлами
/home/torrents/incoming/ - с закаченными торрентами
Странно - rtorrent используется еще папка /home/torrents/session - wtorrent ее нигде не спрашивает.
Теперь через wtorrent у меня получается добавлять файлы в очередь. Но во закладке Main висит только надпись "No torrents found". Ни новые торренты, добавленные через веб-интерфейс, ни старые, добавлявшиеся путем копирования в watch не отображаются :( Причем через консоль rtorrent видно, что они скачиваются
В чем тут может быть проблема?
oxygen121
29-04-2008, 06:26
Раньше юзал rtorrent через консоль. Решил повысить юзабилити - скачал и поставил wtorrent.
поправил часть конфига home.conf.php
// SQLite database file (set folder permision 0777 or chmod to httpd server) (wTorrent will create database when running install.php)
define( 'DB_FILE', 'db/database.db');
// Host or IP to connect to rTorrent
define( 'RT_HOST', 'localhost');
/*define( 'RT_PORT', 65532);*/
define( 'RT_PORT', 8080);
define( 'RT_DIR', 'RPC2/');
define( 'RT_AUTH', false);
define( 'RT_USER', 'my_user');
define( 'RT_PASSWD', 'my_password');
// where to use multicall or not
// if wTorrent makes your rtorrent crash, set this to true
define( 'NO_MULTICALL', true);
// Directory in which to save uploaded .torrent files (set folder permision 0777 or chmod to httpd server)
define( 'DIR_TORRENTS', '/home/torrents/watch/');
// Full path to application directory (where index.php is)
define( 'DIR_EXEC', '/opt/share/www/wtorrent/');
// Permision to set for uploaded .torrent files (don't touch unless you know)
define( 'PERM_TORRENTS', 0777);
// Default location to save downloaded files (can be set for every uploaded .torrent on the ui)
define( 'DIR_DOWNLOAD', '/home/torrents/incoming/');
порт 8080 - на котором запущен lighttpd
/home/torrents/watch/ - каталог с .torrent-файлами
/home/torrents/incoming/ - с закаченными торрентами
Странно - rtorrent используется еще папка /home/torrents/session - wtorrent ее нигде не спрашивает.
Теперь через wtorrent у меня получается добавлять файлы в очередь. Но во закладке Main висит только надпись "No torrents found". Ни новые торренты, добавленные через веб-интерфейс, ни старые, добавлявшиеся путем копирования в watch не отображаются :( Причем через консоль rtorrent видно, что они скачиваются
В чем тут может быть проблема?
Ресурс RPC2 доступен? http://server:8080/rpc2 проверьте браузером
Ресурс RPC2 доступен? http://server:8080/rpc2 проверьте браузером
http://my_ip:8080/RPC2 доступен, нет ошибки 404. Но страничка полностью пустая. Вроде так и должно быть?
http://my_ip:8080/RPC2 доступен, нет ошибки 404. Но страничка полностью пустая. Вроде так и должно быть?
Нет, уже недоступен. Пока я пробовал все что можно переустановить. Обновил rtorrent, xmlrpc
Получил ошибку 500 - Internal Server Error
В логе с ошибками lighttpd имею
2008-04-29 15:18:54: (log.c.75) server started
2008-04-29 15:19:04: (mod_scgi.c.2219) establishing connection failed: Connection refused
2008-04-29 15:19:04: (mod_scgi.c.2353) fcgi-server disabled: 127.0.0.1 5000
2008-04-29 15:19:04: (mod_scgi.c.2821) no fcgi-handler found for: /RPC2
А рторренту сказали, чтобы отвечал на xmlrpc?
А рторренту сказали, чтобы отвечал на xmlrpc?
Единственную строку добавил в .rtorrent.rc
scgi_port = 127.0.0.1:5000
А рторренту сказали, чтобы отвечал на xmlrpc?
Извиняюсь за ламоразм. rtorrent не был запущен в фоне, поэтому и была ошибка 500. Запустил - снова появилась чистая страничка.
Тем не менее, wtorrent все-равно ничего не отображает.
Кстати, в логе рторрента сразу после запуска есть
(15:50:07) XMLRPC initialized with 444 functions.
(15:50:07) The SCGI socket is bound to a specific network device yet may still pose a security risk, consider using 'scgi_local'.
Кстати, в логе рторрента сразу после запуска есть
rtorrent отображает?
Если нет - конфигурационные файл rtorrent кажите.
Если да - гляньте, не светится ли там напротив закачек сообщения от трекера. В случае, если пользуете русские трекеры, кидающие сообщения об ошибках не на английском и не в utf, а скажем, в кои - веб морда при их появлении работать не будет. А может и rtorrent завалить. Ошибка там в блоке xmlrpc. Причем сложно сказать, у кого.
Общий совет - оставьте эту прогрессивную идею, насчет веб-морды. Поимеете проблемы. Основная - из-за еще одной ошибки автора в реализации xmlrpc при пользовании веб-морды (причем все равно какой) происходит массивная утечка памяти.
rtorrent отображает?
Если нет - конфигурационные файл rtorrent кажите.
Если да - гляньте, не светится ли там напротив закачек сообщения от трекера. В случае, если пользуете русские трекеры, кидающие сообщения об ошибках не на английском и не в utf, а скажем, в кои - веб морда при их появлении работать не будет. А может и rtorrent завалить. Ошибка там в блоке xmlrpc. Причем сложно сказать, у кого.
Общий совет - оставьте эту прогрессивную идею, насчет веб-морды. Поимеете проблемы. Основная - из-за еще одной ошибки автора в реализации xmlrpc при пользовании веб-морды (причем все равно какой) происходит массивная утечка памяти.
Да, в логе самого рторрента всё отображается.
Его конфиг:
# 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 = 1
max_peers = 100
# Same as above but for seeding completed torrents (-1 = same as downloading)
min_peers_seed = 5
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 = 0
# Default directory to save the downloaded torrents.
directory = /home/torrents/incoming
# Default session directory. Make sure you don't run multiple instance
# of rtorrent using the same session directory. Perhaps using a
# relative path?
session = /home/torrents/session
# Watch a directory for new torrents, and stop those that have been
# deleted.
schedule = watch_directory,5,5,load_start=/home/torrents/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 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 = 6890-6999
# 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
# 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 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 = 200
# 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 = 5
# +++++++++++++++
session_save = yes
scgi_port = 127.0.0.1:5000
Сообщений от трекеров не увидел. Есть только сообщения о состоянии закачки под каждым торрентом(каждая третья строка получается).
Веб-морду уж очень хочется поставить. Хотя бы для работы удаленно, чтобы следить за торрентами и новые добавлять.
Просто ftp+ssh неудобно.
есть плагин для TC типа ftp via ssh. Я думал через него файлы закачивать, а он не подключается толком к роутеру. Поэтому ставлю морду. Да и наглядность все-таки повыше будет.
oxygen121
29-04-2008, 19:52
Да, в логе самого рторрента всё отображается.
Его конфиг:
# 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 = 1
max_peers = 100
# Same as above but for seeding completed torrents (-1 = same as downloading)
min_peers_seed = 5
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 = 0
# Default directory to save the downloaded torrents.
directory = /home/torrents/incoming
# Default session directory. Make sure you don't run multiple instance
# of rtorrent using the same session directory. Perhaps using a
# relative path?
session = /home/torrents/session
# Watch a directory for new torrents, and stop those that have been
# deleted.
schedule = watch_directory,5,5,load_start=/home/torrents/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 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 = 6890-6999
# 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
# 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 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 = 200
# 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 = 5
# +++++++++++++++
session_save = yes
scgi_port = 127.0.0.1:5000
Сообщений от трекеров не увидел. Есть только сообщения о состоянии закачки под каждым торрентом(каждая третья строка получается).
Веб-морду уж очень хочется поставить. Хотя бы для работы удаленно, чтобы следить за торрентами и новые добавлять.
Просто ftp+ssh неудобно.
есть плагин для TC типа ftp via ssh. Я думал через него файлы закачивать, а он не подключается толком к роутеру. Поэтому ставлю морду. Да и наглядность все-таки повыше будет.
Я вот что советую , попробуйте приконнектится ntorrent-ом для начала http://code.google.com/p/ntorrent/
Тем самым мы проверим работоспособность самого RPC2. Да еще торренты на всякий случай из клиента пока удалите , и попробуйте добавить новый через ntorrent. Только желательно чтобы название файла было в латинице. Если получится приконнектися,то надо ковырять wtorrent если нет то рторрент с лайтхттпд.
Вообще странно, у меня все завелось с под оборота.
Веб-морду уж очень хочется поставить.
Чего мог, все уже сказал. Из прочих советов - поставьте в конфиге
encoding_list = UTF-8
Mashiro-sama
30-04-2008, 12:45
В конфиге lighttpd прописано в server.modules
"mod_scgi"
и
scgi.server = (
"/RPC2" => # RT_DIR
( "127.0.0.1" =>
(
"host" => "127.0.0.1", # Ip where rtorrent is listening
"port" => 5000, # Port specified in .rtorrent.rc
"check-local" => "disable",
"disable-time" => 0
)
)
)
???
Я вот что советую , попробуйте приконнектится ntorrent-ом для начала http://code.google.com/p/ntorrent/
Тем самым мы проверим работоспособность самого RPC2. Да еще торренты на всякий случай из клиента пока удалите , и попробуйте добавить новый через ntorrent. Только желательно чтобы название файла было в латинице. Если получится приконнектися,то надо ковырять wtorrent если нет то рторрент с лайтхттпд.
Вообще странно, у меня все завелось с под оборота.
Вы были правы! Какой-то из торрентов (потом выясню какой точно ) не давал работать wtorrent. Снес все торренты, запустил Wtorrent и добавил через него один - отображается! :D
Тут возникает еще 2 проблемы. Он у всех НАСТОЛЬКО тормозной? У меня полминуты обновляется страничка.
Что-то я не совсем понял с функционалом его. То ли баг очередной у меня, то и так и должно быть. Вот добавлен один торрент. Рядом с ним 4 иконки - работает только одна - удаление. И вообще ничего больше не нажимается. Я грешу на AJAX. В чем может быть проблема здесь?
Вы были правы!
Это не он был прав, а я :) Какой-то из торрентов у Вас имел reply от трекера в нехорошей кодировке. И если трекер продолжит ругаться на Ваши торренты, то все повторится сначала.
Это не он был прав, а я :) Какой-то из торрентов у Вас имел reply от трекера в нехорошей кодировке. И если трекер продолжит ругаться на Ваши торренты, то все повторится сначала.
Я сначала просто не понял причинно-следственную связь :D
Все-таки вопрос про wtorrent остался. У меня не функционирует в приемлемом виде его AJAX. Торренты видны, добавляются, но остальные кнопочки не работают. Может нужны какие-нибудь дополнительные пакеты? Какая версия wtorrent точно работает?
Кстати, ntorrent у меня заработал. И очень даже неплохо. Но есть там единственный недостаток - нельзя опять-же скачанные торренты выкачивать на комп. Никто не пробовал работать через плагин SFTP для ТоталКомандера? Я поставил пакет openssh-sftp-server на роутер, но Тотал тупо зависает при коннекте :(
Но есть там единственный недостаток - нельзя опять-же скачанные торренты выкачивать на комп.
У Вас, IMHO, какие-то странные проблемы.
1) Веб-морда не должна этим заниматься, на это есть самба или, на худой конец, WinSCP.
2) Зачем их вообще выкачивать? Смотрите из под самбы прямо по месту. Это все, разумеется, если Вы из внутренней сети все это дело пользуете.
Может нужны какие-нибудь дополнительные пакеты?
Может, посмотреть настройки браузера, или вообще сменить последний?
Какая версия wtorrent точно работает?
Не в курсе. Свою собственную веб-морду пользую.
wtorrent заваливает консоль ошибок в Firefox
Ошибка: syntax error
Источник: http://192.168.1.40:8080/wtorrent/index.php?cls=ListT
Строка 1, Символ 1
Исходный код:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
Ошибка: RUZEE is not defined
Источник: http://192.168.1.40:8080/wtorrent/index.php?cls=ListT
Строка: 48
Ошибка: Bora has no properties
Источник: http://192.168.1.40:8080/wtorrent/index.php?cls=ListT
Строка: 552
Ошибка: document.getElementsByClassName is not a function
Источник: http://192.168.1.40:8080/wtorrent/index.php?cls=ListT
Строка: 38
Ошибка: Ajax is not defined
Источник: http://192.168.1.40:8080/wtorrent/index.php?cls=ListT
Строка: 107
Браузеры менял, кэши очищал, 5 версий Wtorrent перепробовал. Ну не хочет она работать по-нормальному...
Короче, не оправдала моих надежд эта морда. Оставлю ее на всякий случай, чтобы торренты можно было удаленно залить, но пользоваться ей невозможно :(
Свою собственную веб-морду пользую.
Наcчет последнего - полностью согласен. Уже думаю разобраться с Xmlrpc и написать простенькую морду для себя без всяких навороченных AJAX и БД.
Спасибо за помощь! :)
featZima
13-06-2009, 11:00
Наcчет последнего - полностью согласен. Уже думаю разобраться с Xmlrpc и написать простенькую морду для себя без всяких навороченных AJAX и БД.
Так может и поделитесь потом полученным результатом?) Хотя у меня web морда работает нормально, но очень медленно... много времени выполняются php скрипты...