Skip Navigation Links | |
Exit Print View | |
Oracle Solaris Administration: Network Interfaces and Network Virtualization Oracle Solaris 11 Information Library |
1. Overview of the Networking Stack
Network Configuration in This Oracle Solaris Release
The Network Stack in Oracle Solaris
Network Devices and Datalink Names
Administration of Other Link Types
3. NWAM Configuration and Administration (Overview)
4. NWAM Profile Configuration (Tasks)
5. NWAM Profile Administration (Tasks)
Obtaining Information About Profile States
Displaying the Current State of a Profile
Performing a Wireless Scan and Connecting to Available Wireless Networks
Troubleshooting NWAM Network Configuration
Monitoring the Current State of All Network Connections
Troubleshooting Network Interface Configuration Issues
6. About the NWAM Graphical User Interface
Part II Datalink and Interface Configuration
7. Using Datalink and Interface Configuration Commands on Profiles
8. Datalink Configuration and Administration
9. Configuring an IP Interface
10. Configuring Wireless Interface Communications on Oracle Solaris
12. Administering Link Aggregations
16. Exchanging Network Connectivity Information With LLDP
Part III Network Virtualization and Resource Management
17. Introducing Network Virtualization and Resource Control (Overview)
18. Planning for Network Virtualization and Resource Control
19. Configuring Virtual Networks (Tasks)
20. Using Link Protection in Virtualized Environments
21. Managing Network Resources
User-defined NCPs, Location profiles, and ENMs all have activation-mode properties. The allowable values for each profile are determined by its type.
To manually enable or disable (activate or deactivate) a profile or configuration object, use the netadm enable command or the netadm disable command. Both system-defined and user-defined profiles can be enabled and disabled, if the activation-mode property for the specified profile is set to manual. The activation-mode property is set when you create or modify a profile by using the netcfg command. For more information, see How NWAM Profiles Are Activated.
At any given time, there must be one active NCP and one active Location profile on the system. Enabling a different NCP or location with an activation-mode of manual implicitly deactivates the currently active NCP or Location profile. The current location can also be deactivated, if its activation-mode property is set to manual. If no other locations are available, NWAM falls back to one of the system-defined locations, either the Automatic location, if IP configuration was successful, or the NoNet location. Conditional and system locations can be manually activated, which means that the location remains active until explicitly disabled. This behavior makes it easy to switch a conditional Location profile to “always on.” Disabling the conditional location switches the system back to its normal conditional behavior. When any location is manually enabled, the system does not change the location, even if a conditionally enabled location's conditions are met.
Note - You cannot explicitly disable the NCP that is currently active on a system, as that would effectively shut down the basic network connectivity of the system. An NCP is disabled implicitly when a different NCP is manually enabled. However, there are no constraints on ENM activation. Zero or more ENMs can be active on a system at any given time. Thus, enabling or disabling an ENM has no effect on other currently active ENMs.
You can also manually enable and disable individual NCUs. Note that the specified NCU must be part of the currently active NCP and must have an activation-mode property of manual. If the NCU class is not specified, all of the NCUs (one link NCU and one interface NCU with that name) are activated or deactivated.
Activation and deactivation of objects is performed asynchronously. Therefore, the request to enable or disable might succeed, while the action (activate or deactivate) fails. A failure of this sort is reflected in the profile's state, which changes to maintenance, indicating that the last action taken on the profile failed. For information about displaying the state of profiles, see Obtaining Information About Profile States.
Example 5-2 Enabling a Profile
The syntax to manually enable a profile is as follows:
netadm enable [ -p profile-type ][ -c ncu-class ] profile-name
If the profile name is not unique, for example, if there are multiple profiles with the same name, but of different types, are on the system, you must also specify the profile type.
The -p option can be used to specify one of the following profile types:
ncp
ncu
loc
enm
If the configuration object's type is ncu, the -c option can be used to distinguish the NCU class. The -c option is helpful when two NCUs with identical names are on the system.
If the -coption is used, it must specify either phys or ip class type.
In the following example, a location named office is enabled:
$ netadm enable -p loc office
where the profile-type is loc, and the profile-name is office. Note that the -c ncu-class option is not used in this example because the profile type is a location and not an NCP.
$ netadm enable -p ncp user Enabling ncp 'User' . . .
Note that when you specify profile names, the netadm command is case-insensitive.
Example 5-3 Disabling a Profile
The syntax to manually disable a profile is as follows:
netadm disable [ -p profile-type ][ -c ncu-class ] profile-name
If the profile name is not unique, you must also specify the profile type.
The -p option can be used to specify one of the following profile or object types:
ncp
ncu
loc
enm
If the configuration object's type is an ncu, the -c option must also be used to distinguish the NCU class.
The NCU class must be specified as either phys or ip.
For example, to manually disable a link NCU named net1, you would type the following command:
$ netadm disable -p ncu -c phys net1
where the profile-type is ncu, and the ncu-class is phys, and the profile-name is net1. Note that the -c ncu-class option is used in this example because the configuration object is an NCU.
Example 5-4 Switching Profiles
To change the active NCP and enable manual configuration, you would type the following command:
$ netadm enable -p ncp DefaultFixed
Similarly, to enable automatic (NWAM) configuration with the Automatic NCP, you would type the following command:
$ netadm enable -p ncp Automatic
For more information about netadm, see the netadm(1M) man page.