This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Net extremely sluggish with new ktorrent

Tags: None
(comma "," separated)
tetrarch
Registered Member
Posts
1
Karma
0
The latest SVN version does appear to improve performance - other net traffic is able to get through now. Not sure how much overhead there is here, but it's definitely usable now compared to the 2.0.3 release version I tried before (which didn't maintain a stable download speed from *any* peer, even ones I set up myself using uTorrent on a local net). Thanks for the fixes!

For reference, symptoms of the previous problem include a high SendQ value on netstat -tn for *all* related sockets, and it looks like the code is simply flooding the TCP/IP stack. Some limit on number of connections to open / second might help there. A lot of routers will take issue with >5 connections/s, for example, and there is no reason to open more than 1 or 2 ports every second by default IMHO (2/s -> 120 connections per minute, unless you're running a high-bandwidth connection this should be enough!). Currently seeing 545 connections in FIN_WAIT1, which seems a little high, and 30 in ESTABLISHED, which isn't bad since I'm just uploading at the moment with 16 slots, as reported by:

netstat -tnp | grep ESTABLISHED|grep ktorrent|wc -l

However, there does seem to be an issue in the latest (24th Oct) SVN code, revision 598909. When running ktorrent the first time after updating, it worked okay. Seemed to be running fine so I left it to carry on the good work - at some point in the next 3 hours, it had crashed, and at the time I wasn't aware of the log file so didn't check that before restarting it. This time, it goes into an infinite loop on startup, so the main window is never shown. The log indicates that all the torrents are being loaded and reloaded:

Code: Select all
Starting download
Doing tracker request to url : ...
Starting download
Doing tracker request to url : ...
QM Stopping: ...
Saving 0 chunk downloads
QM Stopping: ...
Saving 0 chunk downloads
Starting download


The memory used ramps up until oom-killer takes over, and CPU is also at 100%. Deleting the tor* directories in the config directory "fixed" that, will post a bug report if it recurs.

Apart from that, there was an issue with torrent files being deleted before the program actually checked the validity (when "delete torrent after load" was set, not sure if this has been fixed). Everything else looks good, I even like the icons, and the program fits in well enough to the desktop, thanks!
imported4-Ivan
Registered Member
Posts
819
Karma
0

Wed Oct 25, 2006 2:42 pm
This error could be related to the changes I've made to QM last evening. If it happens again, try to find a pattern how to reproduce it.
jimisdead
Registered Member
Posts
8
Karma
0

Thu Oct 26, 2006 9:31 am
just posting to say I've got the same problem as the OP... I'm using kubuntu edgy, with ktorrent 2.0.3 from the repositiories. At the moment I don't have time to compile from the sources, but I will try to find time later in the week.
jimisdead
Registered Member
Posts
8
Karma
0

Tue Nov 07, 2006 3:48 pm
latest svn (4th Nov) didn't fix it for me... I am now trying it with the modifications posted earlier in the thread.

also, for extra clarification, the problem really seems to fluctuate. Sometimes ktorrent can run fine, but after a reboot, or other restarting of ktorrent it decides that it wants to knock out the network... strange.
jimisdead
Registered Member
Posts
8
Karma
0

Tue Nov 07, 2006 3:54 pm
and..... still no good. I had to quit ktorrent and wait 20 seconds before I could post this message. Firefox just times out on 'Connecting to www.etc.com'.
George
Moderator
Posts
5421
Karma
1

Tue Nov 07, 2006 6:09 pm
Are you behind a router ?
jimisdead
Registered Member
Posts
8
Karma
0

Tue Nov 07, 2006 6:27 pm
yep, a router connected through WPA encrypted 802.11g wireless
jimisdead
Registered Member
Posts
8
Karma
0

Tue Nov 07, 2006 6:41 pm
i am now starting to suspect that it's not ktorrent, but something at a lower level (in my case kubuntu edgy). testing with aMule has shown it too will cause the problem. And when copying to a NFS server on the local network I am getting issues of the copying dialog (when using kde) copying at 10-15MB/s up to around the 60 meg mark, where the whole computer freezes, no mouse movement or anything, until the actual copying catches up at it's real world speed of 600kb/s-1.0MB/s. The computer then unfreezes for a few seconds before the process repeats until the file is copied.

for reference, here is ksysguard, the top right hand square is the incoming data, and the bottom right hand corner is the outgoing data - the spike is where I started ktorrent.
Image

altogether I don't have any idea how to fix this... and I should note I this is just what I suspect is happening.

Last edited by jimisdead on Thu Nov 09, 2006 8:54 am, edited 1 time in total.
George
Moderator
Posts
5421
Karma
1

Wed Nov 08, 2006 7:38 pm
Maybe it is the WLAN card or a **** driver ? You should compare it with a normal ethernet connection and see if the same problems happen.
jimisdead
Registered Member
Posts
8
Karma
0

Thu Nov 09, 2006 11:03 am
i could slap myself in the head for not trying a driver reinstall earlier... but unfortunately it didn't work, even when i compiled older drivers and firmware... strangely copying via sftp seems to work fine though. :?
WebDrake
Registered Member
Posts
5
Karma
0

Sat Nov 11, 2006 1:30 pm
jimisdead wrote:i am now starting to suspect that it's not ktorrent, but something at a lower level (in my case kubuntu edgy). testing with aMule has shown it too will cause the problem.

I'm also running Edgy (Ubuntu, in my case) and seeing this problem. Nor did the new svn ktorrent help matters.

I noticed that Xorg suddenly starts taking up a huge amount of system resources (40% CPU) when KTorrent is running. Close KTorrent and it goes back to normal. It doesn't matter of KTorrent is minimised or whatever.

I don't seem to have the same problems when running on a serious institutional network. It's only at home, behind my cable modem (Motorola SB5100) that I see such issues.

(P.S. Lest anyone think using a "serious institutional network" could be an issue, the downloads are legit: Linux install ISOs. ;) )
dienadel
Registered Member
Posts
7
Karma
0

