Monday, April 5, 2010

Alternative to 'top' command on Solaris

prstat Command:
prstat utility iteratively examines all active processes on the system and reports statistics based on the selected output mode and sort order. The prstat command provides output similar to the ps command.

Options for prstat Command

Option

Description

How It Can Help

No option

Displays a sorted list of the top processes that are consuming the most CPU resources. List is limited to the height of the terminal window and the total number of processes. Output is automatically updated every five seconds. Ctrl-C aborts.

Output identifies process ID, user ID, memory used, state, CPU consumption, and command name.

-n number

Limits output to number of lines.

Limits amount of data displayed and identifies primary resource consumers.

-s key

Permits sorting list by key parameter.

Useful keys are cpu (default), time, and size.

-v

Verbose mode.

Displays additional parameters.


eg: To find the top 5 process consuming CPU in Solaris
prstat -n 5 -s cpu


Ref: http://docs.sun.com/source/819-1892-12/FMASolarisCmd.html#22021

1 comment:

  1. Check out the Best Alternative of FEEDJIT in 2015
    INSTALL NOW
    1. Better Material Design
    2. Small Size Widget
    3. Track Online Visitors + Page View Counter + LIVE Feed Tracking (ALL-In-One)
    4. Track Mobile Devices which Feedjit Can't
    5. Easy to Install
    MUST TRY INSTALL NOW (Click Here)

    ReplyDelete