Results 1 to 1 of 1
Enjoy an ad free experience by logging in. Not a member yet? Register.
- Join Date
- Oct 2009
How linux displays the network interfaces
1. When I do an ifconfig command I see the some interfaces, but when i give ifconfig -a command I see complete list of interfaces. How linux knows what interfaces is inactive and which is active device. Is have did some googling and got to know that /sys/class/net/lo/operstate is the file. Is my understanding true or linux does some other stuff to find that..
2. Also how ifconfig gets the full details.
Because I have write a method in our project to get the complete list of interfaces and their respective details like ip, gatway, route, arp table etc.. I dont want to shell command in the c program to get the dtails becoz i have to do a grep and hell of stuff is required.. I want to use thing like ioctl to get the details
Can anyone help me in that..
Thanks in advance..
Last edited by maheshgupta024; 12-09-2010 at 06:23 AM.