|Skip Navigation Links|
|Exit Print View|
|man pages section 4: File Formats Oracle Solaris 11.1 Information Library|
- specify host's domain name
The service svc:/network/nis/domain determines a host's domain name for direct use by the NIS name service. For the purposes of backwards compatibility, the service also generates the defaultdomain file.
The property group/property config/domainname represents the NIS domainname represented by /etc/defaultdomain.
The contents of defaultdomain consists of a single line containing a host's domain name.
The defaultdomain 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 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 defaultdomain setting is stored in the default-domain property of a location profile.
Example 1 Setting Up domainname and Enabling the nis/domain Service
The following example sets up domainname and enables the nis/domain service:
% svccfg -s nis/domain setprop config/domainname = \ hostname: nisdomain.example.com % svccfg -s nis/domain:default refresh % svcadm enable nis/domain
The service is not enabled by default. The nis/domain service sets up all the shared NIS configuration, of which domainname is the one mandatory configuration parameter.
The defaultdomain file is created and modified by Oracle Solaris installation and configuration scripts. Only users knowledgeable of name service configuration should edit the file.