Network Appliance(TM)

Manual Pages


Table of Contents

NAME

ifconfig - configure network interface parameters

SYNOPSIS

ifconfig interface [ [ alias | -alias ] address ] [ netmask mask ] [ broadcast address ] [ mediatype type ] [ mtusize size ] [ up | down ] [ trusted | untrusted ]

ifconfig -a

DESCRIPTION

ifconfig is used to assign an address to a network interface and configure network interface parameters. ifconfig 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. When used without optional parameters, ifconfig displays the current configuration for a network interface.

The interface parameter is the name of the network interface. On EISA-based machines, that name is of the form nsn for Ethernet interfaces and fin for FDDI interfaces, where n is that interface's ordinal number (e.g., the first Ethernet interface is ns0, the second is ns1, etc.). On PCI-based machines, that name is of the form en for Ethernet interfaces, fn for FDDI interfaces, and an for ATM interfaces, possibly followed by a letter, where n is 0 for on-board interfaces and the expansion slot number for interfaces plugged into expansion slots. If a card in an expansion slot has more than one interface, the interface name will be followed by a letter between a and z indicating which of the interfaces on that card it is. The interface name vh is used to specify IP virtual host addresses associated with the filer. Only alias addresses (using the alias option) may be assigned to the vh interface. The interface name -a is special and it does not take any optional parameters. It displays the current configuration for all the network interfaces present.

The address is either a host name present in the host name data base /etc/hosts or an Internet address expressed in the Internet standard dot notation.

OPTIONS

broadcast address
Specifies the address to use to represent broadcasts to the network. The default broadcast address is the address with a host part of all 1's.

down
Marks 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.

mediatype type Specifies the Ethernet media type used. Depending on the physical specifications of the Ethernet card the acceptable types are "thick" (10Base5 AUI), "thin" (10Base2 BNC), "tp" (10Base-T RJ-45 twisted-pair), or "tpfd" (Full duplex 10Base-T RJ-45 twistedpair), or "100tx" (100Base-T RJ-45 twistedpair), or "100tx-fd" (Full duplex 100Base-T RJ-45 twisted-pair), or "auto" (Auto RJ-45 twisted-pair). The default media type is set to "tp" or to "auto" where applicable.

On a 10/100 Mbps auto-negotiable interface, the system will auto-negotiate a 10 Mbps half or full duplex or 100 Mbps half or full duplex link and set the interface accordingly when it is configured up. If the other end does not support auto-negotiation and full duplex operation is desired, it must be explicitly set using the mediatype command.

On a 10/100 Mbps interface, the system will auto-detect a 10 Mbps or 100 Mbps link and set the link speed accordingly when the interface is configured up. The hardware is not currently capable of auto-detecting full duplex interfaces, so if full duplex operation is desired, it must be explicitly set using the mediatype command. Only the 10/100 Mbps interfaces are capable of full duplex operation.

mtusize size
Specifies the MTU (maximum transmission unit) to use for the interface. This is normally necessary only for non-compliant FDDI or ATM bridges, routers or switches that don't know how to fragment FDDI or ATM size packets.

netmask mask
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 Internet address, or with a pseudo-network name listed in the network table /etc/networks. The mask contains 1's for the bit positions in the 32-bit address that 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 portion. A default netmask is chosen according to the class of the IP address.

up
Marks an interface "up". This may be used to enable an interface after an "ifconfig down." It happens automatically when setting the first address on an interface. If the interface was reset when previously marked down, the hardware will be reinitialized.

alias
Establishes an additional network address for this interface. This is sometimes useful when changing network numbers and one wishes to accept packets addressed to the old interface. It is required when creating IP virtual host addresses.

-alias
Remove a network address for this interface.

trusted
Specifies that the network to which the interface is attached is trusted relative to firewall-style security (default).

untrusted
Specifies that the network to which the interface is attached is not trusted relative to firewall-style security.

FILES

/etc/hosts
host name data base
/etc/networks
network name data base

SEE ALSO

na_hosts(5), na_networks(5)


Table of Contents