Displaying 2 results from an estimated 2 matches for "checketh0".
2009 Dec 15
2
Define an alias with an embeded awk command
Hi ,all :
I'm trying to define an alias with an embeded awk command:
alias checketh0 `ifconfig eth0 |grep 'inet addr:' |awk '{prinrt $2}' |cut
-c 6- `
After I edit it in the .cshrc file and run "source .cshrc" , I run the
"checketh0" command in the terminal ,
the screen displays the "192.168.7.24: Command not found "
Why does is i...
2010 Mar 06
1
Define an alias with an embeded awk command error ?
Hi, guys:
I'm trying to define an alias in .cshrc with the embeded awk command,
like this :
alias checketh0 "ip add ls eth0 |awk '/inet/{print $2}' |sed -n '1p' "
Then i run "source ~/.cshrc" and run "checketh0" command in the terminal ,
but the result is the following :
" inet 192.168.18.18/24 brd 192.168.18.255 scope global eth0"
but i want...