locked
The underlying connection was closed: The connection was closed unexpectedly RRS feed

  • Question

  • Hi, 

    I have seen threads related to this error but didn't get enough information or may be I misunderstood their comments.  This is what I am trying to do.

    I am trying to run a load test to test load balancer, check if the traffic is being directed properly to different servers.  

    Suppose I have two servers running when starting a load test.  It runs fine for a while.  Now I turn of one server to test if the traffic is loaded to the one thats running.  Here I see the above mentioned connection errors/exceptions.  this happens whenever I switch off/Quiesce one of the servers.

    What is the cause for this? How do I overcome these errors graciously?  I dont get these errors when I run my load test on a single server/ without Quiesceing any of the servers.  

    Thank you.


    Thanks, Siva
    Monday, November 15, 2010 7:51 AM

Answers

  • Hi Siva,

    How is your load balancer set up? If it's using sticky round robin, generally for a given session all the requests within that session get routed to the same server. So depending on your load balancer setup, you may see these exceptions as you turn off one of the servers until the users that are running complete their tests.

    Secondly, do you have any proxies between your load generators and the load balancer? If so, proxies tend to refuse connections if they perceive your load test as a Denial of Service attack.

    Thirdly, if you have virus/firewall software on your load generator machine, these socket exception could be coming because your virus software blocks your traffic. Try changing the rules to allow QTAgent.exe and QTAgent32.exe as the case may be.

    Hope this helps.

    Neelesh

    • Proposed as answer by Edwer FangModerator Wednesday, November 17, 2010 5:20 AM
    • Marked as answer by Siva.h Wednesday, November 17, 2010 5:12 PM
    Tuesday, November 16, 2010 9:25 AM
    Moderator

All replies

  • Hi Siva,

    How is your load balancer set up? If it's using sticky round robin, generally for a given session all the requests within that session get routed to the same server. So depending on your load balancer setup, you may see these exceptions as you turn off one of the servers until the users that are running complete their tests.

    Secondly, do you have any proxies between your load generators and the load balancer? If so, proxies tend to refuse connections if they perceive your load test as a Denial of Service attack.

    Thirdly, if you have virus/firewall software on your load generator machine, these socket exception could be coming because your virus software blocks your traffic. Try changing the rules to allow QTAgent.exe and QTAgent32.exe as the case may be.

    Hope this helps.

    Neelesh

    • Proposed as answer by Edwer FangModerator Wednesday, November 17, 2010 5:20 AM
    • Marked as answer by Siva.h Wednesday, November 17, 2010 5:12 PM
    Tuesday, November 16, 2010 9:25 AM
    Moderator
  • Hello,

    You should follow Neelesh's suggestions, if you switch the server, there will be some errors for current requests, because when you switch, the session information and other information stored in the applicaiton domain has been removed so the other server can not find them which lead to errors.

    Thanks.


    Please remember to mark the replies as answers if they help and unmark them if they provide no help
    Wednesday, November 17, 2010 5:22 AM
    Moderator
  • Thanks a lot Neelesh.  I will see how they are set up and try to configure per your instructions.  Thanks again.
    Thanks, Siva
    Wednesday, November 17, 2010 4:13 PM
  • One question though, you said that all the requests with in a session get routed to the same server.  In my load test, only one request per webtest fails, and then it picks up from the next request.  i.e. it fails on a request as soon as I Quiesce a server and then it succesfully completes the rest of the requests.  Does that mean the requests from a single webtest will have different sessions? If you can elaborate a little more on "requests within a session" will be helpful.  Thank you.

    --

    Siva.


    Thanks, Siva
    Wednesday, November 17, 2010 5:22 PM