Process and Memory Management Commands
on Cisco IOS-XR Software
This chapter describes the commands used to manage pro cesses and me mory on the
Cisco IOS-XR software.
Cisco IOS-XR System Management Command Reference
SMR-273
monitor processes
monitor processes
To display auto-updating statistics on processes in a full-screen mode, use the monitor processes
command in EXEC mode.
monitorprocesses [dumbtty] [locationnode-id]
Process and Memory Management Commands on Cisco IOS-XR Software
Syntax Description
DefaultsIf you omit all keywords, the command displays the top 10 processes of CPU usage for the local node,
Command ModesEXEC
Command History
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
dumbtty(Optional) Displays the output of the command as if on a dumb terminal (the
screen is not refreshed).
locationnode-id(Optional) Displays the output of the command from the designated node.
The node-id argument is entered in the rack/slot/module notation.
sorted in descending order by the time used. The display is cleared and updated every 5 seconds until
you quit the monitor processes command by entering the q key.
ReleaseModification
Release 2.0This command was introduced.
task IDs. For detailed information about user groups and t ask IDs, refer to the Conf iguring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
This command shows the top 10 processes of CPU usage. The display refreshes every 10 seconds.
• To change the parameters displayed by the monitor processes command, ente r one of th e key
commands described in Table 14.
SMR-274
• To terminate the display and return to the system prompt, enter the q key.
• To list the interactive commands, type ? during the display. Example:
The options are described in Table 14.
Table 14Interactive Disp lay Commands for the monitor processes Command
Command Description
?Display or print the interactive commands.
qQuits the monitor processes display and returns to the system prompt.
nChanges the number of processes to be displayed.
dChanges the delay interval between updates.
lRefreshes the screen.
tSorts display by time (default).
Cisco IOS-XR System Management Command Reference
Process and Memory Management Commands on Cisco IOS-XR Software
Tabl e 14Interactive Display Commands for the monitor processes Command (continued)
Command Description
mSorts display by memory used.
cSorts display by number of open channels.
fSorts display by number of open files.
When the n or d interactive command is used, the monitor processes command prompts you to enter a
number. Fo r example, when the interactive command n is entered, the prompt responds as shown belo w:
DefaultsWhen all keywords are omitted, the command displays the first ten threads for the local node, sorted in
Command ModesEXEC
Command History
dumbtty(Optional) Displays the output of the command as if on a dumb
terminal (the screen is not refreshed).
iterationnumber(Optional) Number of times the statistics display is to be updated, in
the range from 0 to 4294967295.
locationnode-id(Optional) Displays the output from the command from the designated
node. The node-id argument is entered in the rack/slot/module
notation.
descending order by the time used. The display is cleared and updated every 5 seconds until you quit the
monitor command.
ReleaseModification
Release 2.0This command was introduced.
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
task IDs. For detailed information about user gr oups and task IDs, refer to the Config uring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
This command shows the top 10 threads based on CPU usage . The displa y refreshes every 10 seconds.
• To change the parameters di splayed by the monitor threads command, enter one of the key
commands described in Table 15.
• To terminate the display and return to the system prompt, enter the q key.
• To list the interactive commands, type ? during the display. Example:
The options are described in Table 15.
Tabl e 15Interactive Display Commands for the monitor threads Command
Command Description
qQuits the interactive display and returns to the system prompt.
nChanges the number of threads to be displayed.
Cisco IOS-XR System Management Command Reference
SMR-277
monitor threads
Tabl e 15Interactive Display Commands for the monitor threads Command (continued)
Command Description
dChanges the delay interval between updates.
lRefreshes the screen.
When the n or d interactive command is used, the monitor threads command prompts for a number
appropriate to the specific interactive command. The following is sample output from the monitor threads command showing the use of the interactive command n after the first display cycle to change
the number of threads:
Enter number of threads to display: 3
Please enter a number between 5 and 40
Enter number of threads to display: 8
87 processes; 249 threads;
CPU states: 95.3% idle, 2.9% user, 1.7% kernel
Memory: 256M total, 175M avail, page size 4K
blockedCollects debug information. The node will be restarted if the mandatory reboot
flag is set.
killKills (stops) a process. The process will not be restarted even if considered
“mandatory”.
restartRestarts a process.
startStarts a process.
executable-name(Optional) Performs the action for all the simultaneously executing instances of
the process, if applicable.
job-id(Optional) Performs the action for only the process instance associated with the
job-id.
locationnode-id(Optional) Specifies a node. The node-id argument is entered in the
rack/slot/module notation.
locationall(Optional) Specifies all nodes.
Command History
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
CautionManually killing or restarting a process can seriously impact the operation of a router. Use these
Cisco IOS-XR System Management Command Reference
SMR-280
ReleaseModification
Release 2.0This command was introduced.
task IDs. For detailed information about user groups and t ask IDs, refer to the Conf iguring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
Under normal circumstances, processes are started and restarted automatically by the operating system
as required. If a process crashes, it will be automatically restarted.
You can also use the process commands to manually stop, start or restart individual processes. These
commands should be used only under the supervision of a Cisco support representative because they can
cause a loss of router operations.
commands only under the direction of a Cisco technical support representative.
Process and Memory Management Commands on Cisco IOS-XR Software
process kill
The process kill command will shut down (terminate) the specified process and copies associated with
the specified process. The process is not restarted, even if considered “mandatory.” Use the show processes command to display a list of executable processes running on the system.
CautionKilling a process can result in an RP failover, system failure or both. This command is intended for use
only under the direct supervision of a Cisco technical support representative.
process restart
The process restart command is used to restart a process, such as a process that is not functioning
optimally.
process start
The process start command starts a process that is not currently running, such as a process that was
terminated using the process kill command. If multiple copies are on the system, all instances of the
process will be started simultaneously.
process blocked
This command is used by Cisco support representatives to collect debug infor mat ion ab out a process. If
the mandatory command is set for a process, the process blocked command will also cause the node to
restart.
process
ExamplesIn the following example, the OSPF process is restarted with the process restart. command:
executable-nameExecutable name of the process for which you want to change core
dump options. Specifying an executable-name va lue changes the core
dumping option for multiple instances of a running process.
job-idJob ID associated with the process instance. Specifying a job-id value
changes the core dumping option for only a single instance of a
running process.
coreIndicates a core dump option change for the specified process.
mainmemDumps the main memory of a crashed process.
mainmem-sharedmemDumps the main memory and the shared memory of a crashed process.
mainmem-textDumps the main memory and text of a crashed process.
mainmem-text-sharedmemDumps the main memory, shared memory and text of a crashed
process.
sharedmemDumps the shared memory of a crashed process.
copyCopies a core dump locally before performing the core dump.
offIndicates that a core dump will not be taken upon the termination of
the specified process.
maxcore value(Optional) Maximum number of core dumps allowed for the specif ied
process since its creation.
location node-id(Optional) Sets the core dump options to a designated node. The
node-id argument is entered in the rack/slot/module notation.
DefaultsBy default, processes are configured to dump shared memory, text area, stack, data section and heap.
Command ModesEXEC
Command History
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
Cisco IOS-XR System Management Command Reference
SMR-282
ReleaseModification
Release 2.0This command was introduced.
task IDs. For detailed information about user groups and t ask IDs, refer to the Conf iguring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
The modular architecture of the Cisco IOS-XR software allows core dumps for individual pr ocesses. By
default, processes are configured to dump shared memory, text area, stack, data section and heap.
Process and Memory Management Commands on Cisco IOS-XR Software
process core
Specifying the process name (executable-nam e) changes the core dumping option for all instances of the
process. Specifying a job-id value changes the core dumping option for a single instance of a running
process.
ExamplesIn the following example, the process core command is used to enable dumping of main memory and
shared memory:
RP/0/RP1/CPU0:router# process ospf core mainmem-sharedmem
In the following example, the process core command is used to turn off core dumping for a process:
RP/0/RP1/CPU0:router# process media_ether_config_di core off
Core dumping is turned back on by specifying the type of core dump for a process, as shown in the
following example:
RP/0/RP1/CPU0:router# process media_ether_config_di core mainmem-text-sharedmem
Related CommandsCommandDescription
show processesDisplays information about processes.
Cisco IOS-XR System Management Command Reference
SMR-283
process mandatory
process mandatory
T o set the mandatory reboot optio ns for a process, use the pr ocess mandatory command in EXEC mode.
process mandatory
process mandatory {on | off} {executable-name | job-id} [location node-id]
process mandatory reboot
process mandatory reboot {enable | disable}
process mandatory toggle
process mandatory toggle {executable-name | job-id} [location node-id]
Process and Memory Management Commands on Cisco IOS-XR Software
Syntax Description
DefaultsNo default behavior or values
Command ModesEXEC
Command History
onTurns on mandatory process attribute.
offTurns off the mandatory process attribute. The process will not be
considered mandatory.
rebootEnables or disables the reboot action when mandatory process fails.
toggleToggles mandatory process attribute
executable-nameExecutable name of the process you want to terminate. Terminates the
process and all the simultaneously executing copies, if applicable.
job-idJob ID associated with the process you want to terminate. Terminat es only
the process associated with the job ID.
locationnode-id(Optional) Sets the mandatory settings for a process on a designated node.
The node-id argument is entered in the rack/slot/module notation.
ReleaseModification
Release 2.0This command was introduced.
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
task IDs. For detailed information about user groups and t ask IDs, refer to the Conf iguring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
If a process unexpectedly goes down, the following action will occur based on whether the process is
considered “mandatory.”
• If the process is mandatory, and the process cannot be restarted, the node will automatically reboot.
Cisco IOS-XR System Management Command Reference
SMR-284
Process and Memory Management Commands on Cisco IOS-XR Software
• If the process is not mandatory and cannot be restarted, it will stay down and the node will not
reboot.
process mandatory
Examples
Turning the mandatory attribute on or off for a process
In the following e xample, the mandator y attribute is turned on for the “media_ether _conf ig _di” pro cess:
RP/0/RP1/CPU0:router# process mandatory on media_ether_config_di
Turning the reboot option on or off with the process mandatory reboot command
In the following example, the system is set to reboot the node if a mandatory process goes down and
cannot be restarted:
RP/0/RP1/CPU0:router# process mandatory reboot enable
RP/0/RP1/CPU0:Mar 19 19:28:10 : sysmgr[71]: %SYSMGR-4-MANDATORY_REBOOT_ENABLE :
mandatory reboot option enabled by request
In the following example, the system is set not to reboot t he node if a mand atory pr ocess goes down and
cannot be restarted. In this case, the mandatory process will be restarted, but the node will not ne
rebooted.
RP/0/RP1/CPU0:router# process mandatory reboot disable
RP/0/RP1/CPU0:Mar 19 19:31:20 : sysmgr[71]: %SYSMGR-4-MANDATORY_REBOOT_OVERRIDE
: mandatory reboot option overridden by request
Related CommandsCommandDescription
show processesDisplays information, attributes and settings for a processes.
Cisco IOS-XR System Management Command Reference
SMR-285
show memory
show memory
To display the av ailable physical memory on the networking device and the memory usage of processes
on the networking device, use the show memory command in EXEC mode.
Process and Memory Management Commands on Cisco IOS-XR Software
show memory [job-id | location node-id | summary]
Syntax Descriptionl
job-id(Optional) Displays the memory available and memory usage information for
only the process associated with this job identifier. If the job-id argument is not
specified, this command displays information for all running processes.
locationnode-id(Optional) Displays the available physical memory from the designated node.
The node-id argument is entered in the rack/slot/module notation.
summary(Optional) Displays only a summary of the physical memo ry and memory usage
information.
Command ModesEXEC
Command History
ReleaseModification
Release 2.0This command was introduced.
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
task IDs. For detailed information about user groups and t ask IDs, refer to the Conf iguring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
ExamplesThe following is partial sample output from the show memory command entered without keywords or
arguments:
RP/0/RP1/CPU0:router# show memory
Physical Memory:2048M total
Application Memory :1802M (1636M available)
Image:116M (bootram:116M)
Reserved:128M, IOMem:0, flashfsys:0
Total shared window:0
kernel:jid 1
Address Bytes What
0008f000 12288 Program Stack
000b2000 12288 Program Stack
Total Allocated Memory:0
Total Shared Memory:0
sbin/devc-pty:jid 68
Address Bytes What
4817f000 4096 Program Stack (pages not allocated)
48180000 516096 Program Stack (pages not allocated)
481fe000 8192 Program Stack
48200000 28672 Physical Mapped Memory
Cisco IOS-XR System Management Command Reference
SMR-286
Process and Memory Management Commands on Cisco IOS-XR Software
The following is sample output from the sho w memory command entered with t he job ID 7 to show the
memory usage information for the process associated with this job identifier:
sbin/pipe: jid 7
AddressBytesWhat
07f7c000126976Program Stack (pages not allocated)
07f9b0004096Program Stack
07f9d000126976Program Stack (pages not allocated)
07fbc0004096Program Stack
07fbe000126976Program Stack (pages not allocated)
07fdd0004096Program Stack
07fdf000126976Program Stack (pages not allocated)
07ffe0004096Program Stack
08000000122880Program Stack (pages not allocated)
0801e0008192Program Stack
0802000012288Physical Mapped Memory
080230004096Program Text or Data
080240004096Program Text or Data
0802500016384Allocated Memory
0802900016384Allocated Memory
7c001000319488DLL Text libc.dll
7e0000008192DLL Data libc.dll
show memory
Related CommandsCommandDescription
show memory heapDisplays information about the heap space for a process.
show processesDisplays information about processes, including memory usage.
Cisco IOS-XR System Management Command Reference
SMR-287
show memory heap
show memory heap
To display information about the heap space for a process, use the show memory heap command in
EXEC mode.
Process and Memory Management Commands on Cisco IOS-XR Software
Syntax Description
allocated(Optional) Displays a list of all allocated heap blocks.
dllname(Optional) Displays heaps with DLL names.
failure(Optional) Displays a summary of heap failures.
free(Optional) Displays a list of all free heap blocks.
summary(Optional) Displays a summary of the information about the heap space.
job-id Information for the process associated with this job identifier.
Command ModesEXEC
Command History
ReleaseModification
Release 2.0This command was introduced.
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
task IDs. For detailed information about user groups and t ask IDs, refer to the Conf iguring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
ExamplesThe following is sample output from the show memory heap command, specifying only the job
job-id(Optional) Displays information for only the process instance associated
with the job-id argument.
process-name(Optional) Displays information for all the simultaneously executing
instances of the process, if applicable.
abortsDisplays process aborts.
blockedDisplays details about reply/send/mutex blocked processes.
bootDisplays process boot information.
cpuDisplays CPU use per process.
distributionDisplays the distribution of processes.
dynamicDisplays process data for dynamically created processes.
failoverDisplays process failover information.
familyDisplays the process session and family information.
filesDisplays information about open files and open communication channels.
logDisplays process log.
mandatoryDisplays process data for mandatory processes.
memoryDisplays information about the text, data, and stack usage for processes.
searchpathDisplays the search path.
signalDisplays the signal options for blocked, pending, ignored, and queued
signals.
startupDisplays process data for processes created at startup
threadnameDisplays thread names.
location node-id(Optional) Displays information about the active processes from a
designated node. The node-id ar gument is entered i n the rack/sl ot/modu le
notation.
Command ModesEXEC
Command History
Usage GuidelinesTo use this command, you must be in a user group associated with a task group that includes the proper
ReleaseModification
Release 2.0This command was introduced.
task IDs. For detailed information about user gr oups and task IDs, refer to the Config uring AAA Services on Cisco IOS-XR Software module of the Cisco IOS-XR System Security Configuration Guide.
Cisco IOS-XR System Management Command Reference
SMR-291
Process and Memory Management Commands on Cisco IOS-XR Software
show processes
The show processes command displays general information on the active processes. To view more
detailed information for a process, include the job-id or process-name.
You can also use the monitor command to determine the top users of the CPU.
ExamplesThe following is partial sample output from the show processes command:
monitor processesDisplays auto-updating process statistics in a full-screen mode.
monitor threadsDisplays auto-updating process and thread statistics in a full-screen mode.
SMR-296
Cisco IOS-XR System Management Command Reference
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.