Iis ошибка конфигурации не удалось прочитать файл конфигурации

There is no problem with your web.config. Your web site runs under a process. In iis you can define the identity of that process. The identity that your web site’s application pool runs as (Network Services, Local System, etc.), should have permission to access and read web.config file.

Update:

This updated answer is same as above, but a little longer and simpler and improved.

First of all: you don’t have to change anything in your config file. It’s OK. The problem is with windows file permissions.

This problems occurs because your application can not access and read web.config file.

Make the file accessible to IIS_IUSRS group. Just right click web.config and click properties, under security tab, add IIS_IUSRS.

So what is this IIS_IUSRS thing?

Your web site is like an exe file. Just like any exe file, it should be started by a user and it runs according to permissions assigned to that user.

When your site is started in IIS, Application Pool of your web site is associated with a user (Network Services, Local System, Etc. …) (and can be changed in IIS)

So when you say IIS_IUSRS, it means any user (Network Services, Local System, Etc. …) that your site is running as.

And as @Seph mentioned in comment below: If your computer is on a domain, remember that IIS_IUSRS group is a local group.
Also make sure that when you’re trying to find this user check the location it should be set to local computer and not a corporate domain.

  • Remove From My Forums

 locked

Проблема с IIS (HTTP 500.19 — Internal Server Error Код ошибки 0x80070003 )

  • Вопрос

  • Помогите, плз, разобраться с проблемой. 
    С некоторых пор при обращении https://server/certsrv выдает ошибку:

     Ошибка HTTP 500.19 — Internal Server Error
    Запрашиваемая страница не доступна из-за неверной конфигурации данных для этой страницы.

     Модуль CustomErrorModule  
    Уведомление SendResponse  
    Обработчик Пока не определено  
    Код ошибки 0x80070003  
    Ошибка конфигурации Не удалось прочитать файл конфигурации  
    Файл конфигурации \?C:Windowssystem32CertSrvru-RUweb.config  
    Запрашиваемый URL-адрес https://server:443/CertSrv  
    Физический путь C:Windowssystem32CertSrvru-RU  
    Способ входа Пока не определено  
    Вход пользователя Пока не определено  

     с https ситуация такая же.
    указанного файла (C:Windowssystem32CertSrvru-RUweb.config) в каталоге нет и, судя по всему, раньше когда работа была корректной не было (центр сертификации полностью переустанавливался с предварительным удалением каталогов certsrv  и certlog)

    • Перемещено

      22 апреля 2012 г. 20:15
      (От:Windows Server 2008)

Ответы

  • в итоге:
    открыл общий доступ к каталогу ru-RU (ru-RU$), Пользователи — Чтение, Администраторы — Полный доступ.
    прописал для сайта CertSrv:
    путь к каталогу \serverru-RU$,
    настройка «Подкл. как» — Пользователь приложения (Сквозная проверка подлинности)».

    Всё работает.
    непонятно только почему не работает стандартная настройка (для сайта CertSrv путь к каталогу c:windowssystem32certsrvru-RU) — такое ощущение что попасть в локальную папку (c:windows….ru-RU) через IIS нельзя из-за каких то политик, но сетевой доступ через iis к этой же папке (\serverru-RU$) работает…. о_0

    • Помечено в качестве ответа
      Nikita Panov
      6 августа 2009 г. 5:34

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…

Liam's user avatar

Liam

27.3k28 gold badges125 silver badges187 bronze badges

asked Apr 9, 2013 at 9:04

user1275154's user avatar

1

I had a similar issue to @Myles J but renaming %userprofile%DocumentsIISExpressconfigapplicationhost.config didn’t work. What I had to do was the following:

  1. Close Visual Studio.
  2. Rename the %userprofile%DocumentsIISExpressconfig directory.
  3. Start Visual Studio again. The %userprofile%DocumentsIISExpressconfig directory will be recreated with the default config files.
  4. Copy the original applicationhost.config file over the autogenerated one.

Before anyone asks: the permissions on the folders were identical, the read-only flag was not set on the folder or its files, and I didn’t modify applicationhost.config in any way.

answered Nov 12, 2013 at 11:51

Ian Kemp's user avatar

Ian KempIan Kemp

