iis-7.5

ASP.NET Web API returns 404 for PUT only on some servers

末鹿安然 提交于 2019-11-26 18:53:40
I have written a site that uses ASP.NET MVC Web API and everything is working nicely until I put it on the staging server. The site works fine on my local machine and on the dev web server. Both dev and staging servers are Windows Server 2008 R2. The problem is this: basically the site works, but there are some API calls that use the HTTP PUT method. These fail on staging returning a 404, but work fine elsewhere. The first problem that I came across and fixed was in Request Filtering. But still getting the 404. I have turned on tracing in IIS and get the following problem. 168. -MODULE_SET

GZip Compression On IIS 7.5 is not working

你说的曾经没有我的故事 提交于 2019-11-26 18:30:30
I am trying to support GZip compression for my static files under IIS (which should be enabled by default but not) but not working so far. Here is the the section under <system.webServer> node inside the web.config file of the web app; <httpCompression directory="%SystemDrive%\inetpub\temp\IIS Temporary Compressed Files"> <scheme name="gzip" dll="%Windir%\system32\inetsrv\gzip.dll" staticCompressionLevel="9" /> <dynamicTypes> <add mimeType="text/*" enabled="true" /> <add mimeType="message/*" enabled="true" /> <add mimeType="application/x-javascript" enabled="true" /> <add mimeType="application

ASP.NET 4.5 has not been registered on the Web server

戏子无情 提交于 2019-11-26 18:19:09
In my Win 7 development machine, and in order to use SQL Express instance instead of the localDB installed by default. I unchecked "Use IIS Express" in my MVC 4 project properties page (Web tab), then I got the following error: ASP.NET 4.5 has not been registered on the Web server. You need to manually configure your Web server for ASP.NET 4.5 in order for your site to run correctly. I verified that ASP.NET is activated within the IIS features. Please what could be done to resolve this? Maybe you have to execute the following in the Visual Studio Tools command prompt: aspnet_regiis -i You can

IIS 7.5 application pool uses wrong %APPDATA% for custom user as identity

你离开我真会死。 提交于 2019-11-26 17:48:12
问题 I want my MVC3 web application to access %APPDATA% (e.g. C:\Users\MyUsername\AppData\Roaming on Windows 7) because I store configuration files there. Therefore I created an application pool in IIS with the identity of the user "MyUsername", created that user's profile by logging in with the account, and turned on the option "Load User Profile" (was true by default anyway). Impersonation is turned off. Now I have the problem that %APPDATA% (in C#): appdataDir = Environment.GetFolderPath

IIS 7.5 Fixing An attempt was made to load a program with an incorrect format problem?

痴心易碎 提交于 2019-11-26 17:45:55
问题 I have a unusual problem throwing an exception "An attempt was made to load a program with an incorrect format" error? I have two identical websites on the same IIS server and my build configuration works for one of them but not the other. My C# MVC 2 web app can deployed to two websites that reside on the same IIS 7.5 webserver (x64). One is the live site (deployed using Release configuration), the second is the beta site (deployed using a new Beta configuration created just for this project

How do I give ASP.NET permission to write to a folder in Windows 7?

倖福魔咒の 提交于 2019-11-26 17:14:46
I have a new Win7 workstation and I am trying to get ScrewTurn Wiki to run on the machine. My STW installation is using the file system option to store its data, and as such I need to give write permissions to the ASP.NET worker process in the folder the website is installed in. HOWEVER, I cannot seem to be able to come up with name of the worker process in Win7 in order to add it to the permissions for the folder. In XP it was ASPNET_WP, if I remember correctly, but that is not its name in Win7. Can someone please tell me? Edited to add: In response to @Dragan_Radivojevic, here's what the

HTTP 404 Page Not Found in Web Api hosted in IIS 7.5

时光总嘲笑我的痴心妄想 提交于 2019-11-26 17:12:43
I have a Web Api application. It works perfectly well when I tested it using the VS 2010 debugging dev server. But I now deployed it to IIS 7.5 and I am getting a HTTP 404 error when trying to access the application. Here is my web.config <?xml version="1.0" encoding="utf-8"?> <configuration> <connectionStrings> <add name="DefaultConnection" connectionString="Data Source=.\SQLEXPRESS;Initial Catalog=aspnet-FlowGearProxy-20123141219;Integrated Security=True" providerName="System.Data.SqlClient" /> </connectionStrings> <appSettings> <add key="webpages:Version" value="2.0.0.0" /> <add key=

rewrite url to url:port number

烈酒焚心 提交于 2019-11-26 16:58:07
问题 how can I rewrite the next url request: http://mydomain.com/virtualDirectory/default.aspx?param1=2&param2=car to: http://mydomain.com:8888/virtualDirectory/default.aspx?param1=2&param2=car Best regards. 回答1: You should install the URL Rewrite and the ARR (Application Request Routing) modules for IIS. Here are two links on how these can work together to create a reverse proxy to do what you want: Reverse Proxy with URL Rewrite v2 and Application Request Routing Setting up a Reverse Proxy using

Stop IIS 7.5 Application Pool Recycling

痞子三分冷 提交于 2019-11-26 16:55:40
问题 How do stop application pools from recycling in IIS 7.5? I have configured the following settings: ProcessModel -> Idle Time-out (minutes) = 0 Recycling -> Regular Time Intervals (minutes) = 0 Are these settings enought to stop an application pool from recycling? 回答1: Yes, that should be ok assuming you also use Private Memory Limit = 0. There are still reasons an AppPool could recycle, such as when adding a new Global Module, it will require to be recycled so configuration changes take

Unable to authenticate to ASP.NET Web Api service with HttpClient

為{幸葍}努か 提交于 2019-11-26 16:01:55
I have an ASP.NET Web API service that runs on a web server with Windows Authentication enabled. I have a client site built on MVC4 that runs in a different site on the same web server that uses the HttpClient to pull data from the service. This client site runs with identity impersonation enabled and also uses windows authentication. The web server is Windows Server 2008 R2 with IIS 7.5. The challenge I am having is getting the HttpClient to pass the current windows user as part of its authentication process. I have configured the HttpClient in this manner: var clientHandler = new