CPUs information on IBM AIX 4.3


 
Thread Tools Search this Thread
Operating Systems AIX CPUs information on IBM AIX 4.3
# 1  
Old 06-04-2008
CPUs information on IBM AIX 4.3

Hi,

I would like to know how can i get information like %user %kernel %idle etc for each cpu. Getting the infomation for the complete system cpu usage is given below but can you help me in getting each cpu information from cpu 0 to cpu n-1. Is there any kernel symbol for that and if there is how to offset into it.

static struct nlist nlst[] = {
{ "sysinfo", 0, 0, 0, 0, 0 }, /* 0 */
};
if (knlist(nlst, 1, sizeof(struct nlist)) != 0) {
perror("knlist");
return -1;
sysinfo_offset = nlst[0].n_value;
struct sysinfo s_info;
// then i read the value from kmem using
// get sysinfo structure
getkval(sysinfo_offset, (caddr_t)&s_info, sizeof s_info, "sysinfo");

Thanks a lot

Regards,
Raja
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. AIX

IBM Virtual Machine OS on intel x86 and x64? IBM AIX OS on IBM Virtual Machine?

Hi There, I have zero information and zero knowledge for IBM virtual machine except Amazon cloud and VMware ESXi (Only Linux OS available). Anyone could provide me the following answer - Can IBM VM been deploy on X86 and X64 (Intel Chip)? If answer is yes any chance to deploy AIX OS... (13 Replies)
Discussion started by: chenyung
13 Replies

2. Shell Programming and Scripting

I want a script to view the complete log information of data stage job from UNIX IBM AIX.

Hi, I am working on data stage 8.7 version and I want a script a to view the all log information of the data stage job from UNIX environment. Can you please help me out by give the script. Thanks in advance... (7 Replies)
Discussion started by: victory
7 Replies

3. AIX

IBM AIX 5.3 Display

Hi, all! I am new in IBM AIX 5.3. I tried to activate graphical display when connected to my UNIX server. 1) I downloaded Putty to connect to my UNIX server. 2) Then I downloaded Xming and installed it. After that I installed Xming fonts. 3)Then I downloaded AIX fonts and put them into... (7 Replies)
Discussion started by: Debuger
7 Replies

4. AIX

pwage-aix for IBM AIX servers

This is the password aging script for aix just completed. So far tested and still testing on one of our aix server running 5.3.0.0. So anyway as you can see it is very similar to pwage-hpux-T the only difference on aix /etc/passwd file looks in this format. Also for this script to work you need to... (0 Replies)
Discussion started by: sparcguy
0 Replies

5. AIX

AIX IBM I and LINUX

As I know PowerVM supports these OS's AIX IBM I and LINUX but is there any blade or other hardware that allows us to use all these OS's (1 Reply)
Discussion started by: Vit0_Corleone
1 Replies

6. AIX

IBM AIX on IBM Eseries & x series server

Hi, I want to know whether IBM AIX can be installed on the IBM e series and x series server hardware? Thanks & Regards Arun (2 Replies)
Discussion started by: Arun.Kakarla
2 Replies

7. AIX

Completed IBM AIX

Yesterday I complted IBM AIX Certification (000-223). Passed 74% (8 Replies)
Discussion started by: udayn
8 Replies

8. AIX

ibm aix L1

hello all, can anyone send me ibm aix L1 interview questions... thank u guys...jiyojith (0 Replies)
Discussion started by: jiyojith
0 Replies

9. UNIX for Advanced & Expert Users

how is IBM-AIX better..?

why IBM-AIX is preferred over HP-UX ..... In what way it is better for infrastructure......? Suggestions are welcome... Suggest you read the RULES (0 Replies)
Discussion started by: bishweshwar
0 Replies

10. AIX

Help-----ibm Aix???

:confused: Hello everybody, I am a totel dummy when it comes to UNIX!!! Must be wondering what I am doing here right? I'm most keen on knowing about-it-all. I need help. Wanna know all about the IBM AIX. The versions, the latest. Please tell me how do I go about my search. Thanks a... (3 Replies)
Discussion started by: rtanuja
3 Replies
Login or Register to Ask a Question
CPUSET(3)						   BSD Library Functions Manual 						 CPUSET(3)

NAME
cpuset_create, cpuset_destroy, cpuset_zero, cpuset_set, cpuset_clr, cpuset_isset, cpuset_size -- dynamic CPU sets SYNOPSIS
#include <sched.h> cpuset_t * cpuset_create(void); void cpuset_destroy(cpuset_t *set); void cpuset_zero(cpuset_t *set); int cpuset_set(cpuid_t cpu, cpuset_t *set); int cpuset_clr(cpuid_t cpu, cpuset_t *set); int cpuset_isset(cpuid_t cpu, const cpuset_t *set); size_t cpuset_size(const cpuset_t *set); DESCRIPTION
This section describes the functions used to create, set, use and destroy the dynamic CPU sets. This API can be used with the POSIX threads, see pthread(3) and affinity(3). The ID of the primary CPU in the system is 0. FUNCTIONS
cpuset_create() Allocates and initializes a clean CPU-set. Returns the pointer to the CPU-set, or NULL on failure. cpuset_destroy(set) Destroy the CPU-set specified by set. cpuset_zero(set) Makes the CPU-set specified by set clean, that is, memory is initialized to zero bytes, and none of the CPUs set. cpuset_set(cpu, set) Sets the CPU specified by cpu in set. Returns zero on success, and -1 if cpu is invalid. cpuset_clr(cpu, set) Clears the CPU specified by cpu in the CPU-set set. Returns zero on success, and -1 if cpu is invalid. cpuset_isset(cpu, set) Checks if CPU specified by cpu is set in the CPU-set set. Returns the positive number if set, zero if not set, and -1 if cpu is invalid. cpuset_size(set) Returns the size in bytes of CPU-set specified by set. SEE ALSO
affinity(3), pset(3), sched(3), schedctl(8), kcpuset(9) HISTORY
The dynamic CPU sets appeared in NetBSD 5.0. BSD
November 2, 2011 BSD