aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: Number of connections  (Read 1552 times)

symbol

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 6
Number of connections
« on: July 29, 2006, 10:45:12 PM »

Hi again,

What is a connection in aMule? I guess that one download means one connection, and the same for an upload but... what else? Searches on the servers will need some connections, but I guess they are closed immediately after. I do not the implementation of aMule, but I guess the keepalives (to servers or clients) are sent through UDP so they don't need to use a connection. What am I missing? Why do I have always around 50 active connections?

My aMule came with max-connections = 50. I haven't seen in the amule wiki  (that doesn't mean it is not there, of course O:-) ) any rule of thumb about what is the correct value for that. I have some found some in eMule fora, however, that recommend several 100's or even 1000! My personal guess was that that does not make sense in aMule since the "Connections Graph Scale" slider in "Statistics" didn't go beyond 200, but then I moved it around and I didn't notice any effect.  ?(  So I guess I am more or less lost.  :(

Could anybody give any advice on that? TIA  :)
Logged

ken

  • Hero Member
  • *****
  • Karma: 4
  • Offline Offline
  • Posts: 825
Re: Number of connections
« Reply #1 on: July 30, 2006, 09:02:49 AM »

When you're connected to an ED2K server, that's a connection.  However, searches to servers other than the one to which you are connected are done via UDP, so they don't count as connections.  When you first discover a source, you will connect and ask for a file.  If that source has a free upload slot, you'll start downloading from them immediately and the connection will be kept open.  Otherwise, you'll go into their queue.  You won't keep a connection open to that source while you're on the queue, you'll just connect briefly every so often to see if you've moved to the front of their queue.

Similarly, when other clients are in your queue, they don't keep a connection open.  Clients in your upload slots do of course have a connection.

So, connections = 1 server connection + clients to whom you are uploading + sources from whom you're downloading + transient connections as you check in with sources and clients check in with you.

If you are running at the limit, then increasing the limit will permit you to be downloading from more sources simultaneously.  Note though, that if you're already downloading at your bandwidth limit then this won't really help.  The downside is that some routers choke on large numbers of connections, and each connection consumes a small amount of resources (memory, file descriptors, CPU, etc.) on your computer.
Logged

symbol

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 6
Re: Number of connections
« Reply #2 on: July 30, 2006, 01:40:11 PM »

Quote
Originally posted by ken
So, connections = 1 server connection + clients to whom you are uploading + sources from whom you're downloading + transient connections as you check in with sources and clients check in with you.

That's more or less what I guessed, I only failed to think that keepalives would be done using UDP instead of creating TCP connections. Thanks.

But then... I do not understand those rule-of-thumbs from the eMule's fora recommending 500 or 1000 max-connections.  ?( How many downloads are they expecting to have?
Logged