times(1) User Commands times(1)NAME
times - shell built-in function to report time usages of the current shell
SYNOPSIS
sh
times
ksh
times
DESCRIPTION
sh
Print the accumulated user and system times for processes run from the shell.
ksh
Print the accumulated user and system times for the shell and for processes run from the shell.
On this man page, ksh(1) commands that are preceded by one or two * (asterisks) are treated specially in the following ways:
1. Variable assignment lists preceding the command remain in effect when the command completes.
2. I/O redirections are processed after variable assignments.
3. Errors cause a script that contains them to abort.
4. Words, following a command preceded by ** that are in the format of a variable assignment, are expanded with the same rules as a vari-
able assignment. This means that tilde substitution is performed after the = sign and word splitting and file name generation are not
performed.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsu |
+-----------------------------+-----------------------------+
SEE ALSO ksh(1), sh(1), time(1), attributes(5)SunOS 5.10 15 Apr 1994 times(1)
Check Out this Related Man Page
times(1) User Commands times(1)NAME
times - shell built-in function to report time usages of the current shell
SYNOPSIS
sh
times
ksh
times
DESCRIPTION
sh
Print the accumulated user and system times for processes run from the shell.
ksh
Print the accumulated user and system times for the shell and for processes run from the shell.
On this man page, ksh(1) commands that are preceded by one or two * (asterisks) are treated specially in the following ways:
1. Variable assignment lists preceding the command remain in effect when the command completes.
2. I/O redirections are processed after variable assignments.
3. Errors cause a script that contains them to abort.
4. Words, following a command preceded by ** that are in the format of a variable assignment, are expanded with the same rules as a vari-
able assignment. This means that tilde substitution is performed after the = sign and word splitting and file name generation are not
performed.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsu |
+-----------------------------+-----------------------------+
SEE ALSO ksh(1), sh(1), time(1), attributes(5)SunOS 5.10 15 Apr 1994 times(1)
Hi All,
I have a problem with using the find command.In my file structure,I need to find files that are exactly 14days old to execute an archive script.I used the "find . -mtime 14" command which displays 14day old files.The problem,however,is I get files that are more than 14days .For example... (19 Replies)
I am trying to substitute words within multiple files...I posted the first script (https://www.unix.com/showthread.php?t=37505) in tcsh and still for some reason getting nowhere so I tried it in ksh.
#!/bin/ksh
pattern1=$1
pattern2=$2
if ]
then
print "Usage: $0 $pattern1 $pattern2"
exit... (25 Replies)
i need to output an ls command to a file but also capture any errors from that command and output them to a log file and the screen.
if it's only possible to output them to a log file and not the screen then that's fine.
this is what i've tried so far, but it won't populate log.txt. i've... (16 Replies)
Hi ,
as others users here , i'm searching for a script which can automate "passwd" dialog .
I saw threads about "expect tool" but on my platforms , "C" product isn't installed and i'm not the admin so i can't install it.
is there another way to do it , with a "simple" shell script ???
... (35 Replies)
i have a shell script(report.ksh) where i am supposed to redirect the output of whence to a log file.
but when i am doing so im gettin an error
whence: command not found
when i execute the same command on the command prompt i am gettin the output.
can anyone tell me how to... (19 Replies)
#!/bin/sh
count=0
for i in 2 4 6
do
echo "i is $i"
count='expr $count + 1'
done
echo "The loop was executed $count times"
with these scripts
my output is :
i is 2
i is 4
i is 6
The loop was executed expr $count + 1 times
What should I do to get the value instead of 'expr... (17 Replies)
Hi,
How to restrict access to a .ksh script in such the way that the users can only execute the script, neither read nor write.
I tried the below code so that my user alone has the rwx and other users can only execute.
chmod 711 sample.ksh
But when I logged in as a different user... (26 Replies)
Hi,
I have a separate file with a ksh function in it. When I try to run it, I get an error about permissions:
user@~/scripts/functions$ ksh f_fill_testfunc
ksh: f_fill_testfunc: cannot open
user@~/scripts/functions$ ls -l batch_functions/f_fill_testfunc
-rwxr-xr-x 1 user user 1105 Aug... (18 Replies)
Hi
I have the following code which was supposed to clean up a directory when the number of files in that directory exeeded 2.The code is given below.
#!/usr/bin/ksh
dir_num=`/usr/bin/find /var/.audit -type d | /usr/bin/wc -l`
if
then
oldest_file=`/usr/bin/ls -1t | /usr/bin/tail... (19 Replies)
Hi, I have 2 statements in a file
a.sh start time is Fri Jan 9 17:17:33 CST 2015
a.sh end time is Fri Jan 9 17:47:33 CST 2015
I am required to get only the time out of it. like
17:17:33 & 17:47:33
PLs suggest (21 Replies)
I need to concatenate the rows that are broken (because of carriage return and line feed) in unix.
Input
123|456|789|""
987|786|"GRT
"|""
3455|896|654|456|""
457|234|"RT"|"PR
TY"|""
Output
123|456|789|""
987|786|"GRT"|""
3455|896|654|456|""
457|234|"RT"|"PRTY"|"" (16 Replies)
I am new to grep and Linux and am looking to see if grep can parse out a list of lines that have a difference of more than 10 seconds between the times on each line.
Example
2016-09-17 19:30:57 INFO: id: 4562079216, time: 2016-09-17 19:30:41,
2016-09-17 12:02:26 INFO: id:... (26 Replies)
Hi. I'd like to remove all values in a string variable that also exist in a second variable. What is the appropriate approach to take here? I can use a 'For' loop and check each element and then populate a new string. But is there a cleaner, simpler way?
E.g. I have the following 2 variables ... (19 Replies)