28k19 gold badges111 silver badges134 bronze badges

8

After installing IIS Express, copy all files from

C:Program FilesIIS ExpressconfigtemplatesPersonalWebServer

to

%userprofile%DocumentsIISExpressconfig

Zameer Ansari's user avatar

Zameer Ansari

28.5k24 gold badges139 silver badges217 bronze badges

answered Jul 25, 2014 at 13:10

user3877075's user avatar

user3877075user3877075

6015 silver badges2 bronze badges

3

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

answered Apr 9, 2014 at 5:04

Deva's user avatar

DevaDeva

3293 silver badges2 bronze badges

5

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.

answered Apr 30, 2013 at 8:27

Myles J's user avatar

Myles JMyles J

2,8393 gold badges25 silver badges41 bronze badges

2

If you do:

C:Users”username*****”DocumentsIISExpressconfig

You find these file

applicationhost.config
aspnet.config
redirection.config

Delete above 3 file and then open the project.then the problem is solved. I tried, its working fine.

durron597's user avatar

durron597

31.9k17 gold badges99 silver badges156 bronze badges

answered Sep 5, 2015 at 16:55

Ramu Jannu's user avatar

Ramu JannuRamu Jannu

811 silver badge1 bronze badge

1

I have the exact same issue with Visual Studio 2013 on Windows 8.1
I map My Documents folder to SkyDrive, so the IISExpress folder was marked as «Online-only». Once I marked it as «Available offline» everything worked.

answered Nov 23, 2013 at 3:33

Matt's user avatar

MattMatt

6,18410 gold badges52 silver badges80 bronze badges

1

Visual Studio will only report the filename it looks for, not the full path. The problem for many users is that the IISExpress with the redirection.config can exist in multiple paths, including a OneDrive path which may not be synced.

To figure out exactly what file Visual Studio attempts to open, use the Microsoft (SysInternals) tool ProcMon. It lists all files and resources Windows tries to access. Add a filter for «Path contains redirection.config» and reproduce the problem in Visual Studio. Now you will see the actual path it tries to use.

In my case, I have multiple IISExpress folders. One that was synced to OneDrive and another one that was local. Visual Studio tried to access the OneDrive folder which was not synced to the local disk, and thus it failed.

Forcing IISExpress folder to store files locally resolved the problem

answered May 7, 2020 at 7:57

Dan Gøran Lunde's user avatar

Dan Gøran LundeDan Gøran Lunde

5,1283 gold badges25 silver badges24 bronze badges

3

In some situations simply renaming/deleting the applicationhost.config file isn’t enough since VS won’t always recreate it for you. I believe the following will fix it under all circumstances:

Close Visual Studio.

Make sure there are no IIS Express processes running, then delete C:UsersXXXXDocumentsIISExpressconfigapplicationhost.config (where XXXX is your Windows username).

On command line, execute c:Program FilesIIS Expressiisexpress.exe. This will recreate the necessary configs. Press ‘Q’ straight away to end the process.

Open Visual Studio again and Start/Debug your web project. Everything should now be working.

answered Jun 27, 2014 at 4:35

David Fidge's user avatar

David FidgeDavid Fidge

4515 silver badges6 bronze badges

2

Backup files at local IISExpress folder. It can be found at: C:Users”username*****”DocumentsIISExpressconfig
Go to the location:
C:Program FilesIIS ExpressconfigtemplatesPersonalWebServer
Copy the required files from this directory to the local IISExpress folder.
It worked for me after I copied over the files:
applicationhost.config
aspnet.config
redirection.config

answered Feb 19, 2015 at 14:55

user_s's user avatar

user_suser_s

811 silver badge2 bronze badges

1

In my case the ‘My documents’ folder for my work laptop was mapped to a network share. So when the work network was not available I was not able to open my solution.

Change:
These will have the value of my docs in network share. Change this to local

I. ComputerHKEY_CURRENT_USERSoftwareMicrosoftWindowsCurrentVersionExplorerShell FoldersPersonal

II. ComputerHKEY_CURRENT_USERSoftwareMicrosoftWindowsCurrentVersionExplorerUser Shell FoldersPersonal

For eg:

Old value: networkdrivec$UsersprofileDocuments

New value: C:UsersprofileDocuments

