Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number

Re: Re:**3 (rob_au) Getting net addy on localhost?

by Dogma (Pilgrim)
on Nov 27, 2001 at 10:36 UTC ( #127742=note: print w/replies, xml ) Need Help??

in reply to Re:**3 (rob_au) Getting net addy on localhost?
in thread Getting net addy on localhost?

That is incorrect, '/etc/sysconfig/network-scripts/ifcfg-*' is a RedHat-ism and isn't even portable between all linux distros. As far as I know there is no standard file between unix and unix-like systems for this information. You can try /etc/hosts but that will only give you resolvable interfaces. Parsing the output of '/sbin/ifconfig' is more likely to be portable. (not that portability is the goal here, but we don't know what system your running on) SNMP (if you have it running) would be another possible means of getting interfaces addresses.
  • Comment on Re: Re:**3 (rob_au) Getting net addy on localhost?

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://127742]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (2)
As of 2021-10-23 02:58 GMT
Find Nodes?
    Voting Booth?
    My first memorable Perl project was:

    Results (86 votes). Check out past polls.