2:27 AM Time command in Linux to give resource usage |
|
TIME a simple command to give resource usage in Linux system FORMAT DESCRIPTION These statistics consist of real time and CPU time
The CPU time is divided into user time and system time User time :- time used by the program itself and any library subroutines it calls
Example:
In above example the "ll" command was executed and its time statistics is displayed. GNU Options -p, --portability real %e
Descriptions are as given below: %E Elapsed real time (in [hours:]minutes:seconds). %e (Not in tcsh.) Elapsed real time (in seconds). %S Total number of CPU-seconds that the process spent in kernel mode. %U Total number of CPU-seconds that the process spent in user mode. %P Percentage of the CPU that this job got, computed as (%U + %S) / %E. -o FILE, --output=FILE -a, --append
The TIME command is also used for resources like memory, I/O and IPC calls (where available). The output is formatted using a format string that can be specified using the -f option or the TIME environment variable.
Note: some shells (e.g., bash(1)) have a built-in time command that provides less functionality than the command described here. To access the real command, you may need to specify its pathname (something like /usr/bin/time). You may also like to see: |
|
|
Related blogs
You may also like to see:
| [2015-06-01] | [Open System-Linux] |
DIG command : A DNS lookup utility | |
| [2014-09-24] | [Open System-Linux] |
Set, unset, display shell behaviour options : SHOPT command in Linux | |
| [2016-03-18] | [Open System-Linux] |
Some amazing command shortcuts in Linux | |
| [2017-08-13] | [Open System-Linux] |
Perl trick to remove Ctrl - M charater from a file | |
| [2014-02-27] | [Open System-Linux] |
RSYNC : A command in linux to copy files remotely. Faster and more flexible than rcp | |
| Total comments: 0 | |
DIG command : A DNS lookup utility
Set, unset, display shell behaviour options : SHOPT command in Linux
Some amazing command shortcuts in Linux
Perl trick to remove Ctrl - M charater from a file
RSYNC : A command in linux to copy files remotely. Faster and more flexible than rcp