« Previous Next »

Answered Thread: Can not edit or save files in the inetpub folder

Last post 12-23-2007 2:39 AM by thomad. 2 replies.

 

RSS

Page 1 of 1 (3 items)

Sort Posts:

  • 12-22-2007, 6:05 PM

    • ram133
    • Not Ranked
    • Joined on 12-22-2007, 10:57 PM
    • Posts 1

    Can not edit or save files in the inetpub folder

    In IIS on my windows vista ultimate pc why can I not change files in the inetpub?

    I am logged in as administrator, and that is the only account on the pc, but when I try to save or edit a file in the inetpub folder, I get an error message that I must ask the administrator. I have file and folder sharing turned on.
  • 12-22-2007, 6:38 PM In reply to

    Answered Re: Can not edit or save files in the inetpub folder

    Just because you are logged in as administrator, your application is executing as IUSR or Network Service.  Grant the appropriate permissions to this user.

    Steve Schofield
    Windows Server MVP - IIS
    http://weblogs.asp.net/steveschofield

    http://www.IISLogs.com
    Log archival solution
    Install, Configure, Forget
  • 12-23-2007, 2:39 AM In reply to

    • thomad
    • Top 25 Contributor
    • Joined on 08-20-2002, 3:28 PM
    • Redmond
    • Posts 551

    Answered Re: Can not edit or save files in the inetpub folder

    You are running into an UAC issue. You don't have access to c:\inetpub although the Administrators group has access to the folder and you are part of the Administrators group. If you have UAC enabled UAC takes your Administrator privileges away however. Welcome to UAC.

    Here is an easy fix. Run the following command from an elevated command prompt (right click the "command prompt" icon and select "Run as Administrator").

    icacls %systemdrive%\inetpub /grant  %userdomain%\%username%:(OI)(CI)(F) /grant %userdomain%\%username%:F

    This command will add full access for your user account to the INETPUB directory. Now the Administrator privileges which you don't have don't matter anymore because your account and not Administrators grant you access.

    Hope this helps.

     

     

    Thomas Deml
    Program Manager
    Internet Information Services
    Microsoft Corp.
    http://blogs.iis.net/thomad
Page 1 of 1 (3 items)