Technical data
ifconfig
ifconfig
Assigns an address to a network interface, and configures and displays network
interface parameters.
Format
ifconfig interface_id [address_family][address[/bitmask]] [dest_address][parameters]
ifconfig -a [-d] [-u] [-v] [address_family]
ifconfig -l [-d] [-u] [-v] [address_family]
ifconfig [-v] interface-id [address_family]
Description
Use the
ifconfig
command to define the network address of each interface. You
can also use the
ifconfig
command at other times to display all interfaces that
are configured on a system, to redefine the address of an interface, or to set other
operating parameters.
Note
If you want to redefine the interface address or the net mask, you should
stop TCP/IP Services. Otherwise, any TCP/IP process currently running
will continue to use the old address and net mask and will fail.
Any user can query the status of a network interface; only a privileged user can
modify the configuration of network interfaces.
You specify an interface with the
ifconfig interface-id
syntax. (See your
hardware documentation for information on obtaining an interface ID.)
If you specify only interface-id, the
ifconfig
program displays the current
configuration for the specified network interface only.
If a protocol family is specified by the address_family parameter,
ifconfig
reports
only the configuration details specific to that protocol family.
When changing an interface configuration, if the address family cannot be
inferred from the address parameter, an address family must be specified. The
address family is required because an interface can receive transmissions in
different protocols, each of which can require a separate naming scheme.
The address parameter is the network address of the interface being configured.
For the
inet
address family, the address parameter is either a host name or an
IP address in the standard dotted-decimal notation with or without the optional
Classless Inter-Domain Routing (CIDR) bit mask (/bitmask). If you specify
bitmask, do not use the netmask parameter.
The destination address (dest_address) parameter specifies the address of the
correspondent on the remote end of a point-to-point link.
Troubleshooting Utilities Reference A–11