C++ application: how to access AIX process and cpu information?


 
Thread Tools Search this Thread
Top Forums Programming C++ application: how to access AIX process and cpu information?
# 1  
Old 05-31-2009
C++ application: how to access AIX process and cpu information?

Hi,

may be this is an AIX noob question:
my current C++ application runs on Linux and is quite memory consuming. Therefore, the application writes a logfile after it has finished containing memory information, CPU information, information on the running other processes besides my application etc.
On Linux I use the /proc/ pseudo-filesystem to access this information.
How can I do this for AIX? Is there any "standard" way how to do this (without calling any system commands and parsing its output)?

Thank you very much for your help!!
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Cpu information

hi unix expert is there any program in terminal to show cpu and ram information? and usage of this? Many thanks samad (3 Replies)
Discussion started by: abdossamad2003
3 Replies

2. Shell Programming and Scripting

Tricky situation with process cpu usage - AIX

OS: AIX so we frequently receive a lot of cpu related alerts. all types of checks have been created to keep an eye on the cpu but a lot of these checks make too much noise as the CPU is always being seen as high. the system and application owners say there's no issue with the cpu. so now,... (6 Replies)
Discussion started by: SkySmart
6 Replies

3. AIX

AIX core,cpu and application list

Hi All , I am trying to pull out below things from AIX machine (any type) 1. number of physical processor 2. number of logical processsors 3. Total number of processors (physical plus logical) 4. total number of cores 5. list of installed applications with versions and vendor name ... (1 Reply)
Discussion started by: omkar.jadhav
1 Replies

4. Shell Programming and Scripting

Cpu utilization by a process has to be mailed if more than 5% on AIX

i am using the below command in order to find the cpu utilization by a user..now i want to mail if the cpu utilization goes beyond 5%....can someone please help me ? ps auxw | sort -r +2 | awk '{ print $3,$1 }' | head -6 | egrep "USER|#anonymous#" %CPU USER 2.0 anonymous Regards,... (6 Replies)
Discussion started by: arorap
6 Replies

5. AIX

Aix process CPU differences.

Hi, I'm trying to create a script to catch a process which is consuming high CPU which I have pretty much done but it's just finding the correct place to pull the current CPU for that process. When viewed in Topas it's consuming 99.*% cpu But if I try using ps avg or ps -eo pcpu ... (5 Replies)
Discussion started by: elmesy
5 Replies

6. AIX

How to access process and cpu info on AIX?

Hi, may be this is an AIX noob question: my current C++ application runs on Linux and is quite memory consuming. Therefore, the application writes a logfile after it has finished containing memory information, CPU information, information on the running other processes besides my application... (5 Replies)
Discussion started by: DarthVader77
5 Replies

7. AIX

Find CPU per process in AIX

Hi. I am looking for a command that will return me the amount of CPU used by a specific process in AIX environment. I know there is TOPAS - but it is interactive and I need to get this information from system that connects remotely via SSH. Using writing to files and than reading them is also... (1 Reply)
Discussion started by: yamsin789
1 Replies

8. UNIX for Dummies Questions & Answers

how to get persistant cpu utilization values per process per cpu in linux (! top,ps)

hi, i want to know cpu utilizatiion per process per cpu..for single processor also if multicore in linux ..to use these values in shell script to kill processes exceeding cpu utilization.ps (pcpu) command does not give exact values..top does not give persistant values..psstat,vmstat..does njot... (3 Replies)
Discussion started by: pankajd
3 Replies

9. AIX

Cmd to find CPU utiliz of a process in AIX

Hello All, I wanna find the CPU utilization of a specific process running on AIX OS. I have its pid, but not sure about the command. iostat sar 5 5 vmstat All the above give me system CPU utilization. Is there a way to find for a specific pid??? Thanks, Ankita (11 Replies)
Discussion started by: Ankita
11 Replies

10. Programming

Obtaining Process information on AIX

I have written a program to collect some performance metrics on and AIX box, but I'm having difficultly getting the process information. I'm lead to believe that I'm not getting the correct information because I'm trying to run the program on AIX 5.1 (5100-03), but I'm not convinced as the... (0 Replies)
Discussion started by: StuBob
0 Replies
Login or Register to Ask a Question
XmFontListGetNextFont(library call)									       XmFontListGetNextFont(library call)

NAME
XmFontListGetNextFont -- A font list function that allows applications to access the fonts and character sets in a font list SYNOPSIS
#include <Xm/Xm.h> Boolean XmFontListGetNextFont( XmFontContext context, XmStringCharSet *charset, XFontStruct **font); DESCRIPTION
XmFontListGetNextFont accesses the character set and font for the next entry of the font list. The application first uses the XmFontLis- tInitFontContext routine to create a font list context. The application then calls XmFontListGetNextFont repeatedly with the same context. Each succeeding call accesses the next element of the font list. When finished, the application calls XmFontListFreeFontContext to free the allocated font list context. This routine allocates memory for the character set string that must be freed by the application. The function allocates memory for charset. The application is responsible for managing the allocated memory. The application can recover the allocated memory by calling XtFree. This function is obsolete and exists for compatibility with previous releases. It is replaced by XmFontListNextEntry. If XmFontListGet- NextFont is passed a context that contains a font set entry, it will return the first font of the font set. The next call to the function will move to the next entry in the font list. context Specifies the font list context charset Specifies a pointer to a character set string; the routine returns the character set for the current font list element font Specifies a pointer to a pointer to a font structure; the routine returns the font for the current font list element RETURN
Returns True if the returned values are valid; otherwise, returns False. RELATED
XmFontList(3) and XmFontListNextEntry(3). XmFontListGetNextFont(library call)