See:
https://blogs.msdn.microsoft.com/chiranth/2015/04/01/error-while-runningstarting-a-website-under-iisexpress-in-visual-studio/

answered Aug 29, 2016 at 11:27

Khabba's user avatar

The issue is that the files in C:Users»Your Username»DocumentsIISExpressconfig are encrypted.
Open this folder, Select all the files, Right click and select properties,
Click advanced, deselect «Encrypt contents to secure data, Click okay, click apply.

That will fix it.

answered Jul 24, 2015 at 17:21

jshaw's user avatar

jshawjshaw

214 bronze badges

Using Visual Studio 2013

I had to stop visual studio rename the whole config directory, Documents > IISExpress> Config then start a new web project, which fails but it recreates the config directory, then I rebooted and launched visual studio and everything worked!

I noticed this problem after copying a project between 2 computers, perhaps it was caused by a duplicate IISExpress port or something trivial.

answered May 12, 2014 at 16:51

JustEngland's user avatar

JustEnglandJustEngland

1,37113 silver badges30 bronze badges

1

Using VS2013 / Windows 7

Close solution. Open Windows Explorer and right-click on «My DocumentsIISExpressconfig» directory and select «Decrypt». Be sure «Apply changes to this folder, subfolders and files» is selected. Reopen VS solution.

answered Jun 18, 2014 at 19:46

user3754015's user avatar

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.

answered Feb 26, 2015 at 10:37

andrew.fox's user avatar

andrew.foxandrew.fox

7,2855 gold badges52 silver badges75 bronze badges

1

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.

answered Aug 29, 2016 at 19:08

GraehamF's user avatar

GraehamFGraehamF

1,96124 silver badges24 bronze badges

You don’t need to close Visual Studio or rename anything.

  1. Open properties for %userprofile%Documents
  2. Select Security > Advanced, change owner to yourself (again if you are already owner).
  3. Select «Replace owner on subcontainers and objects» and «Replace all child object permission entires with inherited permission entires from this object».
  4. Ok.

answered Jun 13, 2018 at 8:57

amuliar's user avatar

amuliaramuliar

1,30815 silver badges26 bronze badges

For me, It’s a simple lack of permission either give everyone permission
to «%userprofile%DocumentsIISExpressconfig» this folder or Open VS in Admin mode

answered Dec 18, 2020 at 11:49

GSKKC's user avatar

GSKKCGSKKC

456 bronze badges

for me was removing the file DocumentsIISExpressconfigapplicationhost.config

Closing visual studio > Open > Debug

Thanks for the previous answer help go straight to the issue

answered Apr 15, 2021 at 20:43

Starlin González's user avatar

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.

answered Jan 3, 2014 at 9:07

Tom Stickel's user avatar

Tom StickelTom Stickel

19.5k6 gold badges111 silver badges113 bronze badges

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.

answered Feb 22, 2014 at 16:14

nixkuroi's user avatar

nixkuroinixkuroi

2,2591 gold badge19 silver badges25 bronze badges

I ran into this issue while trying to open another developer’s solution after installing VS2013 (Update 3 RC). After following the advice here and deleting/renaming/etc. the config folder, VS re-created the files in the wrong location. It created nested config folders:

C:Users[user]DocumentsIISExpressconfigconfig

I moved everything from …configconfig into …config, and it worked as expected.

answered Jul 21, 2014 at 22:20

Brandon Gano's user avatar

Brandon GanoBrandon Gano

6,4201 gold badge24 silver badges24 bronze badges

I found that deleting one of the sites from the applicationhost.config file resolve this problem for me.

I used the following command from the %ProgramFiles(x86)%IISExpress directory:

appcmd list site

then

appcmd delete site rogueSiteName

Especially there was a site name with a bracketed number suffix (e.g. «MySite(1)») that I deleted. I’m not sure yet if VS2013 just had an issue with the brackets or that two sites pointed to the same directory. Either way deleting it made VS happy again.

Background

I had been struggling with this issue for a couple of days and nothing seemed to help — not even the instructions given in the top answers here.

I had also tried moving the config folder as mentioned in http://www.iis.net/learn/extensions/introduction-to-iis-express/iis-80-express-readme. But although VS2013 recreated the directory structure and files in the new location the errors continued and running appcmd showed that it was still pointing at the old location by default.

