Apple Mac OS X Server Network Card User Manual


 
Chapter 6 Setting Network Preferences 71
Configuring a Network Interface
You can configure a network interface for TCP/IP using ifconfig. This tool is used to
bring the interface up or down and set the interface IP address and subnet mask.
To add an Ethernet interface to a bond virtual device (pseudo device):
$ ifconfig
bond_interface_name
bondev
physical_interface
The
bond_interface_name
is the name of the pseudo device and the
physical_interface
is the actual Ethernet interface you want to associate with the
pseudo device, for example, en0. If this is the first physical interface to be associated
with the bond interface, the bond interface inherits the Ethernet address from the
physical interface. Physical interfaces that are added to the bond have their Ethernet
address reprogrammed so that all members of the bond have the same Ethernet
address. If the physical interface is subsequently removed from the bond, a new
Ethernet address is chosen from the remaining interfaces, and all interfaces are
reprogrammed with the new Ethernet address. If no remaining interfaces exist, the
bond interface’s Ethernet address is cleared.
To remove an Ethernet interface from a bond virtual device (pseudo device):
$ ifconfig
bond_interface_name
-bondev
physical_interface
The link status of the bond interface depends on the state of link aggregation.
If no active partner is detected, the link status will remain inactive. To monitor the
IEEE 802.3ad Link Aggregation state, use the -b option.
See the ifconfig man page for more information.
Configuring Ethernet Link Aggregation
You can also use networksetup to configure Ethernet Link Aggregation. The following
commands are supported.
To display if the device can be added to a bond:
$ sudo networksetup -isBondSupported
device
To create a bond and add devices to it:
$ sudo networksetup -createBond
name
[
device1
] [
device2
] [...]
To delete a bond:
$ sudo networksetup -deleteBond
bond
To add a device to a bond:
$ sudo networksetup -addDeviceToBond
device
bond
To remove a device from a bond:
$ sudo networksetup -removeDeviceFromBond
device
bond
To list available bonds:
$ sudo networksetup -listBonds