This section contains the following topics:
Cannot Assign IP address by Using the ipadm create-addr command
Error Message: cannot create address object: Invalid argument provided
Error Message: cannot create address: Persistent operation on temporary object
With the traditional ifconfig command that is used for network configuration in previous Oracle Solaris releases, you could plumb and assign an IP address by using a single command. In this Oracle Solaris release, you use the ipadm command to configure both IP interfaces and IIP addresses.
The following example assumes that a static IP address is being assigned to an interface. This process involves two steps. First, create or plumb the IP interface by using the ipadm create-ip command. Then, assign an IP address to the interface by using the ipadm create-addr command:
# ipadm create-ip interface # ipadm create-addr -T addr-type -a address addrobj
This error message is displayed during IP address configuration.
The address object identifies a specific IP address that is bound to an IP interface. The address object is a unique identifier for each IP address on the IP interface. You must specify a different address object to identify a second IP address that you assign to the same IP interface. If you want to use the same address object name, you must delete the first address object instance before assigning it to a different IP address.
Use one of the following methods:
Specify a different address object to identify a second IP address as follows:
# ipadm show-addr ADDROBJ TYPE STATE ADR lo0 static ok 127.0.0.1/10 net0/v4 static ok 192.0.2.1 # ipadm create-addr -T static -a 192.0.2.5 net0/v4b # ipadm show-addr ADDROBJ TYPE STATE ADR lo0 static ok 127.0.0.1/10 net0/v4 static ok 192.0.2.1 net0/v4b static ok 192.0.2.5
Delete the first instance of the address object, then assign the same address object to a different IP address, as follows:
# ipadm show-addr ADDROBJ TYPE STATE ADR lo0 static ok 127.0.0.1/8 net0/v4 static ok 192.0.2.1 # ipadm delete-addr net0/v4 # ipadm create-addr -T static -a 192.0.2.5 net0/v4 # ipadm show-addr ADDROBJ TYPE STATE ADR lo0 static ok 127.0.0.1/8 net0/v4 static ok 192.0.2.5
This error message is displayed during IP interface configuration.
By default, you use the ipadm command to create persistent network configuration. If the IP interface that you are configuring was created as a temporary interface, you cannot use the ipadm command to configure persistent settings on that interface. After verifying that the interface you are configuring is temporary, delete the interface and recreate it persistently. You can then resume configuring the interface as follows:
# ipadm show-if -o all IFNAME CLASS STATE ACTIVE CURRENT PERSISTENT OVER lo0 loopback ok yes -m46-v------ 46-- -- net0 ip ok yes bm4--------- ---- --
The absence of a 4 flag for an IPv4 configuration or a 6 flag for an IPv6 configuration in the PERSISTENT field indicates that net0 was created as a temporary interface.
# ipadm delete-ip net0 # ipadm create-ip net0 # ipadm create-addr -T static -a 192.0.2.10 net0/v4 ipadm: cannot create address: Persistent operation on temporary object