# rtorrent and 100% CPU

## Mr. Death

Hi, I have problem on my new router with rtorrent. After while it tooks 100% of CPU. I've tried masked version too with the same problem. On my previous router it worked normal. I can't locate the problem. Do you know, where could be the problem? Or what to check? Thanks in advance and sorry if it's in wrong section.

----------

## audiodef

The first thing I would do is start rtorrent from a terminal and watch any output. Is there any?

----------

## Mr. Death

Usually it's starts CPU drain, when someone starts downloading, but it isn't OK and even when there isn't any traffic it holds 100%.

I've tried disable all parameters, same problem.

Here is my configuration:

directory=torrent_dir

download_rate=6M

upload_rate=6M

bind = my_ip

port_range = 26900-26990

use_udp_trackers = yes

check_hash = no

session = /var/rtorrent

system.umask.set = 0000

dht = off

#dht_port = 26991

encryption = allow_incoming, try_outgoing,enable_retry, prefer_plaintext

peer_exchange = yes

scgi_port = 127.0.0.1:5000

encoding_list = UTF-8

max_memory_usage = 1400M

network.send_buffer.size.set = 2M

network.receive_buffer.size.set = 4M

min_peers = 80

max_peers = 160

min_peers_seed = 160

max_peers_seed = 320

max_uploads = 40

----------

## M

This happened to me too recently.

No such behaviour since I recompiled rtorrent with xmlrpc flag disabled. I don't use web frontend anyway, I guess that is what xmlrpc is for.

----------

## Mr. Death

Tried disable xmlrpc and same problem. I don't know, what else should I check.  :Sad: 

----------

## Mr. Death

Now I've tried downgrade to previous version (0.8.7/0.12.7) and receiving segfaults. When trying open rtgui. It could be connected with newer version of XMLRPC.

But no 100% CPU. Definitely newer versions have some problems.

----------

## chrisyu

Had same problem too, x86 and amd64, multiple versions.

Now I switched to transmission.   :Embarassed: 

You could try re-emerge curl with USE='-threads ares', after I switched to transmission, there is a bug if you emerge curl with threads.

But this is just a blind shot.

Good luck.Last edited by chrisyu on Fri May 04, 2012 3:02 am; edited 1 time in total

----------

## Mr. Death

 *chrisyu wrote:*   

> Had same problem too, x86 and amd64, multiple versions.
> 
> Now I switched to transmission.  
> 
> You could try re-emerge curl with USE='-threads ares', after I switched to transmission, there is a bug if you emerge curl with threads.
> ...

 

It seems it helped. Meanwhile my harddrive is almost dead and need replace and I can't to test it properly. Thank you.

----------

## trubicoid

 *chrisyu wrote:*   

> try re-emerge curl with USE='-threads ares'

 

it helped, thanks a lot!  :Very Happy: 

----------

## Mr. Death

Yes, it helped and there is something wrong with curl.

----------

## trubicoid

actually the new unstable version of curl doesn't allow you to choose together ares and threads.

but I haven't tried -ares threads, maybe it also works.

----------

## trubicoid

so -ares +threads and curl-7.25.0-r1 results in 100%cpu usage

keep +ares -threads

----------

## alex67500

Hi,

this is not a Gentoo specific issue, it seems to be the case of FreeBSD too.

Have you managed to solve it?

Thanks.

-- 

Alex

----------

## Mr. Death

I've solved by using older curl.

----------

