Can anyone tell me if there are system requirments to using PowerShell's New-SmbShare cmdlet? I'm trying to create a script that will create the folder, create the share, create groups based on the share name, and assign the appropriate NTFS persmissions
and share permissions. When I try to run New-SmbShare on my Windows 8, I get the following error:
New-SmbShare : Access is denied. At line:1 char:1+ New-SmbShare -Name ISOs -Path C:\Shares\ISOs -FolderEnumerationMode AccessBased ...+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~+ CategoryInfo : PermissionDenied: (MSFT_SMBShare:ROOT/Microsoft/Windows/SMB/MSFT_SMBShare) [New-SmbShare], CimException+ FullyQualifiedErrorId : Windows System Error 5,New-SmbShare
I'm an administrator on the laptop, and local Administrators have Full Control at the NTFS level.
Thanks!