nwamd(1M) System Administration Commands nwamd(1M)
nwamd - network auto-magic daemon
nwamd is a system daemon to manage network interfaces.
This daemon is started automatically and should not be invoked directly. It does not constitute a programming interface.
Whether this daemon is enabled or not depends on your installation medium. To check from within the GNOME desktop environment, double click
on the "Network Manager" icon to open the "Connection Properties" window. If "Configure network automatically" is checked, then auto-magic
mode is enabled. To check from the command line, enter the following:
% svcs svc:/network/physical
Two instances will be listed, one online and the other disabled. If the "nwam" instance is online, then this daemon is running.
To switch between manual and auto-magic mode, you can use the Network Monitor applet available within the GNOME desktop environment. You
can also switch manually from the command line by entering:
% svcadm disable svc:/network/physical:default
% svcadm enable svc:/network/physical:nwam
To go from auto-magic mode to manual mode:
% svcadm disable svc:/network/physical:nwam
% svcadm enable svc:/network/physical:default
When switching modes like this, keep in mind that all network interfaces will be brought down then back up. Therefore, if a different IP
address is configured in this process, existing applications and sessions might be disrupted.
There is a limitation that only one link is active at a time in auto-magic mode. This mode is not recommended for machines that use more
than one link at a time. For machines with wired and wireless links, wired link are preferred by default, although this can be adjusted
from the GNOME NWAM Manager menu (right-click on the icon), or from the command line, by editing the plain text file /etc/nwam/llp. For
the latter (hand-editing) procedure, the first instance of a link in /etc/nwam/llp sets the priority of that link. Subsequent instances of
that link set parameters associated with the interface on that link.
The /etc/nwam/llp interface is volatile and might change in a future release.
Static IP Addresses
A static IP address can be configured by changing the line in the /etc/nwam/llp file that contains an interface name and the name of the
method for obtaining an IP address. It might look like:
Change this line to one that looks like:
nge0 static I1.I2.I3.I4/P
...where the I's are the digits of the IPv4 address and the P is an optional prefix. If the prefix is not provided, it is derived, using
IPv6 is configured by default on a link. It can also be explicitly added in the /etc/nwam/llp file by providing a line that contains an
interface name and the string ipv6. It might look like:
If IPv6 should not be plumbed on a given link, a noipv6 entry should be created in the /etc/nwam/llp file for that link. It might look
An optional static IPv6 address can be provided on the same line, immediately after the ipv6 token. Whether you provide a static address or
not, IPv6 will use DHCPv6 or stateless address configuration, as directed by the local network configuration.
All interfaces listed in this section are volatile and may change in a future release. They are documented here so that those wishing to
experiment with this may do so.
Profiles are a mechanism for making multiple related changes to the system configuration after IP service is available.
There is no direct support for the profiles yet, but a "roll your own" mechanism is provided for now. Once an interface is brought up and
an IP address is configured for it, the daemon looks for the file /etc/nwam/ulp/check-conditions. If this file exists and is executable, it
is run. This should print a single line of output, which is the name of the profile that the user wishes to activate based on the current
conditions. If such a line is read successfully (foo in this example), then /etc/nwam/ulp/foo/bringup is executed. Likewise, when the
interface gets torn down for whatever reason, /etc/nwam/ulp/foo/teardown is executed. The "bringup" and "teardown" scripts are invoked via
pfexec(1) with default basic privileges. Samples for each of these scripts can be found at:
If no wired link is available, a scan for wireless LANs is done, and the resulting list offered via a GUI popup window prompts the console
user to select a preference. If a successful connection is made, the WLAN in question is stored in the plain text file
/etc/nwam/known_wifi_nets and the daemon may connect to any WLAN in that list without prompting the user again. If a user wishes to add
other preferences or revoke existing ones, he can do so by bringing up the NWAM Manager menu with right-click on the icon, and then select-
ing "Manage Favorite Wireless Networks...". A user can also edit the known_wifi_nets file directly. This interface is volatile and might
change in a future release.
See attributes(5) for descriptions of the following attributes:
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
|Availability |SUNWcsr |
|Interface Stability |Volatile |
svcs(1), svcadm(1M), attributes(5), smf(5)
See also nwam-manager(1M), available in the JDS/GNOME man page collection.
The networking service is managed by the service management facility, smf(5), under the service identifier:
Administrative actions on this service, such as enabling, disabling, or requesting restart, can be performed using svcadm(1M). The ser-
vice's status can be queried using the svcs(1) command.
SunOS 5.11 24 Nov 2008 nwamd(1M)