I'm doing application testing on Windows Server 2012 to check compatibility of our web apps (in .Net 4) and am having issues loading any ASPX page. I have tried uninstalling and reinstalling all of the .Net, IIS and ASP.Net roles from Server Manager numerous times. I also found that aspnet_regiis no longer works in Server 2012, it just gives a message to use the role/feature pages instead. I'm at a loss, has anyone else tried IIS 8 yet?
I get the following message:
HTTP Error 404.3 - Not Found
The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map.
Most likely causes:
•It is possible that a handler mapping is missing. By default, the static file handler processes all content.
•The feature you are trying to use may not be installed.
•The appropriate MIME map is not enabled for the Web site or application. (Warning: Do not create a MIME map for content that users should not download, such as .ASPX pages or .config files.)
•If ASP.NET is not installed.
Things you can try:
•In system.webServer/handlers: ◦Ensure that the expected handler for the current page is mapped.
◦Pay extra attention to preconditions (for example, runtimeVersion, pipelineMode, bitness) and compare them to the settings for your application pool.
◦Pay extra attention to typographical errors in the expected handler line.
•Please verify that the feature you are trying to use is installed.
• Verify that the MIME map is enabled or add the MIME map for the Web site using the command-line tool appcmd.exe.
1.To set a MIME type, use the following syntax: %SystemRoot%\windows\system32\inetsrv\appcmd set config /section:staticContent /+[fileExtension='string',mimeType='string']
2.The variable fileExtension string is the file name extension and the variable mimeType string is the file type description.
3.For example, to add a MIME map for a file which has the extension ".xyz": appcmd set config /section:staticContent /+[fileExtension='.xyz',mimeType='text/plain']
Warning: Ensure that this MIME mapping is needed for your Web server before adding it to the list. Configuration files such as .CONFIG or dynamic scripting pages such as .ASP or .ASPX, should not be downloaded directly and should always be processed through a handler. Other files such as database files or those used to store configuration, like .XML or .MDF, are sometimes used to store configuration information. Determine if clients can download these file types before enabling them.
•Install ASP.NET.
•Create a tracing rule to track failed requests for this HTTP status code. For more information about creating a tracing rule for failed requests, click here.
Detailed Error Information:
Module
StaticFileModule
Notification
ExecuteRequestHandler
Handler
StaticFile
Error Code
0x80070032
Requested URL
http://localhost:80/login.aspx
Physical Path
C:\Inetpub\WEBSITE\login.aspx
Logon Method
Anonymous
Logon User
Anonymous
Well, after fighting this issue for the last few days I reset the VM to the base snapshot that I took immediately after finishing the OS install. I followed the exact same steps that I documented during my first runthrough to install the IIS and App Development features then installed my apps and now it works. I have no idea why or how it worked this time where it didn't before, but at least it is working now.
Related
i have window 8 server installed and on deploying my asp.net application iam getting this error
HTTP Error 404.3 - Not Found
The page you are requesting cannot be served because of the extension configuration. If the page is a script, add a handler. If the file should be downloaded, add a MIME map.
Most likely causes:
•It is possible that a handler mapping is missing. By default, the static file handler processes all content.
•The feature you are trying to use may not be installed.
•The appropriate MIME map is not enabled for the Web site or application. (Warning: Do not create a MIME map for content that users should not download, such as .ASPX pages or .config files.)
•If ASP.NET is not installed.
It could be because you have not installed aspnet_regiis.exe
This will register your .NET framework for you and should solve the problem.
IIS 7.5 is looking for my web.config file in a mapped route and not in the actual folder location.
Example
C:\inetpub\wwwroot\api\thedoors\1 <-- is where it's looking this is not a directory but a specified url in WebApiConfig class
Where it should look is
c:\inetpub]wwwroot\thedoors\
I'm using publish from VS 2012 to publish locally to my IIS 7.5 web server.
Server Error in Application "THEDOORS"
Internet Information Services 7.5
Error Summary
HTTP Error 404.0 - Not Found
The resource you are looking for has been removed, had its name changed, or is temporarily unavailable.
Detailed Error Information
ModuleIIS Web Core
NotificationMapRequestHandler
HandlerStaticFile
Error Code0x80070002
Requested URLhttp://localhost:80/api/thedoors/1
Physical PathC:\inetpub\wwwroot\TheDoors\api\thedoors\1
Logon MethodAnonymous
Logon UserAnonymous
Most likely causes:
The directory or file specified does not exist on the Web server. The URL contains a typographical error. A custom filter or module, such as URLScan, restricts access to the file.
Things you can try:
Create the content on the Web server. Review the browser URL. Create a tracing rule to track failed requests for this HTTP status code and see which module is calling SetStatus. For more information about creating a tracing rule for failed requests, click here.
Links and More Information
This error means that the file or directory does not exist on the server. Create the file or directory and try the request again.
View more information »
Benny, this is not the problem with the virtual location of your web.config file. It is telling you that something about your web.config file is not correct. It seems that it cannot find physical web.config in the location C:\inetpub\wwwroot\api\thedoors\web.config where your Web API is executing. Do you have the file in the specified location?
UPDATE: I would open IIS Managment Console and check folder mappings.
I just created a sample Web API project and published it to a local IIS, but I cannot reproduce the issue. My folder mappings seem to be OK. The folder is C:\inetpub\wwwroot\sampleapi and web.config is there.
When getting a newly configured Windows 7 box, I noticed that ASP.NET was turned off by default. So was classical ASP. I was getting a 404.17 error for a web application. I think it's because I don't have an "aspx" MIME type. Although that's just a guess. When I turned them on under Control Panel > Programs and Features > Turn Windows Features on or off, and restarted my Windows 7 machine, the MIME types never showed up. Can someone check what MIME type they have for *.aspx pages, and tell me the configuration in edit mode? What other MIME types would I be missing for ASP.NET extensions (ie: ashx, asax, etc...)? What is the best way to configure them all?
Error Summary
HTTP Error 404.17 - Not Found
The requested content appears to be script and will not be served by the static file handler.
...
Module: StaticFileModule
Notification: ExecuteRequestHandler
Handler: StaticFile
Error Code: 0x80070032
Requested URL: ...
Physical Path: ...
Logon Method: NTLM
Logon User: {DOMAIN}\{WINDOWS LOGIN}
...
Most likely causes:
The request matched a wildcard mime map. The request is mapped to the static file handler. If there were different pre-conditions, the request will map to a different handler.
...
Things you can try:
If you want to serve this content as a static file, add an explicit MIME map.
Fix:
I chose the "ISAPI & CGI Restrictions" after clicking the server
name (not the site name) in IIS Manager, and right clicked the
"ASP.NET v4.0.30319" lines and chose "Allow".
After turning on ASP.NET from "Programs and Features > Turn Windows features on or off", you must install ASP.NET from the Windows command prompt. The MIME types don't ever show up, but after doing this command, I noticed these extensions showed up under the IIS web site "Handler Mappings" section of IIS Manager.
C:\>cd C:\Windows\Microsoft.NET\Framework64\v4.0.30319
C:\Windows\Microsoft.NET\Framework64\v4.0.30319>dir aspnet_reg*
Volume in drive C is Windows
Volume Serial Number is 8EE6-5DD0
Directory of C:\Windows\Microsoft.NET\Framework64\v4.0.30319
03/18/2010 08:23 PM 19,296 aspnet_regbrowsers.exe
03/18/2010 08:23 PM 36,696 aspnet_regiis.exe
03/18/2010 08:23 PM 102,232 aspnet_regsql.exe
3 File(s) 158,224 bytes
0 Dir(s) 34,836,508,672 bytes free
C:\Windows\Microsoft.NET\Framework64\v4.0.30319>aspnet_regiis.exe -i
Start installing ASP.NET (4.0.30319).
.....
Finished installing ASP.NET (4.0.30319).
C:\Windows\Microsoft.NET\Framework64\v4.0.30319>
However, I still got this error. But if you do what I mentioned for the "Fix", this will go away.
HTTP Error 404.2 - Not Found
The page you are requesting cannot be served because of the ISAPI and CGI Restriction list settings on the Web server.
There are two reasons you might get this message:
ASP.Net is not configured. For this run from Administrator command %FrameworkDir%\%FrameworkVersion%\aspnet_regiis -i. Read the message carefully. On Windows8/IIS8 it may say that this is no longer supported and you may have to use Turn Windows Features On/Off dialog in Install/Uninstall a Program in Control Panel.
Another reason this may happen is because your App Pool is not configured correctly. For example, you created website for WordPress and you also want to throw in few aspx files in there, WordPress creates app pool that says don't run CLR stuff. To fix this just open up App Pool and enable CLR.
I'm working on a web application that is referenced from another, external application. The external application tries to do a POST on the vdir when opening. At this point, I get an HTTP 405 Error:
HTTP Error 405 - The HTTP verb used to access this page is not allowed.
Internet Information Services (IIS)
I checked the IIS event logs and I see that the external application tries to post, but I can't change permissions for a directory, since I need an extension.
Any ideas?
Make sure you are including the web page file name in the post URL (http://yoursite/app/Page.aspx instead of http://yoursite/app)
You may need to explicitly allow POSTs to the file type of your web page. See here for instructions of how to do it in IIS. (Those instructions are for IIS 6. For IIS 7 simply go to Handler Mappings, click Edit for the appropriate entry, click the Request Restrictions button, then go to the Verbs tab.)
Do you have a default document in the virtual directory that you are posting to? IIS will not allow POST commands to a folder, but it should still map the virtual directory to the default document. Also try removing the trailing slash.
http://forums.iis.net/t/1171316.aspx
I'm trying to upload a vcard file to a site i've built with ASP.NET. It's hosted on an IIS7 server.
I keep running into the "content type not allowed" error when i try to upload the file. I have write permission to the directory, I've already added the MIME type for vcards and restarted the IIS server, however it still refuses to take it.
I'm using DevExpress UploadControl and i've removed any validation from it so i am fairly certain the control is not restricting the file upload.
Any other suggestions ?
Maybe your component just allow some content types by default and new ones must be granted access manually.
Can you to debug your server side code, to see if your page code executes and to spot exactly what component are throwing up that error?
It's an HTTP error or a .net exception?