//Check current ip configuration status
# dladm show-phys
# ipadm show-if
# ipadm show-addr
//Check the interfaces name
# dladm show-phys
— output Example —
LINK MEDIA STATE SPEED DUPLEX DEVICE
net0 Ethernet up 1000 full e1000g0 –> Attentiom to this line
net1 Ethernet unknown 0 unknown pcn0
===============================================================================================
# ipadm create-ip net0
//Check status
# ipadm show-if
— output Example —
IFNAME CLASS STATE ACTIVE OVER
lo0 loopback ok yes —
net0 ip down no —
//Set IP static
— Template —
# ipadm create-addr -T static -a / /v4static
— Example —
# ipadm create-addr -T static -a 10.163.198.20/24 net0
===============================================================================================
//Check status
# ipadm show-if
— output Example —
IFNAME CLASS STATE ACTIVE OVER
lo0 loopback ok yes —
net0 ip ok yes —
//Check again
# ipadm show-addr
— Exmple —
ADDROBJ TYPE STATIC ADDR
lo0/v4 static ok 127.0.0.1/8
net0/v4 static ok 10.163.198.20/24
lo0/v6 static ok ::1/128
===============================================================================================
// add a persistent default route:
# route -p add default
— OR —