Sat Nov 11, 2006 6:39 pm
Hello, perhaps a bit latter, but i've the same problem as related in the message that opened this treadh.

It's ktorrent 2.0.3. I'm not sure, but i think that this happended too with the previous version.

One example that have not been mentioned:
I was downloading ubuntu (i use archlinux) by direct download. Speed: 350 KB/s. Opened ktorrent, and in a few minutes, that speed was only 30 KB/s. In ktorrent, at that moment, the down speed was 20, and up speed 30. Closed ktorrent and a few seconds later, the direct download growed up to 350.

bye
jdong
Registered Member
Posts
358
Karma
0

Sat Nov 11, 2006 9:37 pm
Are you sure you're not oversaturating your upload? I use wondershaper type traffic shaping on my network, and I never have these types of issues.
imported4-Daniel
Registered Member
Posts
7
Karma
0

Sun Nov 12, 2006 8:50 am
Hi!

I have the absolut same problem here with KTorrent 2.0.3 on kubuntu/edgy. Im also behind a router (surecom) and if i start KTorrent with ~4 torrents it takes about 4-5mins, than webtraffic gets very slow.

I noticed that opera only hase problems resolving the IPs of servers. So i guessed the DNS proxy of my router get saturated. If i enter an external DNS server into my resolve.conf (the DNS of my ISP, and not the router) the webtraffic gets stable again.

I looked with wireshark a bit into the traffic - but i didnt see much DNS traffic between my desktop and the router - the only think i find curious is, the my router broadcasts a ARP "how has 10.0.0.1" (thats me) 2-3 per second if KTorrent is running. But imho it should cache ARPs quite a time...

With ktorrent on, the router tends to lock up itself about after 1 houre (sometimes earlier sometimes later, sometimes not). I havent had any problems with azereus (under win and linux) and my bandwith is surly not saturated.

If i can help debug somehow - pls ask!

greetings, Daniel

PS: my setup: [broadband-modem]---[surecom-router]---[switch]---[3 other PCs, im the onlyone using torrent]
George
Moderator
Posts
5421
Karma
1

Sun Nov 12, 2006 11:38 am
Can you try a weekly snapshot ? For example the one from yesterday :

http://ktorrent.org/downloads/svn-snaps ... -06.tar.gz


Bookmarks



Who is online

Registered users: Bing [Bot], Evergrowing, Google [Bot]