IISExpress 8 Cannot read configuration file redire

2019-01-06 13:03发布

I'm running Windows Server 2008 R2 (x64) with IISExpress8 and when navigating to

c:\Program Files (x86)\IIS Express>iisexpress.exe

it says:

Filename: redirection.config

Error: Cannot read configuration file

Any ideas where to start? I can't find anything...

标签: iis-express
21条回答
Animai°情兽
2楼-- · 2019-01-06 13:46

After trying to solve an issue with a quick fix of changing IIS express inside visual studio from integrated to classic pipeline , I ended up not being able to use IIS express at all. I tried all techniques above...

I could not rename , copy the file. Uninstall of IIS express and re-install did not work.

I FINALLY downloaded the latest version of WebMatrix and installed IIS express 8, that did not work, but at least then i was able to finally delete the old directory and then I recreated itself.....

NOT FUN AT ALL.

查看更多
我想做一个坏孩纸
3楼-- · 2019-01-06 13:48

Right click on your project file and Edit the project file and remove the URL from IISUrl and reload your project then it will work

查看更多
Fickle 薄情
4楼-- · 2019-01-06 13:48

In my case it happened when IISExpress was still active from a previous VS session and new instance of VS was run.

The solution was to stop (or kill) IIS Express instance.

查看更多
时光不老,我们不散
5楼-- · 2019-01-06 13:49

I resolved this (with vs2013 and windows 7) by going to Documents > IISExpress> Config and renaming the application.config. After that, I restarted visual studio and opened my project and it worked.

查看更多
6楼-- · 2019-01-06 13:52

Fix was really simple for me >> Restart Visual Studio

My setup:

  • Visual Studio 2015

  • Web projects use local IIS 8.5

  • I occasionally experience what I believe to be a VS bug where it converts some projects to use IISExpress (this is fixed by deleting the folder created in /This PC/Documents). This might be related.

查看更多
Anthone
7楼-- · 2019-01-06 13:56

I have just resolved this. It is a strange solution but it worked for me. Here are the steps I took:

Navigate to the folder containing the local IISExpress config files (normally My Documents>IISExpress>config on Windows7).

Find the applicationhost.config file. Rename it to something different e.g. applicationhost2.config.

Navigate to your web project in Visual Studio (I was using VS 2012). Right click on the web project and select Use IISExpress. Run the project. It should fail due to the renaming of the config file.

Change the name of the configuration file back to application.config. Ensure "Use Local IIS Web Server" is selected in the web project settings. Run the solution.

This worked for me.

查看更多
登录 后发表回答