chtcpip command
Purpose
Changes the Virtual I/O Server TCP/IP settings and parameters.
Syntax
To change a network interface:
chtcpip {-interface Interface -inetaddr Address -netmask SubnetMask}
chtcpip {-interface Interface -gateway -add New_gateway_address -remove OLD_gateway_address}
chtcpip {-ip6 -interface Interface -inetaddr Address -plen PrefixLen}
chtcpip {-ip6 -interface Interface -gateway -add New_gateway_address -remove OLD_gateway_address}
Description
The chtcpip command
changes the TCP/IP settings and configuration on the Virtual I/O Server.
Note: When the cluster is active, you cannot change the
IP configuration or gateway used for the cluster (shared storage pool)
communication.
Flags
Flag name | Description |
---|---|
-add New_Gateway_Address | Specifies the new default gateway address to add. |
-inetaddr Address | Changes the IP address of the host. |
-interface Interface | Specifies a particular network interface, for example en0. |
-ip6 | Specifies to use the IPv6 version of this command. The -ip6 flag allows the user to change an existing IPv6 address, state, prefix length, and default gateway. |
-gateway Gateway | Changes the gateway address for a static route. |
-netmask SubnetMask | Specifies the subnet mask of the gateway, which is used to route through the appropriate subnetwork. |
-plen prefixLen | Specifies the prefix length of the IPv6 interface. |
-remove Old_Gateway_Address | Specifies the old default gateway address to remove. |
Exit Status
Examples
- To change the current network address and mask to the new settings,
type the command as follows:
chtcpip -interface en0 -inetaddr 9.1.1.1 -netmask 255.255.255.0
- To change the default gateway from 9.1.2.3 to 9.2.3.4, type:
chtcpip -interface en0 -gateway -add 9.2.3.4 -remove 9.1.2.3
- To change the current IPv6 network address and
prefix length for an interface, type the command as follows:
chtcpip -ip6 -interface en0 -inetaddr 2001:1:1:1::9 -plen 64
- To change the IPv6 gateway address for a static
route, type the command as follows:
chtcpip -ip6 -interface en0 -gateway -add 2001:1:1:1::2 -remove 2001:1:1:1::1
Note: If you attempt to change the gateway for
an interface when it is in use for the cluster communication, by typing
the following command:
chtcpip -interface en0 -gateway -add 9.126.86.1 -remove 9.126.88.1
The
system displays the following error message with return code 78:
The requested operation is not allowed because partition is a member of "test_cluster" cluster.
Interface being used is "en0" ("inet" Family) for cluster communication.