I tried like this after searching for it in the forums....
I=`grep 'I.P. Address' /install/cfgdist/`uname -n`.cfg | cut -d : -f 2 | cut -d . -f 1-3 |
sed s/" "//g`
But its giving the error as:
abhi

ts/39:[~] 183) ./abhi
./abhi: .cfg: not found
./abhi: -n: not found
Exit 1
If I run it on shell its working
abhi

ts/39:[~] 185) grep 'I.P. Address' /install/cfgdist/`uname -n`.cfg
| cut -d : -f 2 | cut -d . -f 1-3 |
sed s/" "//g
172.174.158
Please can someone help
Regards,
Abhi