Hallo, dies ist ein Test.
PWD: /www/data-lst1/unixsoft/unixsoft/kaempfer/.public_html
Running in File Mode
Relative path: ./../../../../../../usr/man/man1/pmap.1
Real path: /usr/share/man/man1/pmap.1
Zurück
'\" te .\" Copyright (c) 1998, 2022, Oracle and/or its affiliates. .TH pmap 1 "29 Nov 2022" "Oracle Solaris 11.4" "User Commands" .SH NAME pmap \- displays information about the address space of a process .SH SYNOPSIS .LP .nf \fB/usr/bin/pmap\fR [\fB-bhrslF\fR] [\fB-A\fR \fIaddress_range\fR] [\fB--scale\fR[=\fIitem1\fR,\fIitem2\fR,...]] [\fIpid\fR | \fIcore\fR]... .fi .LP .nf \fB/usr/bin/pmap\fR \fB-L\fR [\fB-bhrslF\fR] [\fB-A\fR \fIaddress_range\fR] [\fB--scale\fR[=\fIitem1\fR,\fIitem2\fR,...]] [\fIpid\fR] ... .fi .LP .nf \fB/usr/bin/pmap\fR \fB-x\fR [\fB-ahslF\fR] [\fB-A\fR \fIaddress_range\fR] [\fB--scale\fR[=\fIitem1\fR,\fIitem2\fR,...]] [\fIpid\fR]... .fi .LP .nf \fB/usr/bin/pmap\fR \fB-S\fR [\fB-ahlF\fR] [\fB-A\fR \fIaddress_range\fR] [\fB--scale\fR[=\fIitem1\fR,\fIitem2\fR,...]] [\fIpid\fR | \fIcore\fR]... .fi .SH DESCRIPTION .sp .LP The \fBpmap\fR utility prints information about the address space of a process. .SH OPTIONS .sp .LP The following options are supported: .sp .ne 2 .mk .na \fB\fB-a\fR\fR .ad .br .sp .6 .RS 4n Prints anonymous and swap reservations for shared mappings. .RE .sp .ne 2 .mk .na \fB\fB-A\fR \fIaddress_range\fR\fR .ad .br .sp .6 .RS 4n Specifies the subrange of address space to display. \fIaddress_range\fR is specified in one of the following forms: .sp .ne 2 .mk .na \fB\fIstart_addr\fR\fR .ad .br .sp .6 .RS 4n A single address limits the output to the segment (or the page if the \fB-L\fR option is present) containing that address. If the specified address corresponds to the starting address of a segment, the output always includes the whole segment even when the \fB-L\fR option is specified. .RE .sp .ne 2 .mk .na \fB\fIstart_addr\fR\fB,\fR\fR .ad .br .sp .6 .RS 4n An address followed by comma without the end address limits the output to all segments (or pages if the \fB-L\fR option is present) starting from the one containing the specified address. .RE .sp .ne 2 .mk .na \fB\fIstart_addr\fR\fB,\fR \fIend_addr\fR\fR .ad .br .sp .6 .RS 4n An address range specified by the start address and end address limits the output to all segments (or pages if the \fB-L\fR option is present) starting from the segment or page containing the start address through the segment or page containing the end address. .RE .sp .ne 2 .mk .na \fB\fB,\fR\fIend_addr\fR\fR .ad .br .sp .6 .RS 4n An address range started with comma without the start address limits the output to all segments, or pages if the \fB-L\fR option is present starting from the first one present until the segment, or pages if the \fB-L\fR option is present containing the specified address. .RE .RE .sp .ne 2 .mk .na \fB\fB-b\fR\fR .ad .br .sp .6 .RS 4n Print the \fBbasename\fR of mapped files rather than the full file path (see \fBbasename\fR(1)). .RE .sp .ne 2 .mk .na \fB\fB-F\fR\fR .ad .br .sp .6 .RS 4n Force. Grabs the target process even if another process has control. .sp For more information, see the Usage section. .RE .sp .ne 2 .mk .na \fB\fB-h\fR\fR .ad .br .sp .6 .RS 4n On output, memory sizes are scaled to a human readable format. The \fB-h\fR option is equivalent to using the \fB--scale=max,1024\fR option. .RE .sp .ne 2 .mk .na \fB\fB-l\fR\fR .ad .br .sp .6 .RS 4n Shows unresolved dynamic linker map names. .RE .sp .ne 2 .mk .na \fB\fB-L\fR\fR .ad .br .sp .6 .RS 4n Prints \fBlgroup\fR containing physical memory that backs virtual memory. .RE .sp .ne 2 .mk .na \fB\fB-r\fR\fR .ad .br .sp .6 .RS 4n Prints the process's reserved addresses. .RE .sp .ne 2 .mk .na \fB\fB-s\fR\fR .ad .br .sp .6 .RS 4n Prints \fBHAT\fR page size information. .RE .sp .ne 2 .mk .na \fB\fB-S\fR\fR .ad .br .sp .6 .RS 4n Displays swap reservation information per mapping. For more information, see the Usage section. .RE .sp .ne 2 .mk .na \fB\fB-x\fR\fR .ad .br .sp .6 .RS 4n Displays additional information per mapping. For more information, see the Usage section. .RE .sp .ne 2 .mk .na \fB\fB--scale[=item1,item2,...\fR]\fR .ad .br .sp .6 .RS 4n On output, memory sizes are scaled to a human readable format, for example, \fB14K\fR, \fB234M\fR, \fB2.7G\fR, or \fB3.0T\fR. Scaling is done by repetitively dividing by \fB1024\fR, unless otherwise specified. \fB--scale\fR specified without arguments enables default scaled output, and is equivalent to \fB--scale=max,1024\fR. See \fBscale\fR(7) for a complete description of \fB--scale\fR features. .RE .sp .ne 2 .mk .na \fB\fB-?\fR\fR .ad .br .na \fB\fB--help\fR\fR .ad .br .sp .6 .RS 4n Print usage message and immediately exit. .RE .SH USAGE .sp .LP The \fBpmap\fR utility prints information about the address space of a process. .sp .ne 2 .mk .na \fBProcess Mappings\fR .ad .br .sp .6 .RS 4n .sp .in +2 .nf /usr/bin/pmap [ -rslF ] [-A \fIaddress_range\fR] [ \fIpid\fR | \fIcore\fR ] ... .fi .in -2 .sp By default, \fBpmap\fR displays all of the mappings in the virtual address order they are mapped into the process. The mapping size, flags, and mapped object name are shown. .sp The \fB-A\fR option can be used to limit the output to a specified address range. The specified addresses are rounded up or down to a segment boundary and the output includes the segments bounded by those addresses. .RE .sp .ne 2 .mk .na \fBProcess \fBLgroup\fR Mappings\fR .ad .br .sp .6 .RS 4n .sp .in +2 .nf /usr/bin/pmap -L [ -rslF ] [-A \fIaddress_range\fR] \fIpid\fR ... .fi .in -2 .sp The \fB-L\fR option can be used to determine the \fBlgroup\fR containing the physical memory backing the specified virtual memory. When used with the \fB-A\fR option, the specified addresses are rounded up or down to a page boundary and the output is limited to the page or pages bounded by those addresses. .sp This can be used in conjunction with \fBplgrp\fR(1) to discover whether the home \fBlgroup\fR of a thread of interest is the same as where the memory is located, and whether there should be memory locality for the thread. The \fBlgrpinfo\fR(1) command can also be useful with this \fBpmap\fR option. It displays the \fBlgroup\fR hierarchy, contents, and characteristics which gives more information about the \fBlgroups\fR that the memory is distributed across and their relationship to each other and any other \fBlgroups\fR of interest. .sp In addition, the thread and memory placement can be changed by using \fBplgrp\fR(1), \fBpmadvise\fR(1), or \fBmadv.so.1\fR(1). .RE .sp .ne 2 .mk .na \fBProcess \fBanon\fR/locked mapping details\fR .ad .br .sp .6 .RS 4n .sp .in +2 .nf /usr/bin/pmap -x [ -aslF ] [-A \fIaddress_range\fR] [ \fIpid\fR] ... .fi .in -2 .sp The \fB-x\fR option displays additional information per mapping. The size of each mapping, the amount of resident physical memory (RSS), the amount of anonymous memory, and the amount of memory locked is shown with this option. This does not include anonymous memory taken by kernel address space due to this process. .RE .sp .ne 2 .mk .na \fBSwap Reservations\fR .ad .br .sp .6 .RS 4n .sp .in +2 .nf /usr/bin/pmap -S [ -alF ] [-A \fIaddress_range\fR] [ \fIpid\fR | \fIcore\fR ] ... .fi .in -2 .sp The \fB-S\fR option displays swap reservation information per mapping. .RE .sp .LP Caution should be exercised when using the \fB-F\fR flag. Imposing two controlling processes on one victim process can lead to chaos. Safety is assured only if the primary controlling process, typically a debugger, stops the victim process and the primary controlling process does nothing at the moment of application of the \fBproc\fR tool in question. .SH DISPLAY FORMATS .sp .LP One line of output is printed for each mapping within the process, unless the \fB-s\fR or \fB-L\fR option is specified. With \fB-s\fR option, one line is printed for a contiguous mapping of each hardware translation page size. With \fB-L\fR option, one line is printed for a contiguous mapping belonging to the same \fBlgroup\fR. With both \fB-L\fR and \fB-s\fR options, one line is printed for a contiguous mapping of each hardware translation page size belonging to the same \fBlgroup\fR. The column headings are shown in parentheses below. .sp .ne 2 .mk .na \fBVirtual Address (\fBAddress\fR)\fR .ad .br .sp .6 .RS 4n The first column of output represents the starting virtual address of each mapping. Virtual addresses are displayed in ascending order. .RE .sp .ne 2 .mk .na \fBVirtual Mapping Size (\fBKbytes\fR)\fR .ad .br .sp .6 .RS 4n The virtual size in kilobytes of each mapping. See \fB--scale\fR. .RE .sp .ne 2 .mk .na \fBResident Physical Memory (\fBRSS\fR)\fR .ad .br .sp .6 .RS 4n The amount of physical memory in kilobytes that is resident for each mapping, including that which is shared with other address spaces. See \fB--scale\fR. .RE .sp .ne 2 .mk .na \fBAnonymous Memory (\fBAnon\fR)\fR .ad .br .sp .6 .RS 4n The number of pages, counted by using the system page size, of anonymous memory associated with the specified mapping. Anonymous memory shared with other address spaces is not included, unless the \fB-a\fR option is specified. .sp Anonymous memory is reported for the process heap, stack, for '\fBcopy on write\fR' pages with mappings mapped with \fBMAP_PRIVATE\fR. For more information, see the \fBmmap\fR(2) man page. .RE .sp .ne 2 .mk .na \fBLocked (\fBLock\fR)\fR .ad .br .sp .6 .RS 4n The number of pages locked within the mapping. Typical examples are memory locked with \fBmlock()\fR and System V shared memory created with \fBSHM_SHARE_MMU\fR. .RE .sp .ne 2 .mk .na \fBPermissions/Flags (\fBMode\fR)\fR .ad .br .sp .6 .RS 4n The virtual memory permissions are shown for each mapping. Valid permissions are: .sp .sp .ne 2 .mk .na \fB\fBr:\fR\fR .ad .RS 6n .rt The mapping can be read by the process. .RE .sp .ne 2 .mk .na \fB\fBw:\fR\fR .ad .RS 6n .rt The mapping can be written by the process. .RE .sp .ne 2 .mk .na \fB\fBx:\fR\fR .ad .RS 6n .rt Instructions that reside within the mapping can be executed by the process. .RE Flags showing additional information for each mapping can be displayed: .sp .ne 2 .mk .na \fB\fBs:\fR\fR .ad .RS 8n .rt The mapping is shared such that changes made in the observed address space are committed to the mapped file, and are visible from all other processes sharing the mapping. .RE .sp .ne 2 .mk .na \fB\fBi:\fR\fR .ad .RS 8n .rt The mapping is enabled for ADI. .RE .sp .ne 2 .mk .na \fB\fBR:\fR\fR .ad .RS 8n .rt Swap space is not reserved for this mapping. Mappings created with \fBMAP_NORESERVE\fR and System V \fBISM\fR shared memory mappings do not reserve swap space. .RE .sp .ne 2 .mk .na \fB\fBI/E:\fR\fR .ad .RS 8n .rt The mapping has prune requests active and will be included or excluded from the core file. 'I' indicates inclusion whereas, 'E' indicates exclusion. .RE .sp .ne 2 .mk .na \fB\fB*:\fR\fR .ad .RS 8n .rt The data for the mapping is not present in the core file (only applicable when applied to a core file). For information on configuring core file content, see the \fBcoreadm\fR(8) man page. .RE .RE .sp .ne 2 .mk .na \fB\fBLgroup\fR (\fBLgrp\fR)\fR .ad .br .sp .6 .RS 4n The \fBlgroup\fR containing the physical memory that backs the specified mapping. .RE .sp .ne 2 .mk .na \fBMapping Name (\fBMapped File\fR)\fR .ad .br .sp .6 .RS 4n A descriptive name for each mapping. The following major types of names are displayed for mappings: .sp .ne 2 .mk .na \fBA mapped file:\fR .ad .br .sp .6 .RS 4n For mappings between a process and a file, the \fBpmap\fR command attempts to resolve the segment name, and file name for each mapping. If the file name cannot be resolved, \fBpmap\fR displays the major and minor number of the device containing the file, and the file system inode number of the file. .RE .sp .ne 2 .mk .na \fBAnonymous memory:\fR .ad .br .sp .6 .RS 4n Memory not relating to any named object or file within the file system is reported as \fB[\ anon\ ]\fR. .sp The \fBpmap\fR command displays common names for certain known anonymous memory mappings: .sp .sp .ne 2 .mk .na \fB\fB[\ heap\ ]\fR\fR .ad .RS 24n .rt The mapping is the process heap. .RE .sp .ne 2 .mk .na \fB\fB[\ stack\ ]\fR\fR .ad .RS 24n .rt The mapping is the main stack. .RE .sp .ne 2 .mk .na \fB\fB[\ stack tid=\fIn\fR\ ]\fR\fR .ad .RS 24n .rt The mapping is the stack for thread \fIn\fR. .RE .sp .ne 2 .mk .na \fB\fB[\ altstack tid=\fIn\fR\ ]\fR\fR .ad .RS 24n .rt The mapping is used as the alternate signal stack for thread \fIn\fR. .RE If the common name for the mapping is unknown, \fBpmap\fR displays \fB[\ anon\ ]\fR as the mapping name. .RE .sp .ne 2 .mk .na \fBSystem V Shared Memory:\fR .ad .br .sp .6 .RS 4n Mappings created using System V shared memory system calls are reported with the names shown below: .sp .ne 2 .mk .na \fB\fBshmid=n:\fR\fR .ad .br .sp .6 .RS 4n The mapping is a System V shared memory mapping. The shared memory identifier that the mapping was created with is reported. .RE .sp .ne 2 .mk .na \fB\fBism shmid=n:\fR\fR .ad .br .sp .6 .RS 4n The mapping is an "Intimate Shared Memory" variant of System V shared memory. \fBISM\fR mappings are created with the \fBSHM_SHARE_MMU\fR flag set, in accordance with \fBshmat\fR(2). .RE .sp .ne 2 .mk .na \fB\fBdism shmid=n:\fR\fR .ad .br .sp .6 .RS 4n The mapping is a pageable variant of \fBISM\fR. Pageable \fBISM\fR is created with the \fBSHM_PAGEABLE\fR flag set in accordance with \fBshmat\fR(2). .RE .sp .ne 2 .mk .na \fB\fBosm shmid=n:\fR\fR .ad .br .sp .6 .RS 4n The mapping is an "optimized shared memory" (OSM) variant of ISM, and was created using \fBshmget_osm\fR(2). .RE .RE .sp .ne 2 .mk .na \fBReserved Virtual Address:\fR .ad .br .sp .6 .RS 4n Ranges are reported as [ \fBreserved\fR ] and are created to prevent the kernel from choosing addresses within the Reserved range to satisfy non-fixed address memory mapping operations (\fBmmap\fR(2) and \fBshmat\fR(2)). Fixed address mapping operations can map on top of the Reserved VA range in which case the Mapping Name changes to that of the new mapping. When the fixed address mapping is unmapped, the address range reverts back to [ \fBreserved\fR ]. .sp Unlike other mapping types, Reserved VA ranges can occupy any location in the process' address space including 'invalid' locations, such as the VA hole. For more information, see MC_RESERVE_AS in \fBmemcntl\fR(2). .RE .sp .ne 2 .mk .na \fBCMI Memory:\fR .ad .br .sp .6 .RS 4n Mappings created by using the CMI API are reported with the names shown below: .sp .ne 2 .mk .na \fB\fBcmi cmi_seg=n\fR:\fR .ad .br .sp .6 .RS 4n The mapping is a local CMI memory. The segment handle that the mapping was created with is reported. .RE .sp .ne 2 .mk .na \fB\fBcmi cmi_seg=n (remote)\fR:\fR .ad .br .sp .6 .RS 4n The mapping is a remote CMI memory. The segment handle that the mapping was created with is reported. .RE .RE .sp .ne 2 .mk .na \fBOther:\fR .ad .br .sp .6 .RS 4n Mappings of other objects, including devices such as frame buffers. No mapping name is shown for other mapped objects. .RE .RE .sp .ne 2 .mk .na \fBPage Size (\fBPgsz\fR)\fR .ad .br .sp .6 .RS 4n The page size in kilobytes that is used for hardware address translation for this mapping. See \fB--scale\fR. For more information, see the \fBmemcntl\fR(2) man page. .RE .sp .ne 2 .mk .na \fBSwap Space (\fBSwap\fR)\fR .ad .br .sp .6 .RS 4n The amount of swap space in kilobytes that is reserved for this mapping. That is, swap space that is deducted from the total available pool of reservable swap space that is displayed with the command \fBswap\fR \fB-s\fR. See \fB--scale\fR. For more information, see the \fBswap\fR(8) man page. .RE .SH EXAMPLES .LP \fBExample 1\fR Displaying Process Mappings .sp .LP By default, \fBpmap\fR prints one line for each mapping within the address space of the target process. The following example displays the address space of a typical shell. .sp .in +2 .nf example$ \fBpmap $$\fR 3585: /usr/bin/ksh 0000000100000000 1728K r-x---- [ text ] /usr/bin/ksh 00000001001B0000 56K r-x---- [ text ] /usr/bin/ksh 00000001002BE000 8K rwx---- [ data ] /usr/bin/ksh 00000001002C0000 64K rwx---- [ data ] /usr/bin/ksh 00000001002D0000 16K rwx---- [ data ] /usr/bin/ksh 0000000100300000 24K rw----- [ bss ] /usr/bin/ksh 0000000EEBFC4000 8K rw----- [ heap ] 0007FCB434C00000 2176K r-x---- [ text ] /lib/sparcv9/libc.so.1 0007FCB434E20000 24K r-x---- [ text ] /lib/sparcv9/libc.so.1 0007FCB434F26000 80K rwx---- [ data ] /lib/sparcv9/libc.so.1 0007FCB434F3A000 40K rwx---- [ data ] /lib/sparcv9/libc.so.1 0007FCB435000000 704K r-x---- [ text ] /lib/sparcv9/libm.so.2 0007FCB4350B0000 56K r-x---- [ text ] /lib/sparcv9/libm.so.2 0007FCB4351BC000 16K rwx---- [ data ] /lib/sparcv9/libm.so.2 0007FCB435200000 256K r-x---- [ text ] /lib/sparcv9/ld.so.1 0007FCB4352F0000 128K rw----- [ anon ] 0007FCB435320000 64K rw----- [ anon ] 0007FCB435340000 8K r------ [ dtrace ] /lib/sparcv9/ld.so.1 0007FCB435370000 128K rw----- [ anon ] 0007FCB4353A0000 128K rw----- [ anon ] 0007FCB4353D0000 128K rw----- [ anon ] 0007FCB435400000 128K rw----- [ anon ] 0007FCB435430000 64K rw----- [ anon ] 0007FCB435442000 24K rwx---- [ data ] /lib/sparcv9/ld.so.1 0007FCB435448000 8K rwx---- [ data ] /lib/sparcv9/ld.so.1 0007FCB435460000 24K rw----- [ anon ] 0007FCB43546E000 8K rw-s--- [ anon ] 0007FCB435472000 8K r--s--- [ anon ] 0007FCB435476000 8K r--s--- [ anon ] 0007FCB43547A000 8K r--s--- [ anon ] 0007FCB43547E000 8K r-x---- [ anon ] FFFFFCFCE72A0000 64K rw----- [ stack ] FFFFFCFCE72B0000 40K rw----- [ stack ] total 6232K .fi .in -2 .sp .LP \fBExample 2\fR Displaying Memory Allocation and Mapping Types .sp .LP The \fB-x\fR option can be used to provide information about the memory allocation and mapping types per mapping. The amount of resident, non-shared anonymous, and locked memory is shown for each mapping. .sp .in +2 .nf example$ \fBpmap -x $$\fR 4022: /usr/bin/ksh Address Kbytes RSS Anon Lock Mode Mapped File 0000000100000000 1784 1704 - - r-x---- [ text ] ksh 00000001002BE000 88 88 72 - rwx---- [ data ] ksh 0000000100300000 24 16 16 - rw----- [ bss ] ksh 0000006AB975A000 8 - - - rw----- [ heap ] 0007FD56FE400000 2200 2200 - - r-x---- [ text ] libc.so.1 0007FD56FE726000 80 80 80 - rwx---- [ data ] libc.so.1 0007FD56FE73A000 40 24 24 - rwx---- [ data ] libc.so.1 0007FD56FE800000 760 760 - - r-x---- libm.so.2 0007FD56FE9BC000 16 16 16 - rwx---- libm.so.2 0007FD56FEA00000 256 256 - - r-x---- [ text ] ld.so.1 0007FD56FEB40000 8 8 - - r------ [ dtrace ] ld.so.1 0007FD56FEBD0000 64 64 64 - rw----- [ anon ] 0007FD56FEBF0000 128 128 128 - rw----- [ anon ] 0007FD56FEC1C000 8 8 - - rw-s--- [ anon ] 0007FD56FEC20000 128 128 128 - rw----- [ anon ] 0007FD56FEC42000 24 24 24 - rwx---- [ data ] ld.so.1 0007FD56FEC48000 8 8 8 - rwx---- [ data ] ld.so.1 0007FD56FEC60000 128 128 128 - rw----- [ anon ] 0007FD56FEC90000 128 128 128 - rw----- [ anon ] 0007FD56FECC0000 24 16 16 - rw----- [ anon ] 0007FD56FECD0000 64 64 64 - rw----- [ anon ] 0007FD56FECEA000 8 8 - - r--s--- [ anon ] 0007FD56FECEE000 8 8 - - r--s--- [ anon ] 0007FD56FECF2000 8 8 - - r--s--- [ anon ] 0007FD56FECF6000 8 8 - - r-x---- [ anon ] FFFFFD103AE20000 64 64 64 - rw----- [ stack ] FFFFFD103AE30000 24 24 24 - rw----- [ stack ] ---------------- ------ ---- ---- ---- total Kb 6088 5968 984 - .fi .in -2 .sp .sp .LP The amount of incremental memory used by each additional instance of a process can be estimated by using the resident and anonymous memory counts of each mapping. .sp .LP In the above example, the shell process has a resident memory size of 5968 Kbytes. However, a large amount of the physical memory used by the shell is shared with other processes. When more than one process runs the same program, they share physical memory with each other where possible, and allocate anonymous memory for any non-shared portion. In the above example, each additional shell process uses approximately 984Kbytes of additional physical memory. .sp .LP A more complex example shows the output format for a process containing different mapping types. In this example, the mappings are as follows. .sp .ne 2 .mk .na \fB0001000\fR .ad .RS 11n .rt Executable text, mapped from 'maps' program .RE .sp .ne 2 .mk .na \fB0002000\fR .ad .RS 11n .rt Executable data, mapped from 'maps' program .RE .sp .ne 2 .mk .na \fB0002200\fR .ad .RS 11n .rt Program heap .RE .sp .ne 2 .mk .na \fB0300000\fR .ad .RS 11n .rt A mapped file, mapped \fBMAP_SHARED\fR .RE .sp .ne 2 .mk .na \fB0400000\fR .ad .RS 11n .rt A mapped file, mapped \fBMAP_PRIVATE\fR .RE .sp .ne 2 .mk .na \fB0500000\fR .ad .RS 11n .rt A mapped file, mapped \fBMAP_PRIVATE | MAP_NORESERVE\fR .RE .sp .ne 2 .mk .na \fB0600000\fR .ad .RS 11n .rt Anonymous memory, created by mapping \fB/dev/zero\fR .RE .sp .ne 2 .mk .na \fB0700000\fR .ad .RS 11n .rt Anonymous memory, created by mapping \fB/dev/zero\fR with \fBMAP_NORESERVE\fR .RE .sp .ne 2 .mk .na \fB0800000\fR .ad .RS 11n .rt A \fBDISM\fR shared memory mapping, created with \fBSHM_PAGEABLE\fR with 8MB locked via \fBmlock\fR(3C) .RE .sp .ne 2 .mk .na \fB0900000\fR .ad .RS 11n .rt A \fBDISM\fR shared memory mapping, created with \fBSHM_PAGEABLE\fR, with 4MB of its pages touched .RE .sp .ne 2 .mk .na \fB0A00000\fR .ad .RS 11n .rt An \fBISM\fR shared memory mapping, created with \fBSHM_SHARE_MMU\fR, with none of its pages touched .RE .sp .ne 2 .mk .na \fB0B00000\fR .ad .RS 11n .rt An \fBISM\fR shared memory mapping, created with \fBSHM_SHARE_MMU\fR .RE .sp .ne 2 .mk .na \fB0C00000\fR .ad .RS 11n .rt A remote CMI memory mapping .RE .sp .ne 2 .mk .na \fB0D00000\fR .ad .RS 11n .rt A local CMI memory mapping .RE .sp .in +2 .nf example$ \fBpmap -x 4095\fR 4095: ./maps Address Kbytes RSS Anon Lock Mode Mapped File 00010000 8 8 - - r-x---- [ text ] maps 00020000 8 8 8 - rwx---- [ data ] maps 00022000 56 8 8 - rwx---- [ heap ] 03000000 1024 1024 - - rw-s--- dev:533,2 ino:631625786 04000000 1024 1024 512 - rw----- dev:533,2 ino:631625786 05000000 1024 1024 512 - rw--R-- dev:533,2 ino:631625786 06000000 1024 1024 1024 - rw----- [ anon ] 07000000 512 512 512 - rw--R-- [ anon ] 08000000 8192 8192 - 8192 rwxs--- [ dism shmid=0x0 ] 09000000 8192 8192 - - rwxs--- [ dism shmid=0x1 ] 0A000000 8192 8192 - 8192 rwxsR-- [ ism shmid=0x2 ] 0B000000 8192 8192 - 8192 rwxsR-- [ ism shmid=0x3 ] 0C000000 1048576 1048576 - - r--s--- [ cmi cmi_seg=0x3 (remote) ] 0D000000 262144 262144 - - rw-s--- [ cmi cmi_seg=0x2 ] FECA0000 2104 1848 - - r-x---- [ text ] libc.so.1 FEEBE000 48 48 48 - rwx---- [ data ] libc.so.1 FEECA000 24 16 16 - rwx---- [ data ] libc.so.1 FF370000 24 16 16 - rw----- [ anon ] FF380000 240 240 - - r-x---- [ text ] ld.so.1 FF3CC000 8 8 - - r------ [ dtrace ] ld.so.1 FF3D4000 32 24 24 - rw----- [ anon ] FF3DE000 16 16 16 - rwx---- [ data ] ld.so.1 FF3EE000 8 8 - - r--s--- [ anon ] FF3F2000 8 8 - - r--s--- [ anon ] FF3F6000 8 8 - - r--s--- [ anon ] FF3FA000 8 8 - - r-x---- [ anon ] FFBF0000 64 64 64 - rw----- [ stack ] -------- ------- ------- ---- ----- total Kb 40040 39712 2760 24576 .fi .in -2 .sp .LP \fBExample 3\fR Displaying Page Size Information .sp .LP The \fB-s\fR option can be used to display the hardware translation page sizes for each portion of the address space. (See \fBmemcntl\fR(2) for further information on Solaris multiple page size support). .sp .LP In the example below, we can see that the majority of the mappings are using an 8K-Byte page size, while the shared memory segments are using a 4M-Byte page size. .sp .LP Notice that non-contiguous regions of resident pages of the same page size are reported as separate mappings. In the example below, the \fBlibc.so\fR library is reported as separate mappings, since only some of the \fBlibc.so\fR text is resident. .sp .in +2 .nf example$ \fBpmap -xs 1840\fR 1840: ./maps Address Kbytes RSS Anon Lock Pgsz Mode Mapped File 00010000 8 8 - - 8K r-x---- [ text ] maps 00020000 8 8 8 - 8K rwx---- [ data ] maps 00022000 8 8 8 - 8K rwx---- [ heap ] 00024000 48 - - - - rwx---- [ heap ] 03000000 1024 1024 - - 8K rw-s--- dev:533,2 ino:569519580 04000000 1024 1024 512 - 8K rw----- dev:533,2 ino:569519580 05000000 1024 1024 512 - 8K rw--R-- dev:533,2 ino:569519580 06000000 1024 1024 1024 - 64K rw----- [ anon ] 07000000 512 512 512 - 8K rw--R-- [ anon ] 08000000 8192 8192 - 8192 4M rwxs--- [ dism shmid=0x0 ] 09000000 8192 8192 - - 4M rwxs--- [ dism shmid=0x1 ] 0A000000 8192 8192 - 8192 4M rwxsR-- [ ism shmid=0x2 ] 0B000000 8192 8192 - 8192 4M rwxsR-- [ ism shmid=0x3 ] FECA0000 384 384 - - 64K r-x---- [ text ] libc.so.1 FED00000 256 64 - - - r-x---- [ text ] libc.so.1 FED40000 640 640 - - 64K r-x---- [ text ] libc.so.1 FEDE0000 128 128 - - - r-x---- [ text ] libc.so.1 FEE00000 64 64 - - 64K r-x---- [ text ] libc.so.1 FEE10000 128 64 - - - r-x---- [ text ] libc.so.1 FEE30000 320 320 - - 64K r-x---- [ text ] libc.so.1 FEE80000 128 128 - - - r-x---- [ text ] libc.so.1 FEEA0000 16 16 - - - r-x---- [ text ] libc.so.1 FEEA4000 40 40 - - 8K r-x---- [ text ] libc.so.1 FEEBE000 48 48 48 - 8K rwx---- [ data ] libc.so.1 FEECA000 8 - - - - rwx---- [ data ] libc.so.1 FEECC000 16 16 16 - 8K rwx---- [ data ] libc.so.1 FF370000 16 16 16 - 8K rw----- [ anon ] FF374000 8 - - - - rw----- [ anon ] FF380000 192 192 - - 64K r-x---- [ text ] ld.so.1 FF3B0000 48 48 - - 8K r-x---- [ text ] ld.so.1 FF3CC000 8 8 - - 8K r------ [ dtrace ] ld.so.1 FF3D4000 24 24 24 - 8K rw----- [ anon ] FF3DA000 8 - - - - rw----- [ anon ] FF3DE000 16 16 16 - 8K rwx---- [ data ] ld.so.1 FF3EE000 8 8 - - - r--s--- [ anon ] FF3F2000 8 8 - - - r--s--- [ anon ] FF3F6000 8 8 - - - r--s--- [ anon ] FF3FA000 8 8 - - - r-x---- [ anon ] FFBF0000 64 64 64 - 64K rw----- [ stack ] -------- ------ ----- ---- ----- total Kb 40040 39712 2760 24576 .fi .in -2 .sp .LP \fBExample 4\fR Displaying Swap Reservations .sp .LP The \fB-S\fR option can be used to describe the swap reservations for a process. The amount of swap space reserved is displayed for each mapping within the process. Swap reservations are reported as zero for shared mappings, since they are accounted for only once system wide. .sp .in +2 .nf example$ \fBpmap -S 4220\fR 4220: ./maps Address Kbytes Swap Mode Mapped File 00010000 8 - r-x---- [ text ] maps 00020000 8 8 rwx---- [ data ] maps 00022000 56 56 rwx---- [ heap ] 03000000 1024 - rw-s--- dev:533,2 ino:634348912 04000000 1024 1024 rw----- dev:533,2 ino:634348912 05000000 1024 512 rw--R-- dev:533,2 ino:634348912 06000000 1024 1024 rw----- [ anon ] 07000000 512 512 rw--R-- [ anon ] 08000000 8192 - rwxs--- [ dism shmid=0x0 ] 09000000 8192 - rwxs--- [ dism shmid=0x1 ] 0A000000 8192 - rwxsR-- [ ism shmid=0x2 ] 0B000000 8192 - rwxsR-- [ ism shmid=0x3 ] FECA0000 2104 - r-x---- [ text ] libc.so.1 FEEBE000 48 48 rwx---- [ data ] libc.so.1 FEECA000 24 24 rwx---- [ data ] libc.so.1 FF370000 24 24 rw----- [ anon ] FF380000 240 - r-x---- [ text ] ld.so.1 FF3CC000 8 - r------ [ dtrace ] ld.so.1 FF3D4000 32 32 rw----- [ anon ] FF3DE000 16 16 rwx---- [ data ] ld.so.1 FF3EE000 8 - r--s--- [ anon ] FF3F2000 8 - r--s--- [ anon ] FF3F6000 8 - r--s--- [ anon ] FF3FA000 8 - r-x---- [ anon ] FFBF0000 64 64 rw----- [ stack ] -------- ------ ---- total Kb 40040 3344 .fi .in -2 .sp .sp .LP The swap reservation information can be used to estimate the amount of virtual swap used by each additional process. Each process consumes virtual swap from a global virtual swap pool. Global swap reservations are reported by the '\fBavail\fR' field of the \fBswap\fR(8) command. .LP \fBExample 5\fR Labeling Stacks in a Multi-threaded Process .sp .in +2 .nf example$ \fBpmap 8703\fR 8703: ./stacks 00010000 8K r-x---- [ text ] /tmp/stacks 00020000 8K rwx---- [ data ] /tmp/stacks 00022000 56K rwx---- [ heap ] FE79A000 8K rw--R-- [ stack tid=11 ] FE89A000 8K rw--R-- [ stack tid=10 ] FE99A000 8K rw--R-- [ stack tid=9 ] FEA9A000 8K rw--R-- [ stack tid=8 ] FEB9A000 8K rw--R-- [ stack tid=7 ] FEC9A000 8K rw--R-- [ stack tid=6 ] FECA0000 2048K r-x---- [ text ] /lib/libc.so.1 FEEA0000 56K r-x---- [ text ] /lib/libc.so.1 FEEBE000 48K rwx---- [ data ] /lib/libc.so.1 FEECA000 24K rwx---- [ data ] /lib/libc.so.1 FEFFA000 8K rw--R-- [ stack tid=5 ] FF0FA000 8K rw--R-- [ stack tid=4 ] FF1FA000 8K rw--R-- [ stack tid=3 ] FF200000 64K rw----- [ anon ] FF31A000 8K rw--R-- [ stack tid=2 ] FF320000 64K rw----- [ anon ] FF340000 128K rw----- [ anon ] FF370000 24K rw----- [ anon ] FF380000 192K r-x---- [ text ] /lib/ld.so.1 FF3B0000 48K r-x---- [ text ] /lib/ld.so.1 FF3C8000 8K rw----- [ altstack tid=8 ] FF3CC000 8K r------ [ dtrace ] /lib/ld.so.1 FF3D4000 32K rw----- [ anon ] FF3DE000 16K rwx---- [ data ] /lib/ld.so.1 FF3E6000 8K rw----- [ altstack tid=4 ] FF3EA000 8K rw-s--- [ anon ] FF3EE000 8K r--s--- [ anon ] FF3F2000 8K r--s--- [ anon ] FF3F6000 8K r--s--- [ anon ] FF3FA000 8K r-x---- [ anon ] FFBF0000 64K rw----- [ stack ] .fi .in -2 .sp .LP \fBExample 6\fR Displaying \fBlgroup\fR Memory Allocation .sp .LP The following example displays \fBlgroup\fR memory allocation by mapping. .sp .in +2 .nf example$ \fBpmap -bL `pgrep nscd`\fR 8629: /usr/sbin/nscd 000000B8886D6000 8K rw----- - [ heap ] 000000B8886D8000 32K rw----- 2 [ heap ] 000000B8886E0000 64K rw----- 2 [ heap ] 000000B8886F0000 256K rw----- 1 [ heap ] \&... 0007FE2990700000 64K r-x---- 1 [ text ] libucrypto.so.1 0007FE2990710000 64K r-x---- 2 [ data ] libucrypto.so.1 \&... 0007FE2995200000 8K r-x---- 1 [ text ] nss_dns.so.1 0007FE2995202000 16K r-x---- 2 [ text ] nss_dns.so.1 0007FE2995306000 8K rwx---- 2 [ data ] nss_dns.so.1 \&... 0007FE2995800000 64K r-x---- 2 [ text ] nss_ldap.so.1 0007FE2995810000 16K r-x---- 2 [ text ] nss_ldap.so.1 0007FE2995914000 8K rwx---- 2 [ data ] nss_ldap.so.1 \&... 0007FE2995C00000 16K r-x---- 1 [ text ] nss_files.so.1 0007FE2995C04000 32K r-x---- 2 [ text ] nss_files.so.1 0007FE2995D0C000 8K rwx---- 2 [ data ] nss_files.so.1 \&... 0007FE2997300000 192K r-x---- 1 [ text ] ld.so.1 0007FE2997330000 64K r-x---- 2 [ text ] ld.so.1 0007FE2997440000 8K r------ - [ dtrace ] ld.so.1 0007FE2997542000 24K rwx---- 2 [ data ] ld.so.1 0007FE2997548000 8K rwx---- 2 [ data ] ld.so.1 0007FE2997600000 64K r-x---- 1 [ text ] nscd 0007FE2997610000 64K r-x---- 2 [ text ] nscd 0007FE2997620000 64K r-x---- 1 [ text ] nscd 0007FE2997630000 16K r-x---- - [ text ] nscd \&... 0007FE2997734000 32K rwx---- 2 [ data ] nscd \&... 0007FE299777C000 8K rw-s--- 2 [ anon ] 0007FE2997780000 64K rw----- 2 [ anon ] 0007FE2997796000 8K r-x---- - [ anon ] 0007FE299779E000 8K r--s--- 1 [ anon ] 0007FE29977A2000 8K r--s--- 1 [ anon ] 0007FE29977A6000 8K r--s--- - [ anon ] FFFFFE5DEF5F0000 16K rw----- - [ stack ] FFFFFE5DEF5F4000 8K rw----- 2 [ stack ] total 177264K .fi .in -2 .sp .SH EXIT STATUS .sp .LP The following exit values are returned: .sp .ne 2 .mk .na \fB\fB0\fR\fR .ad .RS 12n .rt Successful operation. .RE .sp .ne 2 .mk .na \fBnon-zero\fR .ad .RS 12n .rt An error has occurred. .RE .SH FILES .sp .ne 2 .mk .na \fB\fB/proc/*\fR\fR .ad .RS 19n .rt process files .RE .sp .ne 2 .mk .na \fB\fB/usr/proc/lib/*\fR\fR .ad .RS 19n .rt \fBproc\fR tools supporting files .RE .SH ATTRIBUTES .sp .LP See \fBattributes\fR(7) for descriptions of the following attributes: .sp .TS tab( ) box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) . ATTRIBUTE TYPE ATTRIBUTE VALUE _ Availability system/core-os _ Interface Stability See below. .TE .sp .sp .LP The command syntax is Committed. The \fB-L\fR option and the output formats are Uncommitted. .SH SEE ALSO .sp .LP \fBbasename\fR(1), \fBldd\fR(1), \fBlgrpinfo\fR(1), \fBmadv.so.1\fR(1), \fBmdb\fR(1), \fBplgrp\fR(1), \fBpmadvise\fR(1), \fBproc\fR(1), \fBps\fR(1), \fBmemcntl\fR(2), \fBmeminfo\fR(2), \fBmlock\fR(3C), \fBmmap\fR(2), \fBshmget_osm\fR(2), \fBshmop\fR(2), \fBdlopen\fR(3C), \fBproc\fR(5), \fBattributes\fR(7), \fBcmi\fR(7), \fBscale\fR(7), \fBcoreadm\fR(8), \fBprstat\fR(8), \fBswap\fR(8) .SH NOTES .sp .LP Core files do not contain all the information present in the live running image of a process. For example, a segment of memory, reported by pmap as ISM in a running process, may be reported as heap when pmap is run against a core file from the same process. .SH HISTORY .sp .LP Support for the \fB-?\fR, \fB-h\fR, \fB--help\fR, and \fB--scale\fR options was added in the Oracle Solaris 11.4.42 release. .sp .LP Support for the \fB-b\fR option was added in the Oracle Solaris 11.4.0 release. .sp .LP Support for the \fB-A\fR and \fB-L\fR options was added in the Oracle Solaris 11.0.0 release. .sp .LP Support for the \fB-a\fR, \fB-s\fR, and \fB-S\fR options was added in the Solaris 9 release. .sp .LP Support for core file operands was added in the Solaris 8 release. .sp .LP Support for the \fB-l\fR and \fB-F\fR options was added in the Solaris 7 release. .sp .LP The \fBpmap\fR command, with support for the \fB-r\fR and \fB-x\fR options, was introduced in the Solaris 2.6 release.