Thread
:
how to show the servers IP address in a shell script ?
View Single Post
07-06-2005, 12:28 PM
etech
Confirmed User
Join Date: Feb 2004
Location: Right next to you....
Posts: 1,148
I got it, ifconfig eth0 |grep 'inet addr' |awk '{print $2}'
My main problem now is that I need to get that saved in a variable, and i cant do
VAR = ifconfig eth0 |grep 'inet addr' |awk '{print $2}'
echo $VAR
etech
View Public Profile
Find More Posts by etech