The easiest way to find the ip address of an interface is to read /etc/sysconfig/network-scripts/ifcfg-xxx. Where xxx is the interface name(eth0, for eg). You can also get the ip address using ioctl.
Regards
bhaskar
At 12:37 PM 6/12/03 +0200, you wrote:
Hi,
This may or may not be kernel hacking related, but how do I
programmatically find the IP address of an interface?
Thanks,
jules
--
Jules Colding <JuBColding@yorkref.com>
York Refrigeration
--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive: http://mail.nl.linux.org/kernelnewbies/
FAQ: http://kernelnewbies.org/faq/
responsible for whatsoever.
------------------------------------------------------------------------
V. Bhaskar
Rendezvous On Chip (i) Pvt Ltd
Hyderabad, India
Ph: +91-40-2335 1214 / 1175 / 1184
ROC home page <http://www.roc.co.in>