LinuxQuestions.org
Register a domain and help support LQ
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 06-15-2010, 04:21 PM   #1
hoorah928
LQ Newbie
 
Registered: Jun 2010
Posts: 2

Rep: Reputation: 0
Location of standard interface flags on SUSE


Hi,

I am reporting various network statistics in a c++ program by reading the values out of /proc. However, I am having trouble determining the link status. In particular, I am wondering:

1. How are the standard interface flags (IFF_UP, IFF_RUNNING) as referenced in if.h accessed from user land? The ifconfig man page lists its files as

/proc/net/socket (doesn't exist in suse), /proc/net/dev, and /proc/net/if_inet6. None of these seem to contain these flags.

2. ip link show reports a "NO-CARRIER" flag. How does this correlate with the "UP" and/or "RUNNING" flags as reported by ifconfig, and how is it accessed from user space?

Any help is appreciated.

Thanks in advance.
 
Old 07-08-2010, 06:15 PM   #2
hoorah928
LQ Newbie
 
Registered: Jun 2010
Posts: 2

Original Poster
Rep: Reputation: 0
For anyone who is wondering, /sys/class/net/[NIC]/carrier has the information I was looking for in #2.
 
  


Reply

Tags
flags, proc, suse


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
ioctl() and changing network interface flags Kesem Linux - Networking 1 09-01-2009 11:16 PM
eth0: ERROR while getting interface flags: No such device w1k0 Slackware 8 10-18-2008 07:34 PM
Cannot get interface flags: Invalid argument nasim751 Linux - Software 1 04-21-2008 07:20 PM
Cannot get interface flags: Invalid argument nasim751 Linux - Software 1 04-21-2008 07:18 PM
Cannot get interface flags: Invalid argument nasim751 Programming 1 04-21-2008 12:22 PM


All times are GMT -5. The time now is 05:07 AM.

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