1831651 Members
2014 Online
110029 Solutions
New Discussion

timex commans

 
SOLVED
Go to solution
Shay_1
New Member

timex commans

Hi

The timex reports in seconds the elapsed time, user time, and system time spent in execution of the given command.

Could anyone explain the meaning of the "user time", and system time ?

Thanks

Shay
3 REPLIES 3
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: timex commans

Yes, it's just what it sounds like. User time is the amount of time spent in user space (e.g. your actual application) as opposed to the amount of time spent executing system (kernel) code (e.g. system (2) calls like read, write, sbrk,open, close, etc.).

If it ain't broke, I can fix that.
Sridhar Bhaskarla
Honored Contributor

Re: timex commans

Hi Shay,

User Time means the time it spent in executing user instructions while system time is the time the process spent in executing the system instructions. System mode can be viewed something like writing to a disk or buffer cache that have to be done exclusively by the kernel instructions. Examples of user mode instructions are arthmatic calculations.

-Sri
You may be disappointed if you fail, but you are doomed if you don't try
Roger Baptiste
Honored Contributor

Re: timex commans

hi,

Yes, usertime is the time CPU spent running in usermode
and systemtime is the time CPU spent in Kernel mode.
So, if you are running a purely system command , the system time will be more. If you are running a user command which does more processing of records (sorting etc ), then the user time will be more.


If you run sar , even there you can see the user and system modes being displayed.
If the system mode value is more in SAR, then we consider it a problem, since it could be due to excess memory swapping or something on which the CPU is wasting time on.

HTH
raj
Take it easy.