Credits

Credit for where I found the commands to use goes to http://gyorgybalassy.wordpress.com/2013/12/02/cleaning-up-iis-express-configuration/

answered Nov 7, 2014 at 11:23

WooWaaBob's user avatar

WooWaaBobWooWaaBob

3,3773 gold badges23 silver badges23 bronze badges

For ASP.Net Core just access your Properties section, then make a modification and save it.

Example: I modified the SSL port
Core Example

You will get a notification that your launchsettings.json was modified. Accept that and you’re good to go.

answered Nov 29, 2016 at 11:35

Razvan Dumitru's user avatar

Razvan DumitruRazvan Dumitru

11.7k5 gold badges34 silver badges53 bronze badges

If it is ASP.NET Core project

Just try to change iis port in file launchSettings.json by path iisSettings:iisExpress:applicationUrl

answered Aug 14, 2017 at 10:37

skorenb's user avatar

skorenbskorenb

6291 gold badge9 silver badges16 bronze badges

It’s 2020, I am reporting the same problem in Visual Studio 2019.

Cause: Multiple VS instances open with different web app (Blazor in my instance).

Solution: Close all VS instances and re-open the solution that you want to run.

answered May 16, 2020 at 12:01

Johnny Wu's user avatar

Johnny WuJohnny Wu

1,28715 silver badges30 bronze badges

On IIS 10 Express. Make sure that Visual Studio (VS) is turned off.

I first found out that %userprofile%DocumentsIISExpressconfig was not working.

I first thought IIS Express had clashed with IIS from the windows OS.

I uninstalled it, yet no changes, then I uninstalled IIS 10 Express that was installed with VS 2019 through the control panel.

Then I went ahead to discover that this file is saved at the C:UsersusernameOneDriveDocumentsIISExpress, associated with one drive storage, so I advise you copy %userprofile%DocumentsIISExpressconfig and paste in your windows explorer navigation to find directory.

go to one directory higher, and/or rename the config folder. Restart your VS and run the project again.

answered Nov 22, 2020 at 6:47

Rikudou En Sof's user avatar

Rikudou En SofRikudou En Sof

4261 gold badge4 silver badges19 bronze badges

Mine was caused by OneDrive. Apparently my documents folder is being synced to it.
What I did is changed the location of the documents folder through regedit and navigated to this path:

HKEY_CURRENT_USER > Software > Microsoft > Windows > CurrentVersion > Explorer > User Shell Folders

and then changed the value of Personal
from: C:Usersmy usernameOneDriveDocuments
to C:Usersmy usernameDocuments

After that I restart my computer and I was able to create a VS project.

answered Jun 12, 2021 at 17:18

Andrew Casal's user avatar

I have the same issue,
First time, i think Visual Studio not permission access to %userprofile%DocumentsIISExpressconfig so i run Visual Studio with Administrator, but it not working.
I try all answer above but still the error!

Finally, i look internet, i see my onedrive is stopping, i enable and sync data. Restart computer and worked.

answered Oct 9, 2022 at 16:50

HOÀNG LONG's user avatar

HOÀNG LONGHOÀNG LONG

3932 silver badges12 bronze badges

Just uninstalled OneDrive from your comp

answered May 20 at 8:47

Eyal's user avatar

EyalEyal

4,6239 gold badges40 silver badges55 bronze badges

С вашим веб-сайтом нет проблем с . Ваш веб-сайт работает в процессе. В iis вы можете определить личность этого процесса. идентификатор, который использует ваш веб-сайт пул приложений, как (сетевые службы, локальная система и т.д.), Должен иметь разрешение на доступ и чтение файла web.config.

Update:

Этот обновленный ответ аналогичен приведенному выше, но немного длиннее, проще и улучшен.

Прежде всего: вам не нужно ничего менять в конфигурационном файле. В порядке. Проблема заключается в разрешении файлов Windows.

Эти проблемы возникают из-за того, что ваше приложение не может получать доступ и читать файл web.config.

Сделайте файл доступным для группы IIS_IUSRS. Просто щелкните правой кнопкой мыши web.config и нажмите свойства, под вкладкой безопасность добавьте IIS_IUSRS.

