|Skip Navigation Links|
|Exit Print View|
|Transitioning From Oracle Solaris 10 to Oracle Solaris 11 Oracle Solaris 11 Information Library|
Automatic network configuration is made up of a collection of properties that determine how the network is configured, depending on current network conditions. Configuration information is associated with several different types of profiles that are activated and deactivated by the system or by you. See Overview of NWAM Configuration in Oracle Solaris Administration: Network Interfaces and Network Virtualization.
An NCP configures network links and interfaces. A Location configures system-wide network settings, for example naming services and IPfilter settings. NCPs are made up of individual configuration objects that are called Network Configuration Units (NCUs). Each NCU represents a physical link or an interface that includes the properties that define the configuration for that particular link or interface, as shown in the output of the netcfg list command in the following example:
netcfg> select ncp myncp netcfg:ncp:myncp:ncu:nge0> list ncu:nge0 type interface class ip parent "myncp" enabled true ip-version ipv4,ipv6 ipv4-addrsrc dhcp ipv6-addrsrc dhcp,autoconf . . .
User-defined NCPs and Locations are created by using the netcfg command, either in command-line mode or interactively. For example, you would create a new NCP called myncp by using the netcfg command interactively as follows:
$ netcfg netcfg> create ncp myncp
You can configure network settings for an NCP when you create it, or you can configure or reconfigure network settings for an existing NCP by using the nefcfg select command either in command-line mode or interactively, as shown in the following example.
Example 7-6 Configuring a Static IP Address for an existing NCP
In the following example, the netcfg command is used interactively to select the newly created NCP, myncp, then a static IP address is configured for this NCP.
netcfg> select ncp myncp netcfg:ncp:myncp:ncu:nge0> list ncu:nge0 type interface class ip parent "myncp" enabled true ip-version ipv4,ipv6 ipv4-addrsrc dhcp ipv6-addrsrc dhcp,autoconf netcfg:ncp:myncp:ncu:nge0> set ipv4-addrsrc=static netcfg:ncp:myncp:ncu:nge0> set ipv4-addr=22.214.171.124/24 netcfg:ncp:myncp:ncu:nge0> set ipv4-default-route=126.96.36.199 netcfg:ncp:myncp:ncu:nge0> end Committed changes netcfg:ncp:myncp>
Example 7-7 Enabling an NCP
In the following example, a user-defined NCP named myncp is enabled by using the netadm command.
$netadm enable -p myncp Enabling ncp 'myncp' $
System-wide network configuration, for example, naming services configuration, is managed in the Location profile. Properties are configured by using the netcfg command. The Automatic Location profile allows the system to automatically configure naming services. The Automatic Location profile is used to configure DNS through DHCP only. Note that the Automatic Location is different than the Automatic NCP, which configures link and IP interfaces. Before configuring naming service properties in a Location, you need to update the file that is to be referenced by the nameservices-config-file property of the specified Location. This file can be stored anywhere on the system. However, do not use the /etc/nsswitch.conf file name, as this file is overwritten.
For example, you can create a new Location profile and then configure NIS as follows:
$ netcfg netcfg> create loc officeloc Created loc 'officeloc'. Walking properties ... activation-mode (manual) [manual|conditional-any|conditional-all]> conditional-all conditions> advertised-domain contains oracle.com nameservices (dns) [dns|files|nis|ldap]> nis nameservices-config-file ("/etc/nsswitch.dns")> /etc/nsswitch.nis nis-nameservice-configsrc [manual|dhcp]> dhcp nfsv4-domain> ipfilter-config-file> ipfilter-v6-config-file> ipnat-config-file> ippool-config-file> ike-config-file> ipsecpolicy-config-file> netcfg:loc:officeloc> end Committed changes netcfg>
In the following example NIS is configured for an existing location.
$ netcfg> select loc origloc netcfg:loc:origloc> set nameservices=dns,nis netcfg:loc:origloc> set nis-nameservice-configsrc=manual netcfg:loc:origloc> set nis-nameservice-servers="188.8.131.52.184.108.40.206" netcfg:loc:origloc> set default-domain="org.company.com" netcfg:loc:origloc> set nameservices-config-file="/etc/nsswitch.dns" netcfg:loc:origloc> end Committed changes netcfg> exit
Automatic network configuration mode provides limited support for LDAP. Only LDAP anonymous mode works when in automatic mode. If you want to use an LDAP proxy or LDAP self modes and some form of security credentials you must first enable the DefaultFixed profile and manually configure your network. For instructions, see Chapter 12, Setting Up LDAP Clients (Tasks), in Oracle Solaris Administration: Naming and Directory Services.
You can manage automatic network configuration from the desktop by using the NWAM GUI. The tool is similar to using the netcfg and netadm commands. You can connect to wired or wireless networks, configure a new wired or wireless connection, create Location profiles, and activate or deactivate profiles.
Note that IP-related information is configured in the Network Profile, under Connections. If the Network Profile information is not displayed in the upper right-hand corner of the desktop, start the tool from the main menu by choosing System -> Administration -> Network Manager. See Chapter 6, About the NWAM Graphical User Interface, in Oracle Solaris Administration: Network Interfaces and Network Virtualization or the online help.