2009-08-27 11 views

答えて

3

Linuxのbashのコマンドライン:

/sbin/ifconfig eth0 | grep 'inet addr' | cut -d: -f2 | cut -d ' ' -f1 | mail -s 'My IP address' [email protected] 
2

awkの代替のくつろぎのソリューション:

ifconfig eth0 | grep 'inet addr' | awk -F: '{print $2}' | awk -F' ' '{print $1}' | mail -s "My IP address" [email protected] 
0

これを行うウェブサイトがあります。 あなたが入力したメールアドレスにIPアドレスを送信します。 http://mmmip.com

関連する問題