Sponsored Content
Homework and Emergencies Homework & Coursework Questions Time command issuing all zeroes (is now considered homework help) Post 302834371 by lamentofking on Thursday 18th of July 2013 08:04:07 PM
Old 07-18-2013
It is running now. I used my installed copy of ubuntu to use the time command. However I get 3 different lines of output:

Code:
real    xmx.xxxs
user    xmx.xxxs
sys    xmx.xxxs

I do believe my assignment instructions say to sum the first two numbers but my output is different than the example in the first post. I should sum the user and sys values. So what is the number in the "real" field for? Should I ignore it for this assignment?

Last edited by Scott; 07-18-2013 at 09:07 PM.. Reason: Code tags
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Differences between time command and usr/bin/time

I wondered if someone could point out the differences between the time commmand and usr/bin/time and the accuracy one might have over another. Also, is there a website or two a person could maybe link for me to describe the differences? Thank you for your time. (2 Replies)
Discussion started by: icedrake
2 Replies

2. Programming

C: why decimals considered double by default ?

Can anybody tell me why any literal constant real numbers are double by default in C ? Why is the default not float ? (2 Replies)
Discussion started by: limmer
2 Replies

3. AIX

Background & is considered as Idle

Our Aix Unix has one issue. If I type xedit & after 30 minutes, xedit auto shut down. If I type xedit xedit will run forward. I feel this & doesn't perform as it should be. When I use &, system consider this process as idle. How to fix this issue? Does this mean unix env... (12 Replies)
Discussion started by: david_hu_66
12 Replies

4. Shell Programming and Scripting

Csh Programming Considered Harmful

I have noticed a few posts asking questions about c shell scripting these past few days. This a good read for those that currently or are thinking about writing a csh script: Csh Programming Considered Harmful (9 Replies)
Discussion started by: ilikecows
9 Replies

5. UNIX for Advanced & Expert Users

Issuing a Here Document as a Single Line Command

How can I run a here document on just one line? I ask, because I need to issue it from C++ as a system() or similar command and for security reasons I don't want to write out a shell script file from the program and run it. For example, how could I write: passwd test <<EOF n3wp3ss... (3 Replies)
Discussion started by: BrandonShw
3 Replies

6. Programming

Why is C/C++ considered low-level languages???

Hi friends, I hope everyone is doing well and fine. I have always been hearing that C/C++ are relatively low-level as compared to Java/C# etc. Could you please tell me some low-level qualities of C/C++? And I think disk deframenters are written in C/C++, please correct me if I am wrong. And please... (5 Replies)
Discussion started by: gabam
5 Replies

7. Shell Programming and Scripting

Considered basic but advanced outcome (Custom Backup Solution)

Ive a problem that I'm reaching out for help. Ive written (With bits and pieces) of script that is not running as expected or is having an issue causing processes to spiral out of control. The script does this: Unloads a UV database server Tars up a few folders Transfers the file to... (11 Replies)
Discussion started by: coastdweller
11 Replies

8. UNIX for Dummies Questions & Answers

Time command issuing all zeroes

I am trying to issue the time command on a program so I can see execution times but it is returning all zeroes. Like this: time pdriver arg1 arg2 0.000u 0.000s 0:00.00 0.0% 0+0k 0+0io 0pf+0w "0+0k 0+0io 0pf+0w" --> The "0+0io" may change sometimes to a different number. How can I run the... (2 Replies)
Discussion started by: lamentofking
2 Replies

9. Shell Programming and Scripting

Add file extensions to files EXCEPT the script that is issuing

Greetings all, On a RedHat System - I am issuing a command from script.sh that will add a file extension to a listing of files in a directory. It works, but I need to script from having an extension added as well. Here is what I have tried to no luck: for file in `ls * | awk ' /\./{print... (6 Replies)
Discussion started by: jeffs42885
6 Replies

10. UNIX for Dummies Questions & Answers

Using alias after issuing 'su - user'

Hi, Using ksh, I have set up aliases (which work fine) in my user's .profile like this: alias ll = 'ls -lrt' alias cls = 'clear' How do I call these same aliases so that they will work after issuing this: ? su - user I do not want to add aliases to the su shell's .profile or .kshrc. (7 Replies)
Discussion started by: ocbit
7 Replies
DO_SETRESUID(9) 					   BSD Kernel Developer's Manual					   DO_SETRESUID(9)

NAME
do_setresuid, do_setresgid -- set process uid and gid SYNOPSIS
#include <sys/ucred.h> int do_setresuid(struct lwp *lwp, uid_t ruid, uid_t euid, uid_t svuid, u_int flags); int do_setresgid(struct lwp *lwp, uid_t ruid, uid_t euid, uid_t svuid, u_int flags); DESCRIPTION
The do_setresuid and do_setresgid functions are used to implement the various system calls that allow a process to change its real, effec- tive, and saved uid and gid values. The do_setresuid function sets the specified processes real user ID to ruid, its effective user ID to euid, and its saved user ID to svuid. If any of the uid arguments are -1 then that assignment is skipped. If suser() is true, then any values may be assigned, otherwise the new uid values must match one of the existing values and the caller must have set the relevant bit in flags. The flags argument specifies which of the existing uid values the new value must match. It should be set to a logical OR of ID_{R,E,S}_EQ_{R,E,S}, where ID_E_EQ_R means that it is valid to set the effective ID to the current value of the real ID. The do_setresgid function sets the group IDs but otherwise behaves in the same manner as do_setresuid. The processes group list is neither examined nor effected. SEE ALSO
setregid(2), setreuid(2), setuid(2), suser(9) CODE REFERENCES
These functions are implemented in: sys/kern/kern_prot.c. HISTORY
Implemented for NetBSD 2.0 to replace ad-hoc code in each system call routine and in the various compat modules. BSD
September 28, 2003 BSD
All times are GMT -4. The time now is 11:49 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy