Solaris lgrpinfo
Version 12.1.0.1

General Information
Library Note Morgan's Library Page Footer
The Library is currently in the process of being upgraded from Oracle Database Version 11.2.0.3 to 12.1.0.1. Demos are being upgraded to reflect the new Container paradigm as well as EBR (Edition Based Redefinition) and may contain references to CDBs, PDBs, and other objects you may not be familiar with such as CDB_OBJECTS_AE: Welcome to 12c.
Purpose Displays information about NUMA locality groups
 
Description
The lgrpinfo command prints information about the locality group (lgroup) hierarchy and its contents.

An lgroup represents the set of CPU and memory-like hardware devices that are at most some distance (latency) apart from each other. All lgroups in the system are identified by a unique integer called an "lgroup ID".

The lgroups are organized into a hierarchy to facilitate finding the nearest resources. Leaf lgroups each contain a set of resources that are closest (local) to each other. Each parent lgroup in the hierarchy contains the resources of its child lgroups plus their next nearest resources. Finally, the root lgroup contains all the resources in the domain within the largest latency.

A Uniform Memory Access (UMA) machine will simply be represented by the root lgroup. A Non Uniform Memory Access (NUMA) machine is represented by a hierarchy of lgroups to show the corresponding levels of locality. For example, a NUMA machine with two latencies (local and remote) will have an lgroup hierarchy consisting of two levels with its leaves and the root.

Every application thread is assigned a "home" lgroup. When the system needs to allocate a CPU or memory resource for a thread, it searches lgroup hierarchy from the thread's home lgroup for the closest available resources to the thread's home.

When called without arguments, lgrpinfo(1) prints general information about all lgroups in the system. If any lgroup IDs are given in the command line, the command will only print information about the specified lgroups.
 
Description
When called without arguments, lgrpinfo(1) prints general information about all lgroups in the system. If any lgroup IDs are given in the command line, the command will only print information about the specified lgroups.

The lgroup(s) may be specified on the command line as lgroup IDs or by using one of the following keywords:
all All lgroups (default)
intermediate All intermediate lgroups (where an intermediate lgroup is an lgroup that has a parent and children)
leaves All leaf lgroups (where a leaf lgroup is an lgroup that has no children in the lgroup hierarchy)
root Root lgroup (which contains all the resources in the domain within the largest latency and has no parent lgroup)

If an invalid lgroup is specified, the lgrpinfo command prints a message on standard error showing the invalid ID and continues processing other lgroups given in the command line. When none of the specified lgroups are valid, lgrpinfo(1) will exit with 2 as its exit status.
 
Command Line Switches
Calling the program without any arguments is equivalent to: lgrpinfo -c -e -l -m -r -t -all
-a Print topology, CPU, memory, load and latency information. This option is a shorthand for -t -c -e -m -r -l -L unless -T is specified as well. When -T is specified, the -t option is not included. This option, by itself, is shorthand for lgrpinfo -t -c -e -m -r -l -L.
-- print lgroup topology tree, resources, memory and CPU information on a 2 CPU AMD Opteron machine

$ lgrpinfo -Ta
0
|-- 1
|   CPU: 0
|   Memory: installed 2048 Mb, allocated 659 Mb, free 1389 Mb
|   Load: 0.713
|   Latency: 56
`-- 2
    CPU: 1
    Memory: installed 2047 Mb, allocated 323 Mb, free 1724 Mb
    Load: 0.187
    Latency: 56

Lgroup latencies:

------------
  |  0  1  2
------------
0 | 83 83 83
1 | 83 56 83
2 | 83 83 56
------------
-c Print CPU information (default)
-- print CPU IDs for all CPUs in lgroup 1

$ lgrpinfo -c -I 1
0
-C Replace each lgroup in the list with its children. This option cannot be used with the -P or -T option. With no other options given, this option will be applied to the lgroups displayed by default which is all of them.
-- print lgroup IDs for children of the root lgroup

$ lgrpinfo -I -C root
1 2
-e Print lgroup load average (default).
TBD
-G Print OS view of lgroup hierarchy. By default, the caller's view of the lgroup hierarchy is displayed which only includes what the caller can use (eg. only the CPUs in the caller's processor set will be displayed, etc.). Please see lgrp_init(3LGRP) for more details on the OS and caller's view.
TBD
-h Print short help message and exit.
TBD
-I Only print matching IDs. If -c is specified as well, print list of CPUs contained in all matching lgroups. Otherwise, the IDs for the matching lgroups will be displayed (see examples). With no other options given, this option will be applied to the lgroups displayed by default which is all of them.
TBD
-l Print information about lgroup latencies.
$ lgrpinfo -l
lgroup 0 (root):
        Latency: 103
lgroup 1 (leaf):
        Latency: 72
lgroup 2 (leaf):
        Latency: 72
-L Print the lgroup latency table.
TBD
-m Print memory information (default). Memory is rounded to the closest unit specified with -u.
TBD
-P Replace each lgroup in the list with its parent(s). This option cannot be used with the -C or -T option. With no other options given, this option will be applied to the lgroups displayed by default which is all of them.
TBD
-r Print information about lgroup resources. If -T is specified as well, only prints information about resources for the intermediate lgroups. The resources are represented by a set of lgroups in which each lgroup directly contains CPU and/or memory resources.
TBD
-t Print information about lgroup topology (default).
TBD
-T Print the lgroup topology of a system graphically as a tree. This option may only be used with the -a, -c, -e, -m, -l, -r, and -u options. If this option is combined with -c, -e, -l, -m, or -r, it prints the relevant information for all leaf lgroups. The -t option is omitted when -T is used with -a.
-- print lgroup topology tree on a 4 CPU AMD Opteron machine

$ lgrpinfo -T
0
|-- 5
|   `-- 1
|-- 6
|   `-- 2
|-- 7
|   `-- 3
`-- 8
    `-- 4
-u Specify memory units. Units should be b, k, k, g, t for bytes, kilobytes, megabytes, gigabytes and terabytes respectively. By default, memory is printed in megabytes. This option implies -m.
TBD
 
 
Exit Status Values
0 Successful operation
1 Unable to get lgroup information from the system
2 Invalid lgroup
3 Invalid syntax

Related Topics
NUMA
Troubleshooting

Morgan's Library Page Footer
This site is maintained by Dan Morgan. Last Updated: This site is protected by copyright and trademark laws under U.S. and International law. © 1998-2014 Daniel A. Morgan All Rights Reserved