Итак, что это за IIS_IUSRS?

Ваш веб-сайт , например, exe. Как и любой exe файл, он должен быть запущен пользователем, и он запускает в соответствии с разрешениями, назначенными этому пользователю.

Когда ваш сайт запущен в IIS, Пул приложений вашего веб-сайта связан с пользователем (сетевые службы, локальная система, И т.д….) (и может быть изменен в IIS)

Поэтому, когда вы говорите IIS_IUSRS, это означает любой пользователь (сетевые службы, локальная система и т.д.), которые работают на вашем сайте.

И как @Seph, упомянутый в комментарии ниже. Если ваш компьютер находится в домене, помните, что группа IIS_IUSRS — это локальная группа.
Также убедитесь, что когда вы пытаетесь найти этого пользователя, проверьте местоположение, на котором он должен быть установлен на локальный компьютер, а не на корпоративный домен.

Недавно я столкнулся с ошибкой при попытке разместить мой сайт asp.net с помощью IIS. Я нашел решение, которым многие верят.

Решение:

  1. Добавить IIS_IUSRS с разрешением на чтение для файлов в папке
  2. Измените метод проверки подлинности IIS на BasicAuthentication
  3. обновите сайт. Это сработает

(http://vivekthangaswamy.blogspot.com/2009/07/ aspnet-website-cannot-read.html)

Что я могу добавить в свой файл web.config? Мне никогда раньше не приходилось его редактировать. Вот его текущее содержание:

<?xml version="1.0"?>
<!--
  For more information on how to configure your ASP.NET application, please visit
  http://go.microsoft.com/fwlink/?LinkId=169433
  -->
<configuration>
    <connectionStrings>
  <add name="DefaultConnection" connectionString="Data Source=.SQLEXPRESS;AttachDbFilename=|DataDirectory|Database.mdf;Integrated Security=True;User Instance=True"
   providerName="System.Data.SqlClient" />
 </connectionStrings>
 <system.web>
  <compilation debug="true" strict="false" explicit="true" targetFramework="4.0"/>
    </system.web>
</configuration>

Моя ошибка:

Ошибка конфигурации: не удается прочитать файл конфигурации из-за недостаточных разрешений
Файл конфигурации: ? C: Users ***** Documents Visual Studio2010 WebSites PointsForTime web.config

30 ответов

Лучший ответ

Нет проблем с вашим web.config . Ваш веб-сайт работает в рамках процесса. В iis вы можете определить идентичность этого процесса. Удостоверение , под которым пул приложений вашего веб-сайта ( Сетевые службы, локальная система и т. Д.), Должно иметь разрешение на доступ и чтение в Интернете. .config файл.

Обновить:

Этот обновленный ответ такой же, как и выше, но немного длиннее, проще и улучшен.

Прежде всего : вам не нужно ничего менять в файле конфигурации. Все в порядке . Проблема связана с разрешениями для файлов Windows .

Эта проблема возникает из-за того, что ваше приложение не может получить доступ и прочитать файл web.config .

Сделайте файл доступным для группы IIS_IUSRS . Просто щелкните правой кнопкой мыши web.config и выберите свойства на вкладке безопасность , добавьте IIS_IUSRS .

Так что это за штука IIS_IUSRS?

Ваш веб-сайт представляет собой файл EXE . Как и любой exe-файл, он должен быть запущен пользователем и запускается в соответствии с разрешениями , назначенными этому пользователю.

Когда ваш сайт запускается в IIS , Пул приложений вашего веб-сайта связывается с пользователем ( Сетевые службы, Локальная система < / em> и т. д. …) (и может быть изменено в IIS)

Поэтому, когда вы говорите IIS_IUSRS , это означает любого пользователя ( Сетевые службы, локальная система и т. Д. …), что ваш сайт работает как .

И как @Seph упоминается в комментарии ниже : Если ваш компьютер находится в домене , помните, что Группа IIS_IUSRS — это локальная группа . Также убедитесь, что, когда вы пытаетесь найти этого пользователя, проверьте местоположение, он должен быть установлен на локальный компьютер, а не на корпоративный домен.


614

Sнаđошƒаӽ
25 Окт 2019 в 08:27

Примечание редактора: выполнение того, что предлагает этот ответ: «изменение удостоверения на LocalSystem» ОПАСНО! Учетная запись LocalSystem — это…

Полностью доверенная учетная запись, в большей степени, чем учетная запись администратора. В одном ящике нет ничего, что эта учетная запись не могла сделать, и у него есть право доступа к сети в качестве машины (для этого требуется Active Directory и предоставление разрешений учетной записи компьютера для чего-либо)


Изменение идентификатора с ApplicationPoolIdentity на LocalSystem сделало свою работу;).

