iis-6

Pre-compress static files in IIS 6

我们两清 提交于 2020-01-13 06:22:46
问题 I am implementing Gzip compression for CSS and JS files on my site and just need to double check something. Is the file compressed on every request? or is it collected and sent from the Temporary folder (if the file exists)? I just want to be sure that my files are not compressed on every request. Also, is this a default behaviour or do I need some extra configurtion? And last, do I need to worry or configure something when using hash tags in the path (to inform the browser that the file has

Windows Authentication and Forms Authentication together for ASP.NET

只愿长相守 提交于 2020-01-12 09:52:06
问题 I am developing an internally-facing application that needs to automatically authenticate users via Windows Authentication and fall back to Forms authentication. The fall back would occur in situations where the user on a computer logged in as a group account (such as an operations center). I'm concerned about security where a user could "spoof" the Windows Authentication account. Do any of you all know of a design pattern and pragmatic idea that would fit this specific scenario? Technical

WCF and Multiple Host Headers

半腔热情 提交于 2020-01-12 03:28:11
问题 My employers website has multiple hostnames that all hit the same server and we just show different skins for branding purposes. Unfortunately WCF doesn't seem to work well in this situation. I've tried overriding the default host with a custom host factory. That's not an acceptable solution because it needs to work from all hosts, not just 1. I've also looked at this blog post but either I couldn't get it to work or it wasn't meant to solve my problem. The error I'm getting is "This

Creating an IIS 6.0 Application Pool using Powershell

微笑、不失礼 提交于 2020-01-12 02:03:52
问题 How do I create an Application Pool on IIS 6.0 using a PowerShell script? This is what I have come up with so far ... $appPool = [wmiclass] "root\MicrosoftIISv2:IIsApplicationPool" Thanks 回答1: It isn't the most obvious process, but here is what worked for me.. $AppPoolSettings = [wmiclass]'root\MicrosoftIISv2:IISApplicationPoolSetting' $NewPool = $AppPoolSettings.CreateInstance() $NewPool.Name = 'W3SVC/AppPools/MyAppPool' $Result = $NewPool.Put() You might get an error with the call to Put(),

Creating an IIS 6.0 Application Pool using Powershell

只愿长相守 提交于 2020-01-12 02:03:09
问题 How do I create an Application Pool on IIS 6.0 using a PowerShell script? This is what I have come up with so far ... $appPool = [wmiclass] "root\MicrosoftIISv2:IIsApplicationPool" Thanks 回答1: It isn't the most obvious process, but here is what worked for me.. $AppPoolSettings = [wmiclass]'root\MicrosoftIISv2:IISApplicationPoolSetting' $NewPool = $AppPoolSettings.CreateInstance() $NewPool.Name = 'W3SVC/AppPools/MyAppPool' $Result = $NewPool.Put() You might get an error with the call to Put(),

ASP.NET IIS - when are requests queued?

随声附和 提交于 2020-01-10 06:55:08
问题 The following article by Thomas Marquardt describes how IIS handles ASP.Net requests, the max/min CLR worker threads/Managed IO threads that can be configured to run, the various requests queues involved and their default sizes. Now as per the article, the following occurs in IIS 6.0: ASP.NET picks up the requests from a IIS IO Thread and posts "HSE_STATUS_PENDING" to IIS IO Thread The requests is handed over to a CLR Worker thread If the requests are of high latency and all the threads are

How can I change the username/password of an ApplicationPool in IIS from C#?

扶醉桌前 提交于 2020-01-10 04:34:24
问题 I am using the code below to create a new application pool in the Installer class of my application: private static void CreateAppPool(string serverName, string appPoolName) { // metabasePath is of the form "IIS://<servername>/W3SVC/AppPools" // for example "IIS://localhost/W3SVC/AppPools" // appPoolName is of the form "<name>", for example, "MyAppPool" string metabasePath = string.Format("IIS://{0}/W3SVC/AppPools", serverName); Console.WriteLine("\nCreating application pool named {0}/{1}:",

Periodic InvalidCastException and “The server failed to resume the transaction” with Linq

本秂侑毒 提交于 2020-01-10 03:48:05
问题 I see this on our stage system, after it has been up for 2-3 days. "The server failed to resume the transaction. Desc:39000000ef." (with desc:xxx increasing every time). The stack trace shows System.Data.SqlClient.SqlException: The server failed to resume the transaction. Desc:39000000ef. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) at

ASP.NET MVC 404 handling and IIS7 <httpErrors>

本秂侑毒 提交于 2020-01-09 10:06:14
问题 Good day! I use strategy to handle 404 errors like this: Error handling for ASP.NET MVC 2 and IIS 7.0 or this: How can I properly handle 404 in ASP.NET MVC? In short: I handle 404 as exception in Global.asax without adding any routing rules, if the exception is 404 I render special controller\action with error message. On IIS6 it works with ASP.NET wildcard mapping. On IIS7 in integrated mode I need to add the following to the Web.config (where /error/HttpError404 is my action with 404 page):

ASP.net MVC HttpException strange file not found

冷暖自知 提交于 2020-01-07 01:20:43
问题 I'm running asp.net MVC site on IIS6 - I've edited my routing to look like the following: routes.MapRoute( "Default", "{controller}.aspx/{action}/{id}", new { controller = "Home", action = "Index", id = "" } ); routes.MapRoute( "Root", "", new { controller = "Home", action = "Index", id = "" } ); So all my urls now contain .aspx (as per one of the solutions from Phil Haack). Now, I catch all unhandled exceptions using Elmah, and for almost every page request, I get the following error caught