svmon Command
Purpose
Captures and analyzes a snapshot of virtual memory.
Syntax
svmon -C commands [ -O options ] [ -t count ] [ -i interval [ numintervals ] ] [ -@ [ ALL | wparnames ] ]
svmon -D sids [ -O options ] [ -i interval [ numintervals ] ]
svmon -G [ -O options ] [ -i interval [ numintervals ] ] [ -@ [ ALL | wparnames ] ]
svmon -P [ pids ] [ -O options ] [ [ -t count ] [ -i interval [ numintervals ] ] [ -@ [ ALL | wparnames ] ]
svmon -S [ sids ] [ -O options ] [ -t count ] [ -i interval [ numintervals ] ] [ -@ [ ALL | wparnames ] ]
svmon -U [ lognames ] [ -O options ] [ -t count ] [ -i interval [ numintervals ] ] [ -@ [ ALL | wparnames ] ]
Workload management class report
svmon -W [ classnames ] [ -O options ] [ -t count ] [ -i interval [ numintervals ] ] [ -@ [ ALL | wparnames ] ]
Workload management tier report
svmon -T [ tiers ] [ -O options ] [ -a supclassname ] [ -t count ] [ -i interval [ numintervals ] ] [ -@ [ ALL | wparnames ] ]
svmon X [ -o filename ] [ -i interval [ numintervals ] ] [ -c < comment > ] [ -O options ]
Description
The svmon command displays information about the current state of memory. However, the displayed information does not constitute a true snapshot of memory because the svmon command runs at user level with interrupts enabled.
If you specify no flag, the svmon command, by default, reports real memory at the system level.
The output of these reports can be in compact format or long format. To generate compact format report, specify the -O flag. If you do not specify the -O flag, the report is in long format.
Command report
Item | Description |
---|---|
Compact report | A one line summary for each command. To set compact report as the default format, specify the -O flag. |
Long report | A multiple lines report for each command that contains a summary, a size-per-page report, and the details of the segments. To set long report as the default format, do not specify the -O flag. |
Detailed segment report
The detailed segment report displays detailed information about the primary segments that are specified. To print the detailed segment report, specify the -D flag.
The detailed segment report is in long report format only.
Global report
The global report displays the statistics of the real memory and paging space that are in use for the whole system. If you do not specify any flag, the global report is the default format of report that the svmon command generates.
To print the global report, specify the -G flag.
Item | Description |
---|---|
Compact report | A report on only the main metrics of the system. This report is one line with a maximum of 160 characters. |
Long report | A summary of memory, page size, and affinity domain. The report is multiple lines, which is
the default format of global report. By default, the following metrics are displayed:
|
vmm_klock_mode
option) is enabled. For more information about the kernal lock
option, refer to the vmo -h vmm_klock_mode command documentation. Process report
The process report displays the memory use for the specified active process. If you do not specify a list of processes, the svmon command displays the memory use statistics for all active processes.
To print the process report, specify the -P flag.
Item | Description |
---|---|
Compact report | A one line report for each process. To set the compact report as the default format, specify the -O flag. |
Long report | A multiple lines summary for each process. To set the long report as the default format, do not specify the -O flag. This report contains a summary for each process, a per-page-size report, and the details of the segments. |
Segment report
The segment report displays the statistics of memory use for the specified segments. To display the statistics for all of the defined segments, do not specify any list.
To print the segment report, specify the -S flag.
The segment report includes metrics for each specified segment. The report contains several lines of metrics for each segment.
User report
The user report displays the statistics of memory use for the specified users (login names). To display the statistics for all of the users, do not specify any list of login names.
To print the user report, specify the -U flag.
Item | Description |
---|---|
Compact report | A one line report for each user. To set the compact report as the default format, specify the -O flag. |
Long report | A multiple lines summary for each user. To set the long report as the default format, do not specify the -O flag. This report contains a summary for each user, a per-page-size report, and the details of the segments. |
Workload management class report
The workload management class report displays statistics of memory use for the specified workload management classes. To display the statistics for all of the defined classes, do not specify any class.
To print the workload management class report, specify the -W flag.
WLM must be started
If
the Workload Manager is running
in passive mode, the svmon command displays the following message
before displaying the statistics: WLM is running in passive mode
Item | Description |
---|---|
Compact report | A one line report for each class. To set the compact report as the default format, specify the -O flag. |
Long report | A multiple lines summary for each class. To set the long report as the default format, do not specify the -O flag. This report contains a summary for each class, a per-page size report, and the details of the segments. |
Workload management tier report
The workload management tier report displays information about the tiers, such as the tier number, the superclass name, and the total number of pages in real memory from segments belonging to the tier.
To print the tier report, specify the -T flag. Only the long report format is supported.
WLM must be started
If the Workload Manager is running in passive
mode, the svmon command displays the following message before
displaying the statistics: WLM is running in passive mode
XML report
You can use the svmon command with an -X flag to generate a report in XML format. The XML report contains data of the global environment, the processes, the segments, the users, the workload management classes, and the commands running on the system.
The report is by default printed to the standard output. To print the output to a file named filename, specify the -O filename flag. The extension of the output file will be .svm.
The .svm file uses an XML Schema Definition (XSD) that the /usr/lib/perf/svmon_schema.xsd file defines. You can use the XML data in the XML reports to build custom applications because the schema is self-documented.
In the XML report, if you do not specify the -O affinity argument, or set it to the off value, only the domain affinity at system level is reported.
Flags
If no command line flag is given, then the -G flag is the default.
Item | Description |
---|---|
-@ [ ALL | wparnames ] | Displays report for the workload partitions. The -@ ALL option specifies to display the report for all of the WPAR starting with the global report, and to process all of the available WPAR, sorting them by the name. When you specify a list of WPAR names in the wparnames parameter, the WPAR information is displayed in a header, and the report is displayed without adding WPAR information. All information displayed is restricted to the WPAR that was processed and has meaning only inside the WPAR. For example, the pid displayed is virtual pid, which is the pid inside the WPAR. The same rule applies to the svmon options. Each WPAR name in the list is processed in the given order and each svmon report is separated by the WPARname header. When you do not specify a list, the svmon command adds WPAR information to existing reports. The pid section and segments section of the report contain the WPAR name when one is available. Virtual pid information might also be displayed. When all of the keywords are used, the svmon command processes all of the available WPAR, sorting them by the WPAR name. Note: The -@ flag
is not supported when executed within a workload partition.
|
-a supclassname | Restricts the scope to the subclasses of the supclassname parameter (in the Tier report that is returned with the -T flag). |
-c < comment > | Adds a comment, specified by the comment parameter, into the XML report. Use the -c flag with the -X flag. |
-C commands | Displays memory use statistics for the processes running the commands that are specified by the commands parameter. |
-D sids | Displays memory use statistics for the segments that the sids parameter specifies, and a detail status of all of the frames of each segment. |
-G | Displays a global report. |
-i interval [ numintervals ] | Displays statistics repetitively. The svmon command collects and prints statistics in the interval that the interval parameter specifies. The numintervals parameter specifies the number of repetitions. If the numintervals parameter is not specified, the svmon command runs until you interrupt it (Ctrl+C). Tip: The
observed interval might be larger than the specified interval because
it might take a few seconds to collect statistics for some options.
|
-o filename | Specifies the output file with the filename parameter for XML reports. Use this flag with the -X flag. |
-O options | Changes the content and presentation of the reports that the svmon command generates.
You can specify values to the options parameter to modify the output. Tip: To overwrite the default values that are defined previously by the -O
options flag, you can define the .svmonrc configuration file in the
directory where the svmon command is launched.
|
-P [ pids ] | Displays the memory-usage statistics for the processes that the pids parameter specifies. |
-S [ sids ] | Displays the memory-usage statistics for segments that the sids parameter specifies. The sids parameter is a hexadecimal value. The segment IDs (SIDs) that are specified must be of primary segments. If you do not specify a list of SIDs, the statistics of memory use are displayed for all of the defined segments. |
-t count | Displays the top object in the count parameter to be printed. |
-T [ tiers ] | Displays the memory-usage statistics of all of the classes of the tier numbers that the tiers parameter specifies. If you do not specify a list of tiers, the statistics of memory use are displayed for all of the defined tiers. |
-U [ lognames ] | Displays the memory-usage statistics for the login name that the lognames parameter specifies. If you do not specify a list of login identifiers, the statistics of the memory use are displayed for all of the defined login identifiers. |
-W [ classnames ] | Displays the memory-usage statistics for the Workload Manager class that the classnames parameter specifies. If you do not specify a list of class names, the statistics of memory usage are displayed for all of the defined class names. |
-X | Generates the XML report. |
Parameters
Item | Description |
---|---|
commands | Specifies the commands to be reported in the command report ( -C ). The value of the commands parameter is a string. You can specify more than one command. The value of the commands parameter is the exact base name of an executable file. |
options |
Specifies the content and presentation of each report. Use this parameter with the -O flag. The values of the options parameter must be separated by commas, or
enclosed in quotation marks (“ ”) and separated by commas or spaces. The following values are valid
to the options parameter.
Tip: The
scope specifies the reports that support the value.
|
options |
( Continued description of the valid values for the options parameter).
Note: If you use the value of file_mem_scan = on, the performance might be impacted
based on the number of files opened while running the command and the number of segments in the
system.
|
options |
( Continued description of the valid values for the options parameter).
|
options |
( Continued description of the valid values for the options parameter).
|
options |
( Continued description of the valid values for the options parameter).
|
options |
( Continued description of the valid values for the options parameter).
|
options |
( Continued description of the valid values for the options parameter).
|
options |
( Continued description of the valid values for the options parameter).
|
|
|
options |
( Continued description of the valid values for the options parameter).
|
options |
( Continued description of the valid values for the options parameter).
|
options |
( Continued description of the valid values for the options parameter).
Tip: To overwrite the default values that are defined previously by
the -O
options flag, you can define the .svmonrc configuration file in the
directory where the svmon command is launched.
|
count | Specifies the top object to be printed. Use the count parameter with the -T flag. |
interval | Specifies the interval for the svmon command to collect and print statistics. Use the interval parameter with the -i flag. |
numintervals | Specifies the number of repetitions for the svmon command to collect and
print statistics when the interval parameter is specified. Use the
numintervals parameter with the -i
interval option. If the numintervals parameter is not specified, the svmon command runs until you interrupt it (Ctrl+C). |
ALL | Specifies that the -@ flag displays the report for all of the WPAR starting with the global report, and then process all of the available WPAR, sorting them by the WPAR name. |
wparnames | Specifies the workload partitions whose
information is to be displayed. When you specify the -@
wparnames option, all of the information displayed is restricted to the
WPAR that the
wparnames parameter specifies, and has meaning only inside the WPAR. Each WPAR name in the list is processed in the given order and each svmon report is separated by the WPARname header. |
sids | Specifies the segment IDs (SIDs). The SIDs must be primary segments. |
pids | Specifies the process IDs (PIDs). The value of the pids parameter is a decimal value. If you do not supply any list of process IDs (PIDs), the statistics of memory use are displayed for all active processes. Use the pids parameter with the -P flag. |
lognames | Specifies the login names. The value of the lognames parameter is a string. It is an exact login name. If you do not specify any lists of login identifiers, the statistics of the memory use are displayed for all of the defined login identifiers. Use the lognames parameter with the -U flag. |
classnames | Specifies the Workload Manager class. The value of the classnames parameter is a string. It is the exact name of a class. For a subclass, the name should be in the form superclassname.subclassname. |
tiers | Specifies a tier number for the classes. If you do not specify a list of tiers, the statistics of memory use are displayed for all of the defined tiers. Use the tiers parameter with the -T flag. |
supclassname | Specifies the name of the superclass that the subclasses are restricted to. You cannot specify a list of classes for this flag. |
filename | Specifies the name of the output file. It is an alpha-numeric string. The suffix of the output file name is .svm. It is automatically added to the file name if you do not specify the suffix. Use the filename parameter with the -o flag and the -X flag. |
comment | Specifies the string to add in the <CollectionHeader><Comment> tag of the XML report. Use the comment parameter with the -X flag and the -c flag. |
Security
Any user can run the svmon command. If the user is not a root user, the view will be limited to the user's own processes.
If RBAC is activated and the aix.system.stat role that is attributed to the user, the user can see the same view that the root user does.
Examples
- To display global statistics in a one line format every minute
for 30 minutes, enter the following command:
# svmon -G -O summary=longreal -i 60 30
- To display global statics with automatic unit selection, a time
stamp, per page size data, and detailed affinity information, enter
the following command:
# svmon -G -O unit=auto,timestamp=on,pgsz=on,affinity=detail
- To display global statistics for the system and all of its WPAR in a compact format,
enter the following command:
# svmon -G -O summary=longreal -@ ALL
- To display the memory consumption in megabytes (MB) of all processes
in a compact report, enter the following command:
# svmon -P -O summary=basic,unit=MB
- To display the memory consumption of all processes according to
the number of virtual pages, and sort the segments for each process
by the number of pages in the paging space, enter the following command:
# svmon -P -O segment=on,sortentity=virtual,sortseg=pgsp
- To display the memory consumption of process 123456 in full detail,
enter the following command:
# svmon -P 123456 -O segment=on,pidlist=on,range=on,mapping=on,shmid=on,filename=on,affinity=detail
- To display the top 10 system segments sorted by the number of
pages in real memory, enter the following command:
# svmon -S -t 10 -O filtercat=kernel,sortseg=inuse
- To display all of the segments that are not attached to a process,
enter the following command:
# svmon -S -O filtercat=unattached
- To display only 16 MB segments with their address ranges, enter
the following command:
# svmon -S -O filterpgsz=L -O range=on
- In the global WPAR,
to display the WPAR name
that each segment belongs to, enter the following command:
# svmon -S -@
- To display the memory consumption of all Oracle processes in a
compact report for only the shared segments, enter the following command:
# svmon -C oracle -O summary=basic,filtercat=shared
- To display the top 10 users running the processes that consume
the most memory every minute, enter the following command:
# svmon -U -t 10 -O summary=basic -i 60
- To display the memory use for the
Mysupclass
superclass with its subclasses, enter the following command:# svmon -W Mysupclass -O subclass=on
- To display the memory use for the
0
tier subclasses of theMysupclass
superclass, enter the following command:# svmon -T 0 -a Mysupclass
- To display the frames that belong to the
36cfb
segment with frame level details, enter the following command:# svmon -D 36cfb -O frame=on
- To generate an XML report in the lpar01.svm file, enter
the following command:
# svmon -X -o lpar01.svm # svmon -X -o lpar01
- To generate an XML report with affinity domain details, enter
the following command:
# svmon -X -o lpar_affinity -O affinity=on
- To generate an XML report with affinity domain details at the
segment level, enter the following command:
# svmon -X -o lpar_affinitydet -O affinity=detail
- To display global statistics with memory compression details along
with true memory snapshot at the end, enter the following command:
# svmon -G -O summary=ame
- To display global statistics with memory compression details with
true memory details turned-off, enter the following command
# svmon -G -O summary=ame,tmem=off
- To display global statistics with Active Memory Expansion details (in
an Active Memory Expansion
enabled system) in a one line format, enter the following command
# svmon -G -O summary=longame
- To display the home SRADIDs and thread SRAD affinity statistics for the threads
of a process, enter:
# svmon -P 1 -O threadaffinity=on