Create a BranchCache-enabled SMB share

Contributors

You can enable BranchCache on an SMB share when you create the share by setting the branchcache share property.

About this task
  • If BranchCache is enabled on the SMB share, the share must have the offline files configuration set to manual caching.

    This is the default setting when you create a share.

  • You can also specify additional optional share parameters when you create the BranchCache-enabled share.

  • You can set the branchcache property on a share even if BranchCache is not configured and enabled on the storage virtual machine (SVM).

    However, if you want the share to offer cached content, you must configure and enable BranchCache on the SVM.

  • Since there are no default share properties applied to the share when you use the -share-properties parameter, you must specify all other share properties that you want applied to the share in addition to the branchcache share property by using a comma-delimited list.

  • For more information, see the man page for the vserver cifs share create command.

Step
  1. Create a BranchCache-enabled SMB share:
    vserver cifs share create -vserver vserver_name -share-name share_name -path path -share-properties branchcache[,…​]

  2. Verify that the BranchCache share property is set on the SMB share by using the vserver cifs share show command.

Example

The following command creates a BranchCache-enabled SMB share named “data” with a path of /data on SVM vs1. By default, the offline files setting is set to manual:

cluster1::> vserver cifs share create -vserver vs1 -share-name data -path /data -share-properties branchcache,oplocks,browsable,changenotify

cluster1::> vserver cifs share show -vserver vs1 -share-name data
                      Vserver: vs1
                        Share: data
     CIFS Server NetBIOS Name: VS1
                         Path: /data
             Share Properties: branchcache
                               oplocks
                               browsable
                               changenotify
           Symlink Properties: enable
      File Mode Creation Mask: -
 Directory Mode Creation Mask: -
                Share Comment: -
                    Share ACL: Everyone / Full Control
File Attribute Cache Lifetime: -
                  Volume Name: data
                Offline Files: manual
Vscan File-Operations Profile: standard

Related information