Solved

Powershell to create shared folders for users with permssions

Posted on 2015-01-22
3
183 Views
Last Modified: 2015-01-27
Hello!!

I've recently put up a post asking, how I could use PowerShell to create multiple user share folders and amend permissions so that they (the user) have Modify rights only and system/admin have full rights only.
I was provided the following link, https://gallery.technet.microsoft.com/scriptcenter/How-to-create-home-folder-d968f1d4   which did sort of help but as a n00b (forgive me) I need a bit of hand holding as I'm new and learning PowerShell. I have a couple of questions..

1.      How can I use the script so that the user has Modify rights and system/Adam have full rights.
2.      How can the List.txt file i have importing the user name, create the folders in a username structure as oppose to the users full name? i.e. Bob Smith > Bbs

Is anyone able to help and simplify an answer? Also, I have a test environment, so I’m not a live canon :D

Thanks!!!
0
Comment
Question by:N00b2015
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 80

Accepted Solution

by:
David Johnson, CD, MVP earned 500 total points
ID: 40565702
CreateHomeFolder.ps1.txt

To satisfy your requirements changed user from 'full control' to 'modify'
If there are spaces in the users name enclose them with quotes
you should be using the samaccountname
0
 

Author Comment

by:N00b2015
ID: 40566173
David, thank you!!

Everything is working as it should now. Although, the system and admin permissions are now only modify also, which should be full permissions. The user is fine as modify. Any ideas?
0
 

Author Closing Comment

by:N00b2015
ID: 40572485
Demonstrated where the fix needed to be applied including script.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

While rebooting windows server 2003 server , it's showing "active directory rebuilding indices please wait" at startup. It took a little while for this process to complete and once we logged on not all the services were started so another reboot is …
A quick Powershell script I wrote to find old program installations and check versions of a specific file across the network.
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
Finding and deleting duplicate (picture) files can be a time consuming task. My wife and I, our three kids and their families all share one dilemma: Managing our pictures. Between desktops, laptops, phones, tablets, and cameras; over the last decade…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question