ONTAP 9

to Japanese version

Create an SMB share

You must create an SMB share before you can share data from an SMB server with SMB clients. When you create a share, you can set share properties, such as designating the share as a home directory. You can also customize the share by configuring optional settings.

Before you begin

The directory path for the volume or qtree must exist in the SVM namespace before creating the share.

About this task

When you create a share, the default share ACL (default share permissions) is Everyone / Full Control. After testing access to the share, you should remove the default share ACL and replace it with a more secure alternative.

Steps
  1. If necessary, create the directory path structure for the share.

    The vserver cifs share create command checks the path specified in the -path option during share creation. If the specified path does not exist, the command fails.

  2. Create an SMB share associated with the specified SVM: vserver cifs share create -vserver vserver_name -share-name share_name -path path [-share-properties share_properties,...] [other_attributes] [-comment text]

  3. Verify that the share was created:vserver cifs share show -share-name share_name

Examples

The following command creates an SMB share named “SHARE1” on SVM vs1.example.com. Its directory path is /users, and it is created with default properties.

cluster1::> vserver cifs share create -vserver vs1.example.com -share-name SHARE1 -path /users

cluster1::> vserver cifs share show -share-name SHARE1

Vserver          Share    Path     Properties Comment  ACL
---------------  -------- -------- ---------- -------- -----------
vs1.example.com  SHARE1   /users   oplocks    -        Everyone / Full Control
                                   browsable
                                   changenotify
                                   show-previous-versions
Top of Page