By default, the DHCPv4 client does not supply its own host name because the client expects the DHCP server to supply the host name. The DHCPv4 server is configured to supply host names to DHCPv4 clients by default. When you use the DHCPv4 client and server together, these defaults work well. However, when you use the DHCPv4 client with some third-party DHCP servers, the client might not receive a host name from the server. If the dhcpagent daemon does not receive a host name through the DHCP service, the daemon checks the value that is set in the config/nodename property in the svc:/system/identity:node service for a name to use as the host name. If the file is empty, the host name is set to unknown.
If the DHCP server supplies a name in the DHCP Hostname option , the DHCP client uses that host name, even if a different value is placed in the value that is set in the config/nodename property in the svc:/system/identity:node service. If you want the DHCP client to use a specific host name, you can enable the client to request that name. See the following procedure.
The following procedure does not work with all DHCP servers because the DHCP server does not have to respect a request for a specific host name and many do not. In some cases, they simply return a different name.
Assume a role that can grant the DHCP Management profile to users. If the DHCP Management profile has not been assigned to a user, assume the root role.
Roles contain authorizations and privileged commands. For more information about roles, see Creating a Role in Securing Users and Processes in Oracle Solaris 11.3. For more information about the DHCP Management profile, see How to Grant User Access to DHCP Commands.
# ipadm create-ip interface
# ipadm delete-addr -r DHCP-addrobj
# ipadm create-addr -T dhcp -h hostname DHCP-addrobj