sharectl - configure and manage file sharing service
sharectl status [-h] [protocol]
sharectl get [-h] [-p property]... protocol
sharectl set [-h] [-p property=value]... protocol
The sharectl command operates on file-sharing protocols, such as NFS and SMB. The command sets the client and server operational properties, takes and restores configuration snapshots, and gets status of the protocol service.
The get and set subcommands (see below) require root privileges. An authorized user can use sharectl to set global values for NFS and SMB properties in the Solaris server management facility. See nfs(4) and smb(4).
Interaction with Location Profiles
The nfsmapid_domain property is managed in Location profiles (refer to netcfg(1M)) for more information about location profiles). These
profiles are either fixed, meaning the network configuration is being managed in the traditional way, or reactive, meaning the network configuration is being managed automatically, reacting to changes in the network environment according to policy rules specified in the profiles.
When a fixed location (there can currently be only one, the DefaultFixed location) is active, changes made to the SMF repository, including those made by sharectl, will be applied to the location when it is disabled, and thus will be restored if that
location is later re-enabled.
When a reactive location is active, changes should not be applied directly to the SMF repository; these changes will not be preserved in the location profile, and will thus be lost if the location is disabled, or if the system's network configuration, as managed by svc:/network/physical:default
and svc:/network/location:default, is refreshed or restarted. Changes should instead be applied to the location itself, using the netcfg(1M) command;
this will save the change to the location profile repository, and will also apply it to the SMF repository (if the change is made to the currently active location).
The nfsmapid_domain setting is stored in the nfsv4-domain property of a location profile.
The following options are supported:
Displays usage message.
Specifies a property. See “Subcommands,” below.
sharectl supports the subcommands described below. The form of a sharectl command is:
# sharectl subcommand [option]
get [–pproperty] protocol
Get the property values for the specified protocol. If no –p option is provided, get all the properties for the specified protocol.
set [–pproperty=value]... protocol
Set properties for the specified file sharing protocol.
Display status of the specified protocol, or, if no protocol is specified, of all file-sharing protocols.
Example 1 Getting Properties
The following command gets the properties for the NFS protocol.