Hi,
Use gprof or similar to figure out where it is spending most of the
time, so that part might be optimized. I haven't really optimized or
tested rtorrent with that many torrents, so might very well be some
parts of the code in the client that currently doesn't scale well as
most of it was written for flexibility.
BTW, are you using 'scheduler.max_active'?
Jari Sundell
On Sun, Apr 17, 2011 at 4:55 PM, Steven Adams <[email protected]
<mailto:[email protected]>> wrote:
Hi,
I seed ALOT of torrents (9000+).. When i start rtorrent the CPU
goes to 100% usage for AGES, eventually rtorrent responds and the
CPU goes down to 10-15%.
If I choose to delete one of the hashing torrents or incomplete
the CPU goes to 100% again and rtorrent seems to lag.. sometimes
it just sits there for 20-30mins+..
Any ideas what can cause this? I have 16GB of memory and 2x quad
core cpus on Centos 5.
Backtrack
#0 0x00000031ff6c5bb7 in statfs64 () from /lib64/libc.so.6
#1 0x00000031ff6c5c41 in statvfs64 () from /lib64/libc.so.6
#2 0x00007ffff7b11ceb in torrent::FileList::free_diskspace
(this=<value optimized out>) at ../../../rak/fs_stat.h:71
#3 0x00007ffff7b20e57 in operator() (this=0x66ea950, flags=3) at
../../rak/functional.h:507
#4 torrent::ChunkList::sync_chunks (this=0x66ea950, flags=3) at
chunk_list.cc:253
#5 0x00007ffff7b06cb8 in torrent::resume_save_progress
(download=<value optimized out>, object=..., onlyCompleted=true)
at resume.cc:162
#6 0x00000000004718d1 in core::DownloadList::resume (this=<value
optimized out>, download=0x66eb0d0, flags=0) at download_list.cc:345
#7 0x000000000043a5d1 in cmd_scheduler_simple_removed
(download=<value optimized out>, rawArgs=<value optimized out>)
at command_scheduler.cc:78
#8 0x0000000000418660 in rak::ptr_fn2_t<torrent::Object,
core::Download*, torrent::Object const&>::operator() (this=0x0,
arg1=0x7fffffffd580, arg2=...) at ../rak/functional_fun.h:215
#9 0x00000000004a976e in operator() (rawCommand=<value optimized
out>, target=0x7fffffffd6a0, rawArgs=...) at
../../rak/functional_fun.h:136
#10 rpc::CommandSlot<core::Download*>::call_unknown
(rawCommand=<value optimized out>, target=0x7fffffffd6a0,
rawArgs=...) at command_slot.cc:50
#11 0x00000000004a6b32 in rpc::CommandMap::call_command
(this=0x6fc7a0, key=0x593f208 "scheduler.simple.removed",
arg=..., target=...) at command_map.cc:160
#12 0x00000000004b0b30 in rpc::parse_command (target=...,
first=<value optimized out>, last=0x746dab "") at
parse_commands.cc:138
#13 0x00000000004b19af in rpc::parse_command_multiple
(target=..., first=0x7fffffffd6a0 "", last=0x746dab "") at
parse_commands.cc:148
#14 0x0000000000487ad7 in parse_command_multiple_d_nothrow
(this=0x746c30, download=0x59b5120) at ./../rpc/parse_commands.h:87
#15 core::View::erase (this=0x746c30, download=0x59b5120) at
view.cc:154
#16 0x0000000000474eea in operator() (__first=<value optimized
out>, __last=..., __f=...) at
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/bits/stl_function.h:656
#17 operator() (__first=<value optimized out>, __last=...,
__f=...) at
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/bits/stl_function.h:446
#18 std::for_each<__gnu_cxx::__normal_iterator<core::View**,
std::vector<core::View*, std::allocator<core::View*> > >,
std::binder2nd<std::mem_fun1_t<void, core::View, core::Download*>
> > (__first=<value optimized out>, __last=...,
__f=...) at
/usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/bits/stl_algo.h:159
#19 0x0000000000473fa4 in core::DownloadList::erase
(this=0x71ed50, itr=<value optimized out>) at download_list.cc:192
#20 0x00000000004195ce in operator() (this=<value optimized out>,
target=0x7ffff6c6f720, arg1=<value optimized out>) at
../rak/functional.h:525
#21 rpc::object_void_fn_t<core::Download*,
rak::mem_fun1<core::DownloadList, void, core::Download*>,
void>::operator() (this=<value optimized out>,
target=0x7ffff6c6f720, arg1=<value optimized out>) at
rpc/command_slot.h:113
#22 0x00000000004a976e in operator() (rawCommand=<value optimized
out>, target=0x7fffffffd6a0, rawArgs=...) at
../../rak/functional_fun.h:136
#23 rpc::CommandSlot<core::Download*>::call_unknown
(rawCommand=<value optimized out>, target=0x7fffffffd6a0,
rawArgs=...) at command_slot.cc:50
#24 0x00000000004a6b32 in rpc::CommandMap::call_command
(this=0x6fc7a0, key=0x1893828 "d.erase", arg=..., target=...) at
command_map.cc:160
#25 0x00000000004b0b30 in rpc::parse_command (target=...,
first=<value optimized out>, last=0xa3cb520 "") at
parse_commands.cc:138
#26 0x0000000000422a31 in d_multicall (rawArgs=<value optimized
out>) at command_events.cc:373
#27 0x00000000004241cd in rak::ptr_fn1_t<torrent::Object,
torrent::Object const&>::operator() (this=0x0, arg1=...) at
../rak/functional_fun.h:201
#28 0x00000000004aac94 in
operator()<rpc::target_wrapper<void>::no_type*>
(rawCommand=0x6f9d10, target=<value optimized out>, rawArgs=...)
at ../../rak/functional_fun.h:156
#29 rpc::CommandSlot<void>::call_list (rawCommand=0x6f9d10,
target=<value optimized out>, rawArgs=...) at command_slot.cc:59
#30 0x00000000004a6382 in rpc::CommandMap::call_command
(this=<value optimized out>, itr=..., arg=..., target=...) at
command_map.cc:193
#31 0x00000000004b4f77 in rpc::xmlrpc_call_command
(env=0x7fffffffe6a0, args=<value optimized out>,
voidServerInfo=<value optimized out>) at xmlrpc.cc:454
#32 0x00007ffff76d690c in callNamedMethod (envP=0x7fffffffe6a0,
registryP=0x747260, methodName=0x15897a60 "d.multicall",
paramArrayP=0x19102cd0, callInfoP=0x0, resultPP=0x7fffffffe6b8)
at registry.c:311
#33 xmlrpc_dispatchCall (envP=0x7fffffffe6a0, registryP=0x747260,
methodName=0x15897a60 "d.multicall", paramArrayP=0x19102cd0,
callInfoP=0x0, resultPP=0x7fffffffe6b8) at registry.c:337
#34 0x00007ffff76d6a94 in xmlrpc_registry_process_call2
(envP=0x7fffffffe730, registryP=0x747260,
callXml=0xfb5280f "<?xml version=\"1.0\"
encoding=\"UTF-8\"?>\r\n<methodCall>\r\n<methodName>d.multicall</methodName>\r\n<params>\r\n<param><value><string>hashing</string></value></param>\r\n<param><value><string>d.erase=</string></v"...,
callXmlLen=241, callInfo=0x0, responseXmlPP=0x7fffffffe720) at
registry.c:426
#35 0x00007ffff76d6b8a in xmlrpc_registry_process_call
(envP=0x66eb7f8, registryP=0x7fffffffd580, host=<value optimized
out>, callXml=0x0, callXmlLen=18446744073709551615) at registry.c:466
#36 0x00000000004b3c35 in rpc::XmlRpc::process (this=0x6fc7e0,
inBuffer=0xfb5280f "<?xml version=\"1.0\"
encoding=\"UTF-8\"?>\r\n<methodCall>\r\n<methodName>d.multicall</methodName>\r\n<params>\r\n<param><value><string>hashing</string></value></param>\r\n<param><value><string>d.erase=</string></v"...,
length=241, slotWrite=...) at xmlrpc.cc:493
#37 0x0000000000435f15 in rak::mem_fn3_t<rpc::XmlRpc, bool, char
const*, unsigned int, rak::function2<bool, char const*, unsigned
int> >::operator() (this=0x7ffff6c6f720, arg1=0x7fffffffd580
"BSFX", arg2=0, arg3=<value optimized out>)
at ../rak/functional_fun.h:259
#38 0x00000000004b23e4 in operator() (this=0x766af0, task=0x766b18,
buffer=0xfb5280f "<?xml version=\"1.0\"
encoding=\"UTF-8\"?>\r\n<methodCall>\r\n<methodName>d.multicall</methodName>\r\n<params>\r\n<param><value><string>hashing</string></value></param>\r\n<param><value><string>d.erase=</string></v"...,
length=241) at ../../rak/functional_fun.h:173
#39 rpc::SCgi::receive_call (this=0x766af0, task=0x766b18,
buffer=0xfb5280f "<?xml version=\"1.0\"
encoding=\"UTF-8\"?>\r\n<methodCall>\r\n<methodName>d.multicall</methodName>\r\n<params>\r\n<param><value><string>hashing</string></value></param>\r\n<param><value><string>d.erase=</string></v"...,
length=241) at scgi.cc:166
#40 0x00000000004b37bd in rpc::SCgiTask::event_read
(this=0x766b18) at scgi_task.cc:185
#41 0x00007ffff7b02d6b in torrent::PollEPoll::perform
(this=0x72c190) at poll_epoll.cc:166
#42 0x00000000004846c2 in core::PollManagerEPoll::poll
(this=0x7331f0, timeout=<value optimized out>) at
poll_manager_epoll.cc:74
#43 0x0000000000443319 in main (argc=1, argv=0x7fffffffeaf8) at
main.cc:321
_______________________________________________
Libtorrent-devel mailing list
[email protected] <mailto:[email protected]>
http://rakshasa.no/mailman/listinfo/libtorrent-devel