Manual page for IFCONFIG(8C)
ifconfig - configure network interface parameters
is used to assign an address
to a network interface and/or to configure
network interface parameters.
must be used at boot time to define the network address
of each interface present on a machine; it may also be used at
a later time to redefine an interface's address
or other operating parameters.
Used without options,
displays the current configuration for a network interface.
If a protocol family is specified,
will report only the details specific to that protocol family.
Only the super-user may modify the configuration
of a network interface.
parameter is a string of the form
Three special interface names,
are reserved and refer to all or a subset
of the interfaces in the system.
If one of these interface names is given, the commands following it are applied
to all of the interfaces that match:
Apply the commands to all interfaces in the system.
Apply the commands to all ``down'' interfaces in the system.
Apply the commands to all ``up'' interfaces in the system.
Since an interface may receive transmissions in differing protocols,
each of which may require separate naming schemes, the parameters and
addresses are interpreted according to
the rules of some address family,
specified by the
parameter. The address families currently supported are
ether and inet.
If no address family is specified,
the address is either a host name present in the host name data
or in the
Network Information Service
address expressed in the Internet standard
Typically, an Internet address specified in dot notation
will consist of your system's network number and the machine's
unique host number.
A typical Internet address is
is the network number and
is the machine's
the address is an Ethernet address represented as
is a hexadecimal number between 0 and ff.
Only the super-user may use the
parameter is supplied in addition to the
parameter, it specifies the address of
the correspondent on the other end
of a point to point link.
Mark an interface ``up''.
This happens automatically when setting the
first address on an interface.
enables an interface after an
reinitializing the hardware.
Mark an interface ``down''. When an interface is
marked ``down'', the system will not attempt to
transmit messages through that interface.
If possible, the interface will be reset to disable reception as well.
This action does not automatically disable routes using the interface.
This flag used to cause a non-standard encapsulation of inet packets
on certain link levels.
Sun drivers no longer use this flag, but it is ignored for compatibility.
Disable the use of a ``trailer'' link level encapsulation.
Enable the use of the Address Resolution Protocol in mapping
between network level addresses and link level addresses (default).
This is currently implemented for mapping between
addresses and 10Mb/s Ethernet addresses.
Disable the use of the Address Resolution Protocol.
that the interface should not be advertised.
Specify unadvertised interfaces.
Use the Reverse Address Resolution Protocol (RARP) to automatically
acquire an address for this interface. Available beginning
with SunOS 4.1.1 Rev B.
- metric n
Set the routing metric of the interface to
The routing metric is used by the routing protocol
Higher metrics have the effect of making a route
less favorable; metrics are counted as addition hops
to the destination network or host.
- netmask mask
Specify how much of the address to reserve for subdividing
networks into sub-networks.
The mask includes the network part of the local address
and the subnet part, which is taken from the host field of the address.
The mask can be specified as a single hexadecimal number
with a leading 0x, with a dot-notation address,
or with a pseudo-network name listed in the network table
The mask contains 1's for the bit positions in the 32-bit address
which are to be used for the network and subnet parts,
and 0's for the host part.
The mask should contain at least the standard network portion,
and the subnet field should be contiguous with the network
(plus sign) is given for the netmask value,
then the network number is looked up in the
(or in the
file if not running the
- broadcast address
Specify the address to use to represent broadcasts to the
The default broadcast address is the
address with a host part of all 0's.
(plus sign) given for the broadcast value causes the broadcast address to
be reset to a default appropriate for the (possibly new) address
Note that the arguments of
are interpreted left to right,
ifconfig -a netmask + broadcast +
ifconfig -a broadcast + netmask +
may result in different values being assigned for the interfaces'
If your workstation is not attached to an Ethernet, the
interface should be marked ``down'' as follows:
ifconfig ie0 down
To print out the addressing information for each interface, use
To reset each interface's broadcast address after the netmasks
have been correctly set, use
ifconfig -a broadcast +
Messages indicating the specified interface does not exist, the
requested address is unknown, or the user is not privileged and
tried to alter an interface's configuration.
The network information service
was formerly known as Sun Yellow Pages
The functionality of the two remains the same;
only the name has changed.
Created by unroff & hp-tools.
© by Hans-Peter Bischof. All Rights Reserved (1997).
Last modified 21/April/97