IIS7 Permission Denied - Write to ASP File

Unfortunately, I do not have much information about this. I have a client that has moved their site from the old system in IIS7 to Windows 2008 Server. Error information below:

Error: E: \ Wwwroot \ sp \ xxx \ online_data.xls Microsoft VBScript runtime error '800a0046'

Permission denied

/xxx/oat/exceldata.asp line 52

the code:

49 response.write(server.mappath("online_data.xls")) 50 51 set fso = createobject("scripting.filesystemobject") 52 Set act = fso.CreateTextFile(server.mappath("online_data.xls"), true) 

The only thing so far suggested:

provide the application pool (DefaultAppPool / Classic AppPool) s read and write permission to the physical folder that are on the asp page

Look at this when I get access, but other offers will be appreciated.

+6
iis-7 asp-classic
source share
4 answers

The answer provided is correct, but I needed a little more detail on how to execute it. To do this very simply, follow these steps: I set up the asp page counter on the sandbox system on our intranet.

  • Open Computer Management.
  • Migrating to IIS Server Management
  • In the Connections panel, click Application Pools
  • In the Application Pools panel, right-click DefaultAppPool and select Advanced Settings. Take a look at the section "Process Model".
  • By default, set the Identity property to ApplicationPoolIdentity. This is a built-in account.
  • If it is set to the default value, then you can use the built-in user machine name \ IUSR for your permissions. I had to specify the name of the machine because it is a virtualized server, YMMV.
  • If it is not set to the default value, use this username for your configuration rights.
  • Cancel the dialog and return to Windows Explorer, to the folder where you need to add permission.
  • Right-click to get permission settings.
  • Configure username \ IUSR or the incorrect username that you identified in steps 6/7 above. Grant if necessary.

This helped: http://learn.iis.net/page.aspx/140/understanding-built-in-user-and-group-accounts-in-iis-7/

+12
source share

The sentence is correct. If the path to the solution is not immediately obvious for some configuration reasons, try running procmon (filter on "online_data.xls") and see who the failure is, why and what user account they are launching. Then check the ACL.

+3
source share

I had a similar problem in Windows 7 and my solution changed authentication. From IIS, select a site, go to Authentication, turn off anonymous authentication, and enable Windows authentication.

+2
source share

A little time passed with something similar. Even with the correct settings, it did not work.

Then I tried to create the actual file first on the server. It turned out to be a trick that worked. Now my ASP page is not writing to an existing file.

There must be something about creating a new document from scratch, which is another problem.

0
source share

All Articles