Sharing a folder and setting permissions in PowerShell

前端 未结 4 1915
刺人心
刺人心 2021-02-12 22:31

I need a script to run on Vista Ultimate to share an external drive and assign full control to Everyone. I\'ve got a batch file to create the share using net share,

4条回答
  •  醉梦人生
    2021-02-12 23:08

    As of WMF 4:

    New-SmbShare –Name ShareName –Path C:\LocalFolder –FullAccess Username
    

    http://technet.microsoft.com/en-us/library/jj635722.aspx

提交回复
热议问题