none
The requested address is not valid in its context error

    Question

  • Hello,

    I'm using IP switching when running load test (single web test that runs a log in process via SSO).

    My current configuration is a controller and an agent on my local machine and another agent on another machine.

    I'm using only LAN as network mix, no network emulation.

    The error I'm receiving is, when both agents send Get request to the Load Balancer :

    The requested address is not valid in its context 10.8.4.245:80

     And the stack error is:

    at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult)

       at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception

    Saturday, February 09, 2013 8:01 AM

Answers

All replies

  • IPSwitching will only work if you run the tests on controller/agent. IPSwitching does not work if the test is run locally. Can you confirm by looking at the test settings file that the test execution is set up for remote and not local. 

    Here is very useful guidance and quick tricks on how to set up and troubleshoot this, http://vsptqrg.codeplex.com/ 

    An easy way to verify whether IPSpoofing has been set up correctly, is to enable IIS Logging IIS logging on the Web server. You can use the IIS logging functionality to verify that requests are coming from the IP addresses you configured.


    Please remember to mark the replies as answers if they help.

    Tarun Arora

    Blog: http://geekswithblogs.net/TarunArora  Subscribe in a reader


    Facebook: Visual Studio Bytes

    Videos: ALM Videos

    Sunday, February 10, 2013 5:04 PM
  • Hey,

    The guide is for VS 2010 - does the configuration for IPSpoofing is the same in 2012 ?

    The test execution method is indeed remote execution. 

    There are no requests from any IP Address I assigned in the Test Agent Rig in any of the IIS Servers, each request is still encountring the error :

    The requested address is not valid in its context 

    Is there anyway to make sure my setting are okay ? 

    First instance I've configure the the Test Agent Rig with the next settings:

    My IP Address pool is 10.8.37.50 – 100

    Base Address : 10.8.37

    Start Range 50

    End Range 100

    Subnet Mask - 255.255.254.0

    If I run IPConfig or Netstat should I be able to see these IP addresses  assigend as static?

    Regards,

    Oren

    Sunday, February 17, 2013 3:20 PM
  • Hello Oren,

    I think that the IP Switching settings in VS2010 Guide should be applied for VS2012.

    Also you can refer to the following article to know more about IP Switching:

    http://msdn.microsoft.com/en-us/library/dd695837(v=vs.110).aspx

    To use the IP switching feature, the Visual Studio Test Agent service must be running as a user in the Administrators group for that agent computer.

    To verify that IP switching is working correctly, enable IIS logging on the Web server, use the IIS logging functionality to verify that requests are coming from the IP addresses that you configured.

    In addition, based on the following blogs you can enable verbose logging for the Test Agent Service in QTAgentService.exe.config file under %Program Files%\Visual Studio 11.0\Common7\IDE  in VS2012 to troubleshoot your issue:

    Troubleshooting the VSTS Load Testing IP Switching Feature

    How to enable test agent logs

    Best regards,


    Amanda Zhu [MSFT]
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

    Monday, February 18, 2013 9:00 AM