IIS 7 - Windows 7 - WCF Random Timeout - asp.net

I've run out of options at this point guys. So here's the deal, up until today, I had a working setup on my work laptop. I've built a web application using ASP.NET MVC and WCF. My machine is Windows 7, I'm hosting the application on IIS7.
So, like I said, up until today the application worked fine. Last night I installed windows updates. After installing these updates, my WCF services are throwing timeout errors all over the place whenever multiple concurrent requests are made.
Before anyone asks, here are a list of things that I've investigated:
There are no locks in the database. As a matter of fact, at the time of the timeouts, there is no activity whatsoever in SQL server.
The WCF proxies are being closed properly.
I've uninstalled the windows updates in question.
I've uninstalled the .NET Framework, as well as IIS and re-installed.
I've pretty much done everything short of wiping and re-installing Windows 7.
Also worth noting, is that the application works flawlessly in the QA and Production environments, as well as on other development machines.

Related

Mixed ASP.NET and classic ASP project slow performance

I have a legacy Classic ASP web application that performs slowly on my current Windows 10 / SQL Server 2017 Dev machine as well as a Windows server 2016 machine.
In more detail, the ASP parts of the application construct and execute a lot of queries on the SQL server behind it. The queries seem to be taking about 5-10 seconds each to execute and some parts have more than 200 queries resulting in script timeout errors.
The interesting thing is that the same code ran on another Windows 10 Dev machine and performed just fine (the main difference is Windows defender being turned off on that machine), as well as on Windows server 2008.
I've tried disabling real time protection as well as Windows defender altogetger on my Dev machine with no luck.
Any ideas or hint as to what could be causing this?
Turns out the very undocumented (local) value for the database source was what was causing the delays. Changing (local) to the actual machine's name in your Classic ASP project's configuration will fix the issue. This is usually found in a some ASP configuration file within your project (e.g. config.asp).
I will edit this answer with several other topics that I found throughout my research which should apply to anyone having issues with Classic ASP projects.
What's also interesting and hasn't been answered yet is that two machines with (basically) the same stack were having different results.

SignalR web applications multiple Working processes in IIS 7.5 and 8

In my company we have many web applications on a web server. Recently we developed a Chat module to this applications using SignalR. But a strange problem occured on these applications. In time this apps becomes unreachable. Recycleing does not solve. When i try to restart application pools it stops an never starts again. I had create a new app pool and delete the old one. And some time later the problem recurs.
Then i noticed that these application pools have several working processes which have the state of "Closing" and one "Running". What can be the problem? It is about SignalR I know, becouse this problem occurs only the applications which i use SignalR and we have about fifty apps on the server in total and only four of them have signalR on it.
screenshot of stopped process
Please help..
months after i decided to answer my own question. i think it's about windows and iis version. i set up a windows 2012 machine and new version iis on it and on this new server this problem not occured.

Asp.net web application hosted on IIS7 is responding slow

