Bash get ethernet IP
Posted on February 28, 2013
Bash get ethernet IP
DEVICE="eth0"
IP='ip -4 a l dev $DEVICE | grep inet | awk `{ print $2 }`'
IP='echo ${IP///24}'
Bash get ethernet IP
DEVICE="eth0"
IP='ip -4 a l dev $DEVICE | grep inet | awk `{ print $2 }`'
IP='echo ${IP///24}'