LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 05-03-2011, 04:34 AM   #1
tank junior
Member
 
Registered: Apr 2010
Posts: 42

Rep: Reputation: 0
sys/class/net/ethx/type What is it?


To get info of all etherhet adapters I am using C as well as info from various files in /sys/class/net/ethx directory.

There is a file name 'type' and has a number in it. Is it physical medium type of ethernet adapter? If yes, then how do I get string representation of that number? If no, then How do I determine physical medium type of ethernet adapter. For example 802.3, 802.5 etc.

Prashant
 
Old 05-03-2011, 08:23 PM   #2
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,758

Rep: Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643Reputation: 643
I don't know the exact answer but I'd probably try reading up on sysfs, maybe this link will help: http://www.kernel.org/pub/linux/kern...005/mochel.pdf

cheers
 
  


Reply

Tags
ethernet


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Need details on the classes available in the /sys/class folder on RHEL and SuSE. PrasannaKumariMS Linux - General 1 05-03-2011 10:49 AM
/sys/class/net/ Is this is the correct place for eth info tank junior Linux - Newbie 1 04-14-2011 02:58 AM
[SOLVED] C++ Initialize Class Member Variables of Another Class Type mirlin510 Programming 9 04-13-2011 11:46 AM
/sys/class/hwmon Question Aztral Linux - General 1 08-11-2009 02:00 PM
HowTo Run a script on ifup ethX and a different one for ifdown ethX dscholl Red Hat 3 07-07-2009 01:09 PM


All times are GMT -5. The time now is 01:32 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration