Directory Permissions Windows (v3.6.3)

Re: Directory Permissions Windows (v3.6.3)

by Leon Stringer -
Number of replies: 1
Picture of Core developers Picture of Particularly helpful Moodlers

You don't say which web server you're using.

If you are using IIS this will use an IIS user unless you've set up integrated authentication (you'll know if you've done this). By default a folder won't be writable an IIS user unless you've added access for this so your Moodle files should already be set up correctly. But the Moodledata directory must be writable by the web server user. To achieve this I follow the steps from the PHP documentation:

Determine the IIS user for your site with %windir%\system32\inetsrv\appcmd.exe list config "Default Web Site" /section:anonymousAuthentication. Default Web Site is the name that appears for your site in the IIS Manager console, if you've used something else you should change this, e.g.:

C:\inetpub>%windir%\system32\inetsrv\appcmd.exe list config "Moodle site" ^
More? /section:anonymousAuthentication

      <anonymousAuthentication enabled="true" userName="IUSR" />

In the above example the IIS user is IUSR so we need to give this write access to the Moodledata folder. So, assuming this is C:\inetpub\moodledata the command would be icacls C:\inetpub\moodledata /grant IUSRsadOI)(CI)(M):

C:\inetpub>icacls C:\inetpub\moodledata /grant IUSR:(OI)(CI)(M)
processed file: C:\inetpub\moodledata
Successfully processed 1 files; Failed processing 0 files

If you're using Apache or XAMPP the best advice is to switch to IIS. Apache on Microsoft Windows is not suitable for production sites.

Lastly, don't apologise for asking questions, that's a good rule for these forums and probably a good rule for life too.

Average of ratings: Useful (2)
In reply to Leon Stringer

Re: Directory Permissions Windows (v3.6.3)

by Leon Stringer -
Picture of Core developers Picture of Particularly helpful Moodlers

Looks like I need to post a forum question asking how to stop characters being replaced with emoticons.

Those sad faces are supposed to be a ':' followed by '('.