2.3 Creating general-purpose SMB shares
To create a new general-purpose SMB share on a volume using
Server Manager, perform the following steps:
-
Launch the New Share Wizard—for example, by right-clicking
on the volume named Archive Volume in Figure 9.
-
Select the SMB Share - Quick option shown previously in
Figure 8.
-
Select a volume on a file server—for example, the 2-TB
volume named Archive Volume that was provisioned using Storage
Spaces in the previous section of this lesson.
-
Type a name for the new share. By default, a new local
folder will be created for the share in the following
location:
<volume>\Shares\<share_name>
For example, if you specify Archive Share as the name for
the new share being created on the E volume, the following local
folder will be created for the new share:
E:\Shares\Archive Share
-
If access-based enumeration is desired, enable it on the
share.
-
If you want to, disable caching on the share. (Caching is
enabled by default.) If you leave caching enabled and the
BranchCache feature is installed on the server, you can enable
BranchCache on the share if desired.
-
If you want to, enable encrypted data access on the
share.
-
Review the permissions for the new share. If you want to,
open the Advanced Security Settings dialog box and modify the
permissions as needed.
-
Click Next, and complete the remaining steps of the wizard
to create the new share.
You can also use Windows PowerShell to create new
general-purpose SMB shares on a volume. For example, you could start
by using the New-Item cmdlet to create a local folder named
E:\Shares\Archived Content for your new share:
PS C:\> New-Item -Path "E:\Shares\Archived Content" -ItemType Directory
Directory: E:\Shares
Mode LastWriteTime Length Name
---- ------------- ------ ----
d---- 8/20/2012 8:55 PM Archived Content
You could then use the New-SmbShare cmdlet to create a new
share named Archive Share that maps to the local folder and assign
the shared folder permission Change to the CONTOSO\Sales group as
follows:
PS C:\> New-SmbShare -Name "Archive Share" -Path "E:\Shares\Archived Content" `
-ChangeAccess CONTOSO\Sales
Name ScopeName Path Description
---- --------- ---- -----------
Archive Share * E:\Shares\Archived Content
If you later decide you want to enable access-based
enumeration on your new share, you could use the Set-SmbShare cmdlet
to do it like this:
PS C:\> Set-SmbShare -Name "Archive Share" -FolderEnumerationMode AccessBased `
-Confirm:$false
The –Confirm:$false portion of the
preceding command suppresses the “Are you sure you want to perform
this action?” confirmation prompt that the Set-SmbShare cmdlet
usually displays.
You can then use the Get-SmbShare cmdlet to verify that
access-based enumeration has been enabled on the share:
PS C:\> Get-SmbShare -Name "Archive Share" | select FolderEnumerationMode | fl
FolderEnumerationMode : AccessBased