Я использую win7 64 с IIS 7.5

Больше о Идентификатор пула приложений в IIS 7.5 и win 7

enter image description here


67

MeSo2
4 Янв 2022 в 16:33

У меня была такая же проблема, когда я попытался поделиться корневой папкой сайта с другим пользователем. Какая-то папка потеряла разрешение. Итак, я выполнил шаги, чтобы добавить разрешение группе IIS_IUSRS , как было предложено Афшин Гх. Проблема в том, что эта группа была недоступна для меня. Я использую windows 7.

Что я сделал, я просто изменил несколько шагов:

  1. Щелкните правой кнопкой мыши родительскую папку (которая потеряла разрешение),
  2. Свойства => Безопасность => В «Имена групп или пользователей:»,
  3. Щелкните Изменить …
  4. Откроется окно «Разрешение для вашей папки».
  5. В «Имена групп или пользователей:» нажмите ДОБАВИТЬ … btn,
  6. Введите Authen и нажмите Проверить имена,
  7. Вы увидите полное название группы « Прошедшие аутентификацию «.
  8. Нажмите ок => применить.
  9. Это должно снова включить привилегии.

Это сработало для меня.


71

IgorAlves
22 Сен 2015 в 15:49

Вам не нужно ничего менять в файле web.config.

Проблема в разрешениях файловой системы. Ваши права доступа к файлу не позволяют пользователю IIS_IUSRS получить доступ к web.config (или, возможно, к любому из файлов). Измените их права доступа к файлам в Windows, чтобы позволить учетной записи IIS_IUSRS получить к ним доступ.


19

Erik Funkenbusch
11 Апр 2011 в 03:28

Сделайте файл доступным для группы IIS_IUSRS . Щелкните правой кнопкой мыши свой web.config, разверните свойства и на вкладке безопасности добавьте IIS_IUSRS. Предоставьте группе доступ для чтения / записи.

Когда группа НЕ доступна, замените IIS_IUSRS на ComputerName IIS_IUSRS .


21

Kurt Van den Branden
24 Окт 2016 в 10:55

Когда вы предоставляете разрешения для IIS_IUSRS , вы должны проверить, что в разделе IIS / Authentication вашего веб-приложения учетные данные для анонимной аутентификации используют идентификатор пула приложений, а не IUSR.

enter image description here


14

Carlos
23 Июн 2015 в 03:18

Перейдите в родительскую папку, щелкните правой кнопкой мыши и выберите Свойства . Выберите вкладку Безопасность , измените разрешения и Добавить . Нажмите Дополнительно и Найти . Выберите IIS_IUSRS и снова нажмите ОК и ОК . Убедитесь, что у вас установлен флажок Запись . Снова нажмите ОК и ОК .

Работа сделана!


13

Quinny
8 Янв 2012 в 13:21

По какой-то причине ваш web.config установлен только для чтения. Снимите флажок только для чтения в файле web.config.


8

Luis
7 Ноя 2011 в 18:35

Я использовал subst для создания сопоставления от D: до C:, чтобы сохранить те же настройки, что и у других разработчиков в команде. Это также дало мне те же ошибки, что и описано. Удаление этого исправило это для меня.


4

Sniipe
25 Сен 2012 в 19:10

Вместо предоставления доступа всем пользователям IIS, таким как IIS_IUSRS, вы также можете предоставить доступ только к идентификатору пула приложений с помощью сайта. Это рекомендованный подход Microsoft, дополнительную информацию можно найти здесь:

https://support.microsoft.com/en-za/help/4466942/understanding-identities-in-iis

https://docs.microsoft.com/en-us/iis/manage/configuring-security/application-pool-identities

Fix :

enter image description here

Начните с просмотра параметра файла конфигурации выше, чтобы определить расположение, к которому требуется доступ. В этом случае требуется доступ ко всей папке publish. Щелкните правой кнопкой мыши папку и выберите свойства, а затем вкладку Безопасность.

enter image description here

Нажмите Edit..., а затем Add....

Теперь посмотрите на Диспетчер информационных служб Интернета (IIS) и пулы приложений:

enter image description here

В моем случае мой сайт работает в пуле приложений LocalTest, а затем я ввожу имя IIS AppPoolLocalTest

enter image description here

Нажмите Check Names, и пользователь должен быть найден.

enter image description here

Дайте пользователю необходимый доступ (по умолчанию: чтение и выполнение, список содержимого папки и чтение), и все должно работать.


5

Ogglas
8 Июл 2020 в 12:31

Это произошло с нами, когда в приложении IIS есть виртуальный каталог с физическим путем , который содержит косые черты / вместо обратной косой черты . Это было случайно сделано с помощью API управления PowerShell для IIS в процессе непрерывной доставки.

Пример неверной конфигурации — applicationHost.config

<application path="/MySite/MyService" applicationPool="MyAppPool" enabledProtocols="http">
    <virtualDirectory path="/" physicalPath="C:inetpubMySite/MyService" />
</application>

Убедитесь, что атрибут physicalPath не содержит косых черт / , а только обратных косых черт

Исправленный пример конфигурации — applicationHost.config

<application path="/MySite/MyService" applicationPool="MyAppPool" enabledProtocols="http">
    <virtualDirectory path="/" physicalPath="C:inetpubMySiteMyService" />
</application>


4

SliverNinja — MSFT
22 Окт 2016 в 01:35

Для меня ошибка возникла во время отладки на моем локальном компьютере и оказалась связанной с базовым файлом web.config, который запускается .NET Framework при компиляции веб-сайта. В моем файле C: Windows Microsoft.NET Framework64 v4.0.30319 Config web.config был нераспознанный элемент (folderLevelBuildProviders). Исправление этого исправило ошибку 500.19.

См. Это: Диспетчер IIS не может настроить компиляцию .NET. в приложениях .NET 4


2

Community
23 Май 2017 в 14:47

У меня была такая же проблема с правами доступа к файлу web.config.

Однако моя проблема была вызвана тем, что IIS не удалось загрузить файл конфигурации, поскольку он содержал правила перезаписи URL-адресов, а я не установил модуль перезаписи URL-адресов IIS на новый сервер.

Решение состояло в том, чтобы установить модуль перезаписи.


87

TylerH
8 Фев 2022 в 19:53

Изменение идентификатора модели процесса на LocalSystem устранило эту проблему для меня. Вы можете найти этот параметр, если щелкните правой кнопкой мыши пул приложений и выберите «Дополнительные параметры». Я использую IIS 7.5.


3

jshoaf
3 Июн 2015 в 20:28

Переместите свой проект на другой диск, кроме C: У меня работала с той же ошибкой.


3

Talha Imam
16 Фев 2017 в 14:12

Принятое решение меня не устроило. Я использую репозиторий Git, и он клонирован в следующую папку

c:usersmyusernamesourcereposmyWebSite

Я создал новый веб-сайт IIS и указал его на путь. У которого не было разрешений iis_iusrs, предложенных в принятом решении. Когда я добавил разрешения, он все еще не работал.

Он начал работать только тогда, когда я дал следующие разрешения группе «Пользователи», и наследование каскадировало разрешения для web.config. Вероятно, следовало применить его только к web.config, чтобы уменьшить площадь поверхности атаки.

User Pemissions


3

Tom McDonald
24 Май 2017 в 20:03

Все предоставленные ответы действительны и работают при различных обстоятельствах.

Для меня перезапуск Visual Studio сработал.


3

Doruk
31 Май 2019 в 09:17

У нас был веб-сайт, работающий с определенным идентификатором в пуле приложений, только после предоставления этому пользователю доступа для чтения к папке, содержащей web.config, он работал бы. Мы отследили это после добавления пользователя «все» с функцией чтения, и все работало нормально.


2

rob
16 Янв 2014 в 20:02

Щелкните правой кнопкой мыши Web.Config => Tab Security => Button Edit => Button Add => Button Advanced => Button Find Now => В результатах поиска выберите свою группу (в нашем случае «IIS_IUSRS») => Ok => Ok => Хорошо


2

Ihor Levkivskyi
5 Окт 2016 в 10:30

Я решил это, добавив разрешение на чтение в папку для пользователя пула приложений (WIN SERVER 2008 R2): C: Windows System32 inetsrv config

Небольшая предыстория: наш сервер был взломан с использованием классической ошибки, когда у пользователя приложения было больше разрешений, чем он должен (локальный администратор).

Чтобы исправить это, мы создали нового пользователя домена, у которого были только разрешения на папку приложения, с минимальными необходимыми правами, и назначили его пользователем пула приложений. чем мы столкнулись с проблемой, и это было решением наших проблем.


2

ludens
19 Янв 2017 в 12:36

Приведенные выше ответы были полезны, но в случае, если это кому-то поможет — у меня была именно эта проблема, и оказалось, что я (сеть Windows) использовал корневую папку, из которой размещался сайт. Мы убили общий ресурс и добавили разрешение пользователей на чтение / выполнение, и он снова заработал нормально.

Я подозреваю, что акция все испортила.


2

Michael
12 Фев 2020 в 23:35

Я также получал сообщение «Не могу прочитать файл конфигурации из-за недостаточных разрешений». Оказывается, ограничения ISAPI и CGI в IIS для 32-разрядной и 64-разрядной версии ASP.NET 4.0 были запрещены. Пометка их обоих как разрешенных устранила мою проблему.


1

Earl
24 Окт 2014 в 00:53

Была эта проблема с виртуальным приложением. Все разрешения были выставлены. IIS_IUSRS, AppPoolIdentity, а затем предоставил полный доступ всем. Ничего не получилось. Перезапущен пул приложений, сайт и IIS, но нет.

Удалил виртуальное приложение и снова добавил с нуля, и оно начало работать.

Хотел бы я знать, что это решило.


0

gbs
26 Июн 2015 в 08:52

Проверьте, не помечен ли файл как только для чтения , несмотря на разрешение IIS_IUSRS, он будет отображать то же сообщение.


0

Syed Umar Ahmed
10 Июл 2015 в 15:21

У меня было это сообщение об ошибке, которое оказалось из-за того, что моя физическая папка была расположена на сетевом диске, а не на локальном. Кажется, разрешения на таких дисках по умолчанию могут быть разными. Например, в то время как расположение локального диска давало разрешение пользователям локального компьютера, расположение в сети — нет.

Далее, принятый ответ в таком случае не работает. Локальные пользователи или пользователи IIS не были доступны для назначения разрешений. Решением было переместить физическую папку на локальный диск.


0

Kat
16 Сен 2015 в 18:23

У меня была такая же проблема, и после того, как я выполнил все, что написано здесь в качестве ответов, она все еще воспроизводится. Вторая половина проблемы заключалась в том, что .NET был отключен в разделе «Включение или отключение компонентов Windows».


0

Bogdan Mates
14 Июл 2016 в 10:33

Иногда, если это новый сервер, вам нужно настроить или установить функцию ASP.NET в IIS, чтобы он мог читать ваш файл web.config.

В моем случае это было причиной.


0

SanthoshM
28 Окт 2016 в 18:50

В моем случае я пытался разместить страницы с подключенного диска (subst). Проблема в том, что подстановка была запущена под моей учетной записью, и пользователь IIS не может видеть тот же диск.


0

Dinesh Rajan
2 Мар 2017 в 05:56

Это может произойти, если ваше приложение находится в виртуальном каталоге, а путь к файлам — это подключенный диск.

Если вы измените путь к файлам на локальном диске, это решит проблему, если это действительно ваша проблема.


2

UKcentric
4 Янв 2019 в 18:17

Понравилась статья? Поделить с друзьями:
  • Ihka система отопления с auc ошибка бмв
  • Ignore as err 0x0080 pandora ошибка
  • Ignition on фольксваген поло что означает ошибка
  • Ignition on фольксваген поло не заводится причины ошибка
  • Ignition on ошибка фольксваген поло что это