Results 1 to 5 of 5
  1. #1
    Join Date
    Jun 2003
    Posts
    38

    Thumbs up Unanswered: Affinity Parameters in Onconfig

    Hi,

    I am using IDS 7.3. My onconfig file for the server has NUMCPUVPS as 8 and no values for AFF_NPROCS and AFF_SPROC (the affinity parameters). Its a multi-cpu system with 8 processors.

    I am trying to calculate 'usercpu' (the output of onstat -p). The onstat -g glo and onstat -g sch lists others VPs too.


    My query is :
    In a multi-processor environment:
    How to discover how many processors are being employed? With Affinity turned on, we can count the cpus assigned to the Informix engine using AFFN_PROCS. But, I do not know if those will be the only CPU's employed or not.

    Thanks,
    Anu_R
    Last edited by Anu_R; 07-09-03 at 03:36.

  2. #2
    Join Date
    Aug 2002
    Location
    Belgium
    Posts
    534
    There are lots of unix commands to do so.

    You can also monitor the sysvpprof table in the sysmaster database.

    When affinity is not turned on, all virtual processors (processes) will jump to the physical cpu with the least work to do. If you want them to stick to one physical CPU you will have to turn on affinity.
    rws

  3. #3
    Join Date
    Jun 2003
    Posts
    38
    Thanks. But my situation is slightly different. Say I have 8 CPU's. My NUMCPUVPS is 8. I turn on affinity.

    Now how do I find which of the 8 CPUs are actually getting involved.

    Affinity just ensures that the probability of CPU VPs binding to the assigned CPU is more. The number of CPU vps does not necessarily match the number of CPU which denote the available CPU time. We are not monitoring the CPU vps but CPU usage. Almost all of vps use both user and system CPU time. So the result of onstat -g glo or onstat -g sch is actually not helpful.

    The sysvpprof as you mentioned does give the CPU VP and its usage. But does it tell me which is the active CPU? I am trying to think at the hardware level and not at the CPU VP level.

    Please suggest.

  4. #4
    Join Date
    Aug 2002
    Location
    Belgium
    Posts
    534
    If you define 8 CPU VP's, all 8 physical CPUs will be used if they are recognized by the OS.
    You can only be sure which physical CPU is used if you bind a CPU VP to a physical process. If the affinity is turned of, I think that the OS takes care of the separate processes and decides on which CPU it has to run.

    The more CPU VPS you define the more the database can spread the network handling (poll and listen threads) and the sql execution (sqlexec threads).
    Every connection results in a thread spawn and is created in a specific CPU VP.
    'onstat -g ath' shows you all the threads doing the work and you can immediately see in which CPU VP the thread is created.

    I am not sure what you want to do here - or what you want to check. Do you have a CPU tuning issue?
    rws

  5. #5
    Join Date
    Jun 2003
    Posts
    38
    Originally posted by Roelwe
    If you define 8 CPU VP's, all 8 physical CPUs will be used if they are recognized by the OS.
    You can only be sure which physical CPU is used if you bind a CPU VP to a physical process. If the affinity is turned of, I think that the OS takes care of the separate processes and decides on which CPU it has to run.

    The more CPU VPS you define the more the database can spread the network handling (poll and listen threads) and the sql execution (sqlexec threads).
    Every connection results in a thread spawn and is created in a specific CPU VP.
    'onstat -g ath' shows you all the threads doing the work and you can immediately see in which CPU VP the thread is created.

    I am not sure what you want to do here - or what you want to check. Do you have a CPU tuning issue?
    Hi,

    I don't remember if I answered your last question. We are trying to deal with processor affinity basically.

    I basically need to find: out of 8 CPU's how many CPU's actually got involved in doing some sql execution during the last 5 seconds for example. I need the related pid of CPU, the cpu VP, and the value of usercpu and syscpu for each of the actively involved CPU.

    Does this info help?

    Thanks,
    Anu_R

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •