LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   what is the command 'time'? (https://www.linuxquestions.org/questions/linux-newbie-8/what-is-the-command-time-372493/)

buuchanh 10-12-2005 11:04 PM

what is the command 'time'?
 
hi, everybody!
When I type the 'time' command, it will appear :
real 0m0.084s
user 0m0.000s
sys 0m0.000s
I want to know the meaning of 'time, user, and sys' in the above lines.
please, help me!

Wim Sturkenboom 10-12-2005 11:15 PM

Does man time and man 2 times not give you the answer?

tkedwards 10-12-2005 11:15 PM

From man time:
Quote:

The default format string is
%Uuser %Ssystem %Eelapsed %PCPU (%Xtext+%Ddata %Mmax)k
%Iinputs+%Ooutputs (%Fmajor+%Rminor)pagefaults %Wswaps

.....
Time

%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
so real is the time that elapsed while the process was running
user is how much CPU-time it spent in user mode
sys is how much CPU-time it spent in kernel mode

sajjadc 10-13-2005 01:46 PM

plz use -help option


All times are GMT -5. The time now is 07:31 PM.