I have 17 simple data entry applications(.net version is 3.5, designed in asp.net, coding language is c# and database is Oracle 10g) hosted under one application pool which is configured on IIS7 as .Net Framework Version = v2.0, Manged pipeline mode = Classic. My server is Windows server 2008 r2 64 bit with 32 GB ram.
Problem is one of my application started responding slowly, it was working fine before but now even pressing the tab key takes 2 to 3 seconds.
To check the problem I debugged the application in visual studio 2008 and it was working fine, then I configured the IIS7 on my PC and hosted the application from it and it was working fine( surprisingly my pc only have 4GB of ram and 32 bit windows 7 as operating system.)
I also tried DebugDiag on server to check the performance of w3wp.exe but couldn't find anything.
I also compared both the hosted applications (one from my local PC and one from server) using Firebug and fond under the .net tab that application hosted from server is taking more time, but I don't know the reason.
I also know for sure that database is not responding slow.
If someone can advice me how to check the problem that would be great,any advice would be appreciated.
Many thanks.

Deployed ASP.NET application reverts to old code base?

We have an ASP.NET application running on a webfarm. When we release a new version and copy it to the production servers, occasionally it happens that after a few hours the application reverts to a an earlier code base.
Have anyone else experienced something like this? Would sharing an application pool between two applications running different versions of the code make this happen?
Additional information:
3 x web servers running w2k3/iis6
ASP.NET 3.5
I've had this happen rarely on non-precompiled sites and the solution was to stop IIS and clear out the temporary cache at:
%WINDIR%\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files
Is not a long-term solution, but will address the immediate problem. If not already, it is worth considering deploying the site pre-compiled.

ASP.NET Development Server or Localhost IIS?

Currently our dev team set up all the websites they're working on in IIS on their local machine. We're thinking of switching to using the built in ASP.NET development server instead.
Is this a good idea? What are the pros / cons of using the ASP.NET dev Server? Are there any gotchas we should be aware of?
Thanks.
NB: Running on Win XP / IIS 5 / VS2005
Edit:
Didn't realise it was called Cassini.. More answers for Cassini v IIS here.
There is nothing that the ASP.NET Dev WebService can do that IIS can't (You can set breakpoints etc, just attach the VS debugger to the ASP.NET runtime).
However, the ASP.NET Dev WebService does not represent a true production environment, and as such you can get caught by gotchas that you wouldn't expect when you deploy to production.
Because of that, I mandate that all development is done using IIS on a local machine. It doesn't take much work to configure a site in IIS.
It's a very good idea. Here are some reasons for:
You no longer need admin access to your machine for web development (it can still be helpful).
It's much easier to test a quick change and continue work, and faster iteration cycles are good.
It can simplify setup and deployment of your development environments.
The XP version of IIS has limitation that are not present in the Server version that Cassini side-steps.
The only argument I know against is that there are a couple very rare edge cases where the Cassini built-in server doesn't exactly mimic IIS because you're using odd port numbers. I doubt you'll ever run into them, and using Cassini as the primary dev environment does not preclude developers from also having access to IIS on the machine. In fact, my preferred setup is Cassini first for most small work, then deploy to my local IIS for more in-depth testing before moving code back to the shared source repository.
[Edit]
Forgot about url re-writing. You do need IIS for that. And an example of a limitation of the built-in XP IIS is that you are limited to one site in XP (can have multiple applications, but that's a different thing).
I had to switch (back) to IIS for one project, because I needed to set some virtual directories which is not possible on the ASP.NET Development Web Server.
As I stated here: https://stackoverflow.com/questions/103785/what-are-the-disadvantages-of-using-cassini-instead-of-iis your developers need to be aware that Cassini runs as the local user, which is typically an admin account for developers. The development will be able to access any file or resource that their account can, which is quite different from what they will see on an IIS 6 server.
The other thing that's a pretty big gotcha is debugging web services is much easier using IIS and vdirs rather than separate Cassini instances.
I know at one point I had an issue with Authentication not working as expected on Cassini (built in development server)
Also, if you need to test things like ISAPI plugins (a re-writer for example) I'm not sure how that's done on Cassini.
The constantly changing port is also rather disconcerting to me. Also, for each web project in your solution it fires up another instance of a Casini server, and each one takes anywhere from 20 to 50 MB of memory.
I use IIS all the time, it's pretty easy to setup, and you guys are already doing that...
I've used both methods and I prefer having IIS locally vs. using the built-in server. At very least you're more consistent with the final deployment setup.
Also, when using IIS 5.1, be sure to get JetStat IIS Admin, it adds functionality that is disabled out of the box on IIS 5, such as being able to setup multiple sites.
I have run into the following limitations with the asp.net dev server:
does not support virtual dirs. If you need them in your app, IIS seems to be your only choice
Classic asp pages dont run in dev server. So if you have a mixed web app (like I have at my client right now), IIS seems to be the solution
If you need an admin UI to configure settings, IIS works better
Of course IIS requires that you be a local admin.
Another distinction I noticed is that Cassini runs as a 32-bit process and you have no control over it, whereas you can control the application pool of your IIS app to disallow 32-bit (assuming your IIS is running on a 64-bit server). This becomes especially important if your web application is going to call APIs in 64-bit processes such as SharePoint Foundation/Server 2010. When you debug your web app with Cassini as your debug server, you'll get "The Web application at url could not be found. Verify that you have typed the URL correctly" type errors when instantiating objects. If you debug using IIS with the app running in an app pool that runs as 64-bit with an identity that allows access to sharepoint database then you'll be able to debug properly.
In VS12 the development server is way slow, takes a few seconds to download a 2kbyte file. This did not happen in vs10. When you have a bunch of jquery files and css this is a real problem. Also every page requeries all the css/js files. Very very slow regression testing.
The main issue I've run into with the dev server is SerializationExceptions with custom security principals stored on the thread context. Details here.

Resources