NTFS rights for auto creating home directory

When a user logs on into a new environment, whether or not managed by RES PowerFuse, it’s always good to have a backup script in place for setting up the missing home drive. For instance my file share for hosting the home directories is \FILESERVER\USERS$. There everyone has a folder equal to his Username. So my home directory would be \FILESERVER\USERS$\Jeroen

But. When the folder Jeroen doesn’t exist I want to auto create it by an ‘External Task’ (RES PowerFuse) or login script.

To do this, add the following line in the loginscript.

IF NOT EXIST \\FILESERVER\USERS$\%USERNAME% MD \\FILESERVER\USERS\%USERNAME%

Or create an External Task (before running any other task, runonce, no time-out, wait before continue), in RES PowerFuse with that line.

Now the tricky part. Because that script is run with the users his credentials, the NTFS rights on the share must be pretty damn good Winking smile. Otherwise, other users can access folders from other users.

Group

Rights

Apply To

Administrators (Or Domain Admins) Full Control This folder, subfolders and files
Authenticated Users Traverse Folder, List Folder, Read Attribute, Create Folder, Read Permissions This folder only
CREATOR OWNER Modify Subfolders and files only
SYSTEM Full Control This folder, subfolders and files

Untitled

2 thoughts on “NTFS rights for auto creating home directory

  1. Hello,

    Nice write up!
    Would the permissions be set on the “\servernameusers$” shared? along with inheritable permissions?

    Thank you

    1. Correct Alex. But disable/uncheck the inheritance permissions.

      The share rights would be:

      Domain Admins: Full Control;
      Everyone: Change.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Related Posts

Begin typing your search term above and press enter to search. Press ESC to cancel.

Back To Top