I just published my ASP.NET Website on IIS and have already configured it to be working, everything is running smoothly.
Except.. I can't accept the App_Data file where all my database information is stored. That might not be the only folder that i can't access but maybe possibly App_Code too? Where i place all my Data Access Object classes (CRUD).
I searched high and low on blogs, articles and stackoverflow but i still can't find the solution to accessing the folders.
I also read that by default certain file extensions are being blocked by IIS
These are some hopefully useful information..
It appears that App_Data and App_Code folders are empty..
Codes in Web.config file from Published Directory
Have some issues copying the codes..**
File Segments in IIS
ConnectionStrings in IIS
Error i'm getting..
Any help is appreciated..
Ok this is what you can try to isolate the issue.
Enable Failed Request tracing for the website for which you are seeing this failure.
This will help you determine where the error might be coming from.
Looking at the call-stack you provided, it seems that there is a different issue. I would suggest you to debug the web app on the server to understand what the problem is. Refer the instructions here: https://msdn.microsoft.com/en-in/library/mt621540.aspx
Related
I am having a problem, that is when I deployed my asp.net 4.0 application on my web server i am unable to write to App_Data folder. Actually it has an xml file which I am trying to write some information into. I am getting the following error.
Access to the path 'C:\HostingSpaces\hosterind\mydomain.com\wwwroot\App_Data\ErrorLog.xml' is denied.
I tried searching every corner for a possible solution before posting on stackoverflow but i am unable to fix this. Searching similar questions on internet (stackoverflow too) i concluded that i need to handle it through IIS as everywhere it was quoted on internet to grant permission to App_Data folder through IIS Manager. As accessing IIS Manager of your web hosting server is impossible, i supposed people are referring to my local IIS server. So, i copied my project which i was developing in visual studio from location: C:\Users\DanComputer\Documents\Visual Studio 2010\WebSites\MyWebProject and pasted into C:\inetpub\wwwroot. Then i located my project in IIS Manager by selecting DefaultAppPool as application pool. I changed my App_Data folder permission to allow full control for IIS_IUSRS(DanComputer\IISUSRS). Then i copied my App_Data folder to my web hosting space using ftp software but it didn't solve my problem. I tried many thing even changing permission to allow full control for everyone but it did't work and i am still getting the same error. Any help please?
You need to know what is the identity of the Application Pool of your app. You can get this information from IIS or console. It is possible that your hosing company may have a control panel that can give you that information.
Then you need to give permissions to the account in the app pool identity the names will be the same or at least be very similar to what you saw in IIS:
So using my examples above I will have to give permissions to Local Service or Network Service to read/write my app_data folder.
I am deploying an asp.net solution written in vb.net, the solution works fine on the localhost server and on my development server. On the live server the solution keeps ignoring the local web.config file and is using one belonging to another persons project which I have no control over.
This is the list of files that are in the folder I uploaded to the live server:
imageFolder
Default.htm
FormDelete.aspx
FormDelete.aspx.vb
thankyou.htm
web.config
I want my solution to only look at the web.config located in the same folder as it, and not inherit any values from another web.config file. Can this be done?
Thank you in advanced
This happened to me some days ago; as I was the owner of them both, I deleted the app I didn't need, and restarted IIS.
Maybe there are some similarities between your app and the other one, or there is some bad redirection, I don't know. In my case, the other app just linked to a test database, that's how I knew there was an issue.
Okay, I realize there are many questions relating to this error, I have read several questions and answers without resolving my problem.
I have a MVC site that I'm trying to debug on local IIS web server.
I check the option to use local IIS in the project properties and I've created a virtual directory in IIS.
The error I get in Visual Studio is:
Unable to start debugging on web server.
In IIS i try browse the site but get the error:
Cannot read configuration file due to insufficient permissions
Config File \?\C:\Users\Mike\Documents\Visual Studio 2010\Projects\MvcApplication1\MvcApplication1\web.config
I've set permissions for the pool identity on the web.config and whole project folder.
I've tried localsystem identity, no luck!
Please help me resolve this. I've spent several hours trying to fix this.
I found that if granting read permission to IIS_IUSRS still does not help. You need to also check that the web.config file is not encrypted. You can see if the file name is green in Window Explorer, it means the file encrypted. You can also do right click at the file, select Properties… / General Tab / Advanced… Make sure the "Encrypt content to secure data" unchecked.
It works for me once I uncheck that Encrypt box.
Maybe this will help. Look here, here and here
You also might have to grant ISS_IUSRS right to C:\Windows\Microsoft.NET\Framework64\v2.0.50727\config\machine.config and then do a iisreset
Edit:
Do you have the right Application Pool Identities? Read more here
For local development I've used pritty straightforward solution - just set IIS Application Pool to LocalSystem, set permissions for site folder (ISS_IUSRS - all) and it's worked for me
I only ran into a different set of issues with IIS_IUSRS. So I just published the site under a whole different folder, off the root, and the issue went away!
I am working on a asp.net website which is created by someone else.
Some files are exist in root folder and some are exist in one sub folder.
I can access all files from root folder in the browser, however when try to access the pages from sub folder is shows following error
Access is denied.
Description: An error occurred while accessing the resources required to serve this request. The server may not be configured for access to the requested URL.
Error message 401.2.: Unauthorized: Logon failed due to server configuration. Verify that you have permission to view this directory or page based on the credentials you supplied and the authentication methods enabled on the Web server. Contact the Web server's administrator for additional assistance.
I unable to point out the issue. I checked the web.config file, but didnt get anything related to that folder. I know it is difficult to find the exact issue in my case, but I would appreciate if anyone can give me possible reasons or clues so that i can try.
Thanks in Advance.
EDIT
There is a sub folder web.config with the following content
However, even if I login with "administrator" it fails.
I got the issue, actually previously it was Forms authentication which I commented out.
Is there a web.config file in the sub-folder? These can apply local restrictions.
Other questions that it would be good to know the answer to:
What authentication scheme (forms, windows etc) are you using?
What sort of content are you trying to access (static content or aspx)
what version of IIS are you using?
This sounds like an ACL problem to me. More information, as Xhalent asks, would be useful. Does the user that IIS is using have access to all of the files on the file system?
I don’t know anything about deploying a website, so I probably made some stupid mistake.
Anyways, I opened IIS 7 manager, created new virtual directory ( via Add Application ) and pointed it to physical directory where Visual studio saved my Web project. But when I tried to request an .aspx page, browser reported the following error (I won’t post the whole error, but just the interesting bits):
Handler: Not yet determined
Config Error: Cannot read configuration file due to insufficient permissions
Logon User: Not yet determined
A) why is handler not yet determined? As far as I know, IIS7 does have Asp.Net handler registered?!
B) Why wouldn’t IIS have sufficient permissions? Does that mean I should give IIS higher privileges? Or does Asp.Net runtime have insufficient permissions?
C) Could the error also be due to the fact that perhaps it expected the user to authenticate itself? I’m assuming this due to Logon user not yet being determined?
D) And finally, any ideas how to make it work?
thanx
error code:0x8007000d
I started playing with permissions and all the stuff about access issues to web.config or applicationhost.config anyway those did not change the error.
while I was playing with my web.config I deleted rewrite tags from my config file and error changed. then I installed "web platform installer" and installed url rewrite module for IIS and played with some configuration now my site is working. it took about one day to find out this issue I hope it helps someone.
Does the identity of your IIS application pool have sufficient rights to access the folder that is hosting your site?