Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. TCP Stack overflow [modified]

TCP Stack overflow [modified]

Scheduled Pinned Locked Moved C / C++ / MFC
c++helpsysadmindata-structurestutorial
6 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    micutzu
    wrote on last edited by
    #1

    Hello, I have a tricky problem and I hope someone might give me a hint or a suggestion. The problem is caused by an application that acts as a proxy server with filtering capabilities which is installed on a machine and receives the HTTP traffic from the LAN to the Internet and filters the HTTP traffic from the Internet to the LAN. For small LANS (5 – 10 PC’s is working fine) but for larger networks an error is frequently raised: WSAECONNRESSET – connection reset by peer. As far as I know this problem is caused by the use of blocking sockets (which is not the case) or by a TCP Stack overflow. Can anyone point a good article about how to avoid a TCP Stack overflow or knows a good tool that allows me to monitor the TCP Stack? The application is developed in Visual C++ 6.0. Thank you, Best Regards, Dan. -- modified at 9:25 Wednesday 20th December, 2006

    J M 3 Replies Last reply
    0
    • M micutzu

      Hello, I have a tricky problem and I hope someone might give me a hint or a suggestion. The problem is caused by an application that acts as a proxy server with filtering capabilities which is installed on a machine and receives the HTTP traffic from the LAN to the Internet and filters the HTTP traffic from the Internet to the LAN. For small LANS (5 – 10 PC’s is working fine) but for larger networks an error is frequently raised: WSAECONNRESSET – connection reset by peer. As far as I know this problem is caused by the use of blocking sockets (which is not the case) or by a TCP Stack overflow. Can anyone point a good article about how to avoid a TCP Stack overflow or knows a good tool that allows me to monitor the TCP Stack? The application is developed in Visual C++ 6.0. Thank you, Best Regards, Dan. -- modified at 9:25 Wednesday 20th December, 2006

      J Offline
      J Offline
      James R Twine
      wrote on last edited by
      #2

      I do not know the answer to your problem and I do not pretend understand the internals of a particular TCP/IP implementation, but if on Win32, you solution may be just a registry tweak away.    Do you have any loggings/stats from the application or Performance Counters that shows a "trigger" point where you start to have problems?  Knowing if/what that value is (memory, handles, etc.) would be a good place to start in looking for solutions IMHO.    That error, if being received by your application, is usualy the result of the other side dropping the connection.  Are you sure there is no other hardware between your application and the Internet that may be getting overloaded or is faulty?  Or is that error being raised in other applications (like IE) that are going through your app?    Peace!

      -=- James


      If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
      Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
      DeleteFXPFiles & CheckFavorites (Please rate this post!)

      M 1 Reply Last reply
      0
      • M micutzu

        Hello, I have a tricky problem and I hope someone might give me a hint or a suggestion. The problem is caused by an application that acts as a proxy server with filtering capabilities which is installed on a machine and receives the HTTP traffic from the LAN to the Internet and filters the HTTP traffic from the Internet to the LAN. For small LANS (5 – 10 PC’s is working fine) but for larger networks an error is frequently raised: WSAECONNRESSET – connection reset by peer. As far as I know this problem is caused by the use of blocking sockets (which is not the case) or by a TCP Stack overflow. Can anyone point a good article about how to avoid a TCP Stack overflow or knows a good tool that allows me to monitor the TCP Stack? The application is developed in Visual C++ 6.0. Thank you, Best Regards, Dan. -- modified at 9:25 Wednesday 20th December, 2006

        J Offline
        J Offline
        James R Twine
        wrote on last edited by
        #3

        I got curious and bumped into this:    http://laurentszyster.be/blog/tcp-stack-flaking-out/[^]    Peace!

        -=- James


        If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
        Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
        DeleteFXPFiles & CheckFavorites (Please rate this post!)

        M 1 Reply Last reply
        0
        • J James R Twine

          I do not know the answer to your problem and I do not pretend understand the internals of a particular TCP/IP implementation, but if on Win32, you solution may be just a registry tweak away.    Do you have any loggings/stats from the application or Performance Counters that shows a "trigger" point where you start to have problems?  Knowing if/what that value is (memory, handles, etc.) would be a good place to start in looking for solutions IMHO.    That error, if being received by your application, is usualy the result of the other side dropping the connection.  Are you sure there is no other hardware between your application and the Internet that may be getting overloaded or is faulty?  Or is that error being raised in other applications (like IE) that are going through your app?    Peace!

          -=- James


          If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
          Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
          DeleteFXPFiles & CheckFavorites (Please rate this post!)

          M Offline
          M Offline
          micutzu
          wrote on last edited by
          #4

          Hello James, Thank you for the reply. The probability that the error is raised by a different network device is almost 0 because it was tested on different platforms and different LAN and the error keep appearing. I am convinced that somehow (I do not know exactly how) the application does not correctly close the connections and this error keep raising. Regards, Dan.

          1 Reply Last reply
          0
          • J James R Twine

            I got curious and bumped into this:    http://laurentszyster.be/blog/tcp-stack-flaking-out/[^]    Peace!

            -=- James


            If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
            Avoid driving a vehicle taller than you and remember that Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
            DeleteFXPFiles & CheckFavorites (Please rate this post!)

            M Offline
            M Offline
            micutzu
            wrote on last edited by
            #5

            Thanks, I will read it right now. Regards, Dan.

            1 Reply Last reply
            0
            • M micutzu

              Hello, I have a tricky problem and I hope someone might give me a hint or a suggestion. The problem is caused by an application that acts as a proxy server with filtering capabilities which is installed on a machine and receives the HTTP traffic from the LAN to the Internet and filters the HTTP traffic from the Internet to the LAN. For small LANS (5 – 10 PC’s is working fine) but for larger networks an error is frequently raised: WSAECONNRESSET – connection reset by peer. As far as I know this problem is caused by the use of blocking sockets (which is not the case) or by a TCP Stack overflow. Can anyone point a good article about how to avoid a TCP Stack overflow or knows a good tool that allows me to monitor the TCP Stack? The application is developed in Visual C++ 6.0. Thank you, Best Regards, Dan. -- modified at 9:25 Wednesday 20th December, 2006

              M Offline
              M Offline
              Mark Salsbery
              wrote on last edited by
              #6

              This may be totally unrelated, but if you are using listen(), what happens if you use a larger backlog value? SOMAXCONN is typically 5 which may cause alot of refused connections if they come in fast enough.

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups