How to increase maximum connections?

Discussion in 'Sveasoft Firmware' started by peich9, Aug 2, 2004.

  1. peich9

    peich9 Network Guru Member

    Hi, I've started to use Bittorrent lately and I'm facing a new problem: the maximum simultaneous connections. The WRT54G seems to stop to make new connections when there are ~200 connections open. Yes, they are plenty, but I would to increase them to 300 at least. I haven't found any post anywhere about this problem. So I was thinking about some Linux command or some kind of configuration to modify (like Windows registry keys) but I have no clue about Linux. Any help, please?
  2. pkitester

    pkitester Network Guru Member

    Sveasoft should open the forums back up...

    That is one of the nuggets of information that is now "lost" to us poor folk since sveasoft has restricted access...

    You should be able to get more than 200 connections, I thought the default was 512. But to get it to 4096 telnet into the box and issue:

    echo 4096 > /proc/sys/net/ipv4/ip_conntrack_max
  3. sune

    sune Network Guru Member

    You should also consider lowering the default TTL for established TCP connections which is 5 days as default.
    My experience is that you will get many orphaned entries in ip_conntrack this way, because often p2p connections are not terminated properly.

    Try lowering this to eg. one hour:

    sysctl -w net.ipv4.ip_conntrack_tcp_timeouts="1800 3600 120 60 120 120 10 60 30 120"

    (the second value is the changed one)...

  4. grem

    grem Network Guru Member

    How do I make these config changes with the standard Linksys 2.04.4 firmware? I don't believe I can telnet into the box.
  5. commanderx

    commanderx Network Guru Member

    This doesnt work wirh the original Linksys Firmware.
  6. StarKruzr

    StarKruzr Network Guru Member

    sysctl -w net.ipv4.ip_conntrack_tcp_timeouts="1800 3600 120 60 120 120 10 60 30 120"
    Would this work in HyperWRT's Startup box along with the setting for max # of connections?
  7. Wareagle

    Wareagle Network Guru Member


    Will these settings stick if I reboot the router, or do I need to issue these commands every time it is rebooted or unplugged?
  8. StarKruzr

    StarKruzr Network Guru Member

    Re: Persistent?

    I did both of these command sets and haven't had a problem since. YMMV, of course.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice