delete share command

Samba 2.2.0 introduced the ability to dynamically add and delete shares via the Windows NT 4.0 Server Manager. The delete share command is used to define an external program or script which will remove an existing service definition from smb.conf.
In order to successfully execute the delete share command, smbd requires that the administrator connects using a root account (i.e. uid == 0) or has the SeDiskOperatorPrivilege. Scripts defined in the delete share command parameter are executed as root.
When executed, smbd will automatically invoke the delete share command with two parameters.
configFile - the location of the global smb.conf file.
shareName - the name of the existing service.
This parameter is only used to remove file shares. To delete printer shares, see the .

Example: /usr/local/bin/delshare

Supported on: At least Microsoft Windows 7 or Windows Server 2008 family

delete share command

Registry HiveHKEY_LOCAL_MACHINE
Registry PathSoftware\Policies\Samba\smb_conf\delete share command
Value Namedelete share command
Value TypeREG_SZ
Default Value

samba.admx

Administrative Templates (Computers)