使用 %w 和 %d 变量创建主目录配置
可使用 %w 和 %d 变量创建主目录配置。用户即可连接到其使用动态创建共享的主共享。
示例
以下示例中的命令会通过以下设置创建主目录配置:
- 共享名称为 %w。 
- 主目录相对路径为 %d/%w。 
- 用于包含主目录的搜索路径, /home1,是以 NTFS 安全模式配置的卷。
- 配置创建于 SVM vs1。
用户从 Windows 主机访问其主目录时,可使用此类主目录配置。用户从 Windows 和 Linux 主机访问其主目录时,也可使用此类型配置,并且文件系统管理员会使用基于 Windows 的用户和组来控制对文件系统的访问。
cluster::> vserver cifs share create -vserver vs1 -share-name %w 
-path %d/%w -share-properties oplocks,browsable,changenotify,homedirectory
cluster::> vserver cifs share show -vserver vs1 -share-name %w
                      Vserver: vs1
                        Share: %w
     CIFS Server NetBIOS Name: VS1
                         Path: %d/%w
             Share Properties: oplocks
                               browsable
                               changenotify
                               homedirectory
           Symlink Properties: enable
      File Mode Creation Mask: -
 Directory Mode Creation Mask: -
                Share Comment: -
                    Share ACL: Everyone / Full Control
File Attribute Cache Lifetime: -
                  Volume Name: -
                Offline Files: manual
Vscan File-Operations Profile: standard
cluster::> vserver cifs home-directory search-path add -vserver vs1 ‑path /home1
cluster::> vserver cifs home-directory search-path show
Vserver     Position Path
----------- -------- -----------------
vs1         1        /home1
提供反馈