Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 11-22-2002, 01:38 PM   #1
LQ Newbie
Registered: Nov 2002
Posts: 1

Rep: Reputation: 0
Unhappy System Stats


I need to write a program that can monitor the CPU usage , memory usage and monitor the list of PId .

I know this can be possible by parsing the /proc filesystem. But I dont want to do that. I am looking for some kind of an API that will let me read these values directly from my code...

Old 11-24-2002, 03:09 PM   #2
Registered: Aug 2001
Location: ChristChurch New Zealand
Distribution: Ubuntu
Posts: 389

Rep: Reputation: 87
The /proc file system is designed to be very fast, and very easy to parse, and language neutral.

It is actually one of the better ways of getting such data.

There is also no POSIX mandated interface to that sort of info.

The linux kernel source has a fair bit on what the magic numbers mean.


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
UT2004 stats I_Come_anon3410 Linux - Games 2 10-16-2004 08:59 PM
system stats RTT Linux - Software 3 03-08-2004 04:00 PM
DU Stats WhiteWolf Linux - Networking 0 10-01-2003 06:43 PM
System Stats Fantmx Linux - Newbie 1 04-30-2003 02:13 AM
SYstem stats Stephanie General 6 02-21-2003 10:17 AM > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 12:41 AM.

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