Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IIS Express Error 500.19 (0x80070003) cannot read config file

Tags:

asp.net

iis

I've been working on MVC 5 tutorial on my office machine. Everything work perfectly in that environment.

Recently I pulled the repository to my personal laptop and I get this error.

IIS Express Error 500.19 (0x80070003) cannot read config file

In the error page I see the following path to the config file:

\?\D:\Dev\Personal\MvcMovie\src\MvcMovie\wwwroot\web.config

Which is a correct path for my office machine, but wrong for the home environment.

Additional info:

Here are locations for the Visual Studio solution:

At the office
D:\Dev\Personal\MvcMovie

At home

C:\Dev\Projects\MvcMovie

I'm a newbie to a web development, so hopefully there is an easy way to solve the problem.

Regards,

Michael

like image 800
Michael Daniloff Avatar asked Mar 19 '16 17:03

Michael Daniloff


People also ask

Where is the ApplicationHost config file located?

The location of the file is currently in the %windir%\system32\inetsrv\config directory.

How do you verify that the application pool identity account of this web application has sufficient permissions to open the web config file?

Go to the parent folder, right-click and select Properties. Select the Security tab, edit the permissions and Add. Click on Advanced and the Find Now. Select IIS_IUSRS and click OK and OK again.


2 Answers

I have resolved the problem deleting the directory ".vs" in the local directory of the project. Note: the directory .vs is hidden from Windows, enables hidden files to be displayed.

like image 123
Roby Gar Avatar answered Oct 09 '22 10:10

Roby Gar


Turned out, IIS Express was pulling the old path from .vs/config/applicationhost.config file

Modifying the path to the current one has resolved the issue

like image 29
Michael Daniloff Avatar answered Oct 09 '22 11:10

Michael Daniloff