On Wed, Jun 09, 2004 at 11:08:12AM +1000, James Sinnamon wrote:
Dear debian users,
Is there a utility to simply return the IP address of an interface, say
eth1 or ppp0? I need something that works like:
$ netutil eth0
144.133.251.117
... or is it necessary to use ifconfig something
Incoming from James Sinnamon:
Is there a utility to simply return the IP address of an interface, say
eth1 or ppp0? I need something that works like:
$ netutil eth0
144.133.251.117
#!/usr/bin/perl -w
use strict;
my ( $ip );
open ( IFC, /sbin/ifconfig | )
or die qq($0: failed opening
On Wed, Jun 09, 2004 at 11:08:12AM +1000, James Sinnamon wrote:
Dear debian users,
Is there a utility to simply return the IP address of an interface, say
eth1 or ppp0? I need something that works like:
$ netutil eth0
144.133.251.117
... or is it necessary to use ifconfig something
James Sinnamon wrote:
Dear debian users,
Is there a utility to simply return the IP address of an interface, say
eth1 or ppp0? I need something that works like:
$ netutil eth0
144.133.251.117
... or is it necessary to use ifconfig something like as follows:
$ ifconfig eth0 | sed ' ... ' | cut
4 matches
Mail list logo