chgif Method
Purpose
Reconfigures an instance of a network interface.
Syntax
chgif [ -d | -T ] -l InterfaceInstance -a "Attribute=Value ..."
Description
The chgif method first modifies the database and then reconfigures the specified network interface instance (InterfaceInstance) by issuing a call to the ifconfig command. Only one interface can be changed per command invocation, and at least one attribute must be specified. This method is not normally used on the command line. Rather, it is called by high-level commands.
Note: The chgif method is a programming tool and it must not be run from the command line. The chdev command must be used to change the network interface, which invokes the chgif method internally.
Flags
Item | Description |
---|---|
-a"Attribute=Value ..." | Specifies pairs of attributes and values that
configure the Interface instance. The AttributeValue pairs
must be surrounded by quotes. Valid attribute values are as follows:
|
|
|
When the level of security is defined as none or unclassified, no IP Option header is added to the IP header. |
|
|
|
When more than one level of authority is specified, the values are separated by commas without embedded spaces. |
|
|
|
-d | Specifies that changes are made only in the configuration database. Changes take effect at the next system restart. |
-l InterfaceInstance | Specifies the instance of the network interface to be reconfigured. |
-T | Makes a temporary change in the device without the change being reflected in the database. It is temporary in that the device reverts to the characteristics described in the database when the system is restarted. |
Examples
- To add the netaddr=10.3.4.2 Object Data Manager (ODM) entry to
the en2 standard Ethernet network interface with netmask=255.255.255.0,
enter the following command:
A message that is similar to the following example is displayed:chdev -l en2 -a netaddr=10.3.4.2 -a netmask=255.255.255.0
en2 changed
- To add the alias4=10.3.4.3 ODM entry to the en2 standard Ethernet
network interface, enter the following command:
A message that is similar to the following example is displayed:chdev -l en2 -a alias4=10.3.4.3,255.255.255.0
en2 changed
- To delete the alias4=10.3.4.3 ODMentry from the en2 standard Ethernet
network interface, enter the following command:
A message that is similar to the following example is displayed:chdev -l en2 -a delalias4=10.3.4.3
en2 changed
- To add the netaddr6=fe80::20b4:40ff:fe00:f012 ODM entry to the
en2 standard Ethernet network interface with prefixlen=64, enter the
following command:
A message that is similar to the following example is displayed:chdev -l en2 -a netaddr6=fe80::20b4:40ff:fe00:f012 -a prefixlen=64
en2 changed
- To add the alias6=fe80::20b4:40ff:fe00:f016/64 ODM entry to the
en3 standard Ethernet network interface, enter the following command:
A message that is similar to the following example is displayed:chdev -l en3 -a alias6=fe80::20b4:40ff:fe00:f016/64
en3 changed
- To delete the alias6=fe80::20b4:40ff:fe00:f016/64 ODM entry from
the en3 standard Ethernet network interface, enter the following command:
A message that is similar to the following example is displayed:chdev -l en3 -a delalias6=fe80::20b4:40ff:fe00:f016/64
en3 changed