Couldn't start profiling session: timed out waiting for port
marcf
Posts: 1 New member
Attempting to use ANTS Performance Profiler for the first time on a production server to profile an ASP.NET web application.
It fails with the following when I ask it to use the existing port:
Couldn't start the profiling session
Cause: Timed out waiting for port 8002 on 127.0.0.1 to become available
I get the same error when I ask it to use an unused port:
Couldn't start the profiling session
Cause: Timed out waiting for port 8015 on 127.0.0.1 to become available
Note the application normally takes 15 seconds to load the very first page due to warm-up.
The last lines from the log file as as follows:
I can see a new w3wp.exe process is spawned and it sits at a constant 5,676 K memory according to Task Manager.
It fails with the following when I ask it to use the existing port:
Couldn't start the profiling session
Cause: Timed out waiting for port 8002 on 127.0.0.1 to become available
I get the same error when I ask it to use an unused port:
Couldn't start the profiling session
Cause: Timed out waiting for port 8015 on 127.0.0.1 to become available
Note the application normally takes 15 seconds to load the very first page due to warm-up.
The last lines from the log file as as follows:
14 Feb 2019 12:58:21.054 [13] INFO RedGate.Profiler.Engine.Startup.Basic.Attacher - Found runtime version v4.0.30319 14 Feb 2019 12:58:28.102 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.IisRunner - Initializing ASP.NET session, running on IIS 14 Feb 2019 12:58:28.102 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.IisRunner - Initializing IIS 7/7.5 session 14 Feb 2019 12:58:28.102 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.IisRunner - IIS: Profiling on unused port 14 Feb 2019 12:58:28.102 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.IisRunner - IIS: Profiling application at http://127.0.0.1:8002/ 14 Feb 2019 12:58:28.102 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.IisRunner - IIS: Port is 8015 14 Feb 2019 12:58:28.102 [18] WARN RedGate.Profiler.Engine.Startup.IIS.IISUtilities - About to get site for URL 14 Feb 2019 12:58:30.024 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.BaseSessionRunner - Line-level blacklist alwaysApply="true"; applying blacklist 14 Feb 2019 12:58:30.040 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.BaseSessionRunner - Newtonsoft.Json is in the line-level blacklist file; excluding from line-level timing 14 Feb 2019 12:58:30.040 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.BaseSessionRunner - log4net is in the line-level blacklist file; excluding from line-level timing 14 Feb 2019 12:58:30.040 [18] INFO RedGate.Profiler.Logic.Controllers.Session.Type.BaseSessionRunner - Castle.Core is in the line-level blacklist file; excluding from line-level timing 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Logic.Controllers.Session.Type.BaseRunner - Launching session 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Logic.Controllers.Session.Type.BaseRunner - Launch: Will request elevation 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Logic.Controllers.Session.Type.BaseRunner - Options: IL timings turned on 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Engine.Startup.Sessions.BaseSession - ANTS is running under a 64-bit version of Windows. 32-bit binaries were found in C:\WINDOWS\SysWOW64. 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Engine.Startup.Sessions.BaseSession - InetSrv directory is C:\WINDOWS\system32\inetsrv 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Engine.Startup.Sessions.BaseSession - InetSrv WOW64 directory is C:\WINDOWS\SysWOW64\inetsrv 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Engine.Startup.Sessions.BaseSession - Trying to start the IIS profiler service 14 Feb 2019 12:58:30.040 [22] INFO RedGate.Profiler.Engine.Startup.Sessions.BaseSession - The IIS service appears to be registered; requesting that it start now
I can see a new w3wp.exe process is spawned and it sits at a constant 5,676 K memory according to Task Manager.
Tagged:
Answers
If you try to attach to the running process using the "Attach to .NET 4+ process" does that work successfully?
Also, the obvious question of, is there actually something using the ports in question? In the case of the original port it would be whether the ANTS Performance Profiler 10 service could restart the IIS page to launch it on the original port; for the unused port it could be something using it that you were not aware of.
A few other things to check:
Kind regards,
Alex
Have you visited our Help Center?
So the resolution for us was to convert from shared config and app on network shares to non-shared all local on the web server.