Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

time(3f) [bsd man page]

TIME(3F)																  TIME(3F)

NAME
time, ctime, ltime, gmtime - return system time SYNOPSIS
integer function time() character*(*) function ctime (stime) integer stime subroutine ltime (stime, tarray) integer stime, tarray(9) subroutine gmtime (stime, tarray) integer stime, tarray(9) DESCRIPTION
Time returns the time since 00:00:00 GMT, Jan. 1, 1970, measured in seconds. This is the value of the UNIX system clock. Ctime converts a system time to a 24 character ASCII string. The format is described under ctime(3). No 'newline' or NULL will be included. Ltime and gmtime disect a UNIX time into month, day, etc., either for the local time zone or as GMT. The order and meaning of each element returned in tarray is described under ctime(3). FILES
/usr/lib/libU77.a SEE ALSO
ctime(3), itime(3F), idate(3F), fdate(3F) 4.2 Berkeley Distribution May 15, 1985 TIME(3F)

Check Out this Related Man Page

STIME(2)						     Linux Programmer's Manual							  STIME(2)

NAME
stime - set time SYNOPSIS
#include <time.h> int stime(time_t *t); Feature Test Macro Requirements for glibc (see feature_test_macros(7)): stime(): _SVID_SOURCE DESCRIPTION
stime() sets the system's idea of the time and date. The time, pointed to by t, is measured in seconds since the Epoch, 1970-01-01 00:00:00 +0000 (UTC). stime() may only be executed by the superuser. RETURN VALUE
On success, zero is returned. On error, -1 is returned, and errno is set appropriately. ERRORS
EFAULT Error in getting information from user space. EPERM The calling process has insufficient privilege. Under Linux the CAP_SYS_TIME privilege is required. CONFORMING TO
SVr4. SEE ALSO
date(1), settimeofday(2), capabilities(7) COLOPHON
This page is part of release 3.27 of the Linux man-pages project. A description of the project, and information about reporting bugs, can be found at http://www.kernel.org/doc/man-pages/. Linux 2010-02-25 STIME(2)
Man Page

15 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Converting regular time to CTIME

Does anyone know of an easy way to convert regular time 08/21/2002 @ 8:21:21 pm to ctime. I need this to complete a script that I am writing. Your expertise and help would be amost appreciated. Please note - I am not a programmer so c-code etc will not help. A utility that can be run from a... (9 Replies)
Discussion started by: PGPhantom
9 Replies

2. UNIX for Dummies Questions & Answers

oracle and loop question

Hi All, I have a 2 questions; 1 is oracle and another is korn shell say TIME=20060928 desired output: 20060927 say TIME=20061001 DESIRED output: 20060930 If i substract one day from 'TIME' i am looking for previous day. can anyone please suggest me how do i do this is SQL. i... (4 Replies)
Discussion started by: pavan_test
4 Replies

3. Shell Programming and Scripting

Delete 6 months old files

Hi, Iam trying to delete 6 months old files. Iam using the following script -ctime +190 -type f -exec echo rm {} \; Iam getting an error saying -ctime not found. (6 Replies)
Discussion started by: Sompalle Jalaja
6 Replies

4. AIX

AIX TIME CHANGE

Hi Guys , I see a weird problem with one of the AIX Machine, The time is changing randomly on the server. The seconds part of the time is what is the problem which is jumping on a uneven order and coming back to the original state after some time and again the same.. I have collected the time... (8 Replies)
Discussion started by: kkeng808
8 Replies

5. Shell Programming and Scripting

Please Explain me this command

find . -type f -ctime +3 -exec mv {} /somedirectory/ \; in particular "-ctime v/s -mtime" and "difference between +3 and -3" (5 Replies)
Discussion started by: Rambo
5 Replies

6. Shell Programming and Scripting

Variable TIME

Hello. I need to capture files from a server with format XXXYYYYMMDDHHMMSS.tar.gz, I have defined the DATE but how I can resolve the issue of time? Best regards. Rob (10 Replies)
Discussion started by: Robcam
10 Replies

7. Shell Programming and Scripting

[gnuwin32] sed & variable %TIME%

HI.. I made ".bat" in windows 2003 , with set TIEMPO1= %TIME% | sed -e "s/://g" -e "s/,//g" echo valor de tiempo1 = %TIEMPO1% when i execute this, the result is but if i open cmd, and execute en line command this.. G:\>echo %TIME% | sed -e "s/://g" -e "s/,//g" 12390841 anyone have... (5 Replies)
Discussion started by: upszot
5 Replies

8. Shell Programming and Scripting

find -ctime

I know that find -ctime +1 will find ALL files that have been modified that are greater than 1 day old and -ctime 1 will find files that are ONLY 1 day old -ctime -1 mean files that are less than a day old? Can find actually use this granularity? (5 Replies)
Discussion started by: BeefStu
5 Replies

9. Emergency UNIX and Linux Support

DATE TIME formatting

can anyone one help me....to make date and time format...to following format for my file Code: DATE TIME DD- MON- YEAR 24 Hours I have a need of format like this 12-Jan-2012 in one column, then time in 24 Hours in another column....please help...me... ... (7 Replies)
Discussion started by: nex_asp
7 Replies

10. AIX

PS command - TIME column is 00:00:00

Hi, I am running the following command: ps -efk -o "user pid ppid pcpu pmem stime time vsz rssize args" But TIME column is always 00:00:00 . The AIX Actual version is 6.1.8.0 When I run it on another server that I have with version 6.1.0.0, the output is valid. Regards, Amit (6 Replies)
Discussion started by: amitlib
6 Replies

11. UNIX for Dummies Questions & Answers

Ls -l displays ctime or mtime?

commands ls -l or just l displays ctime (changed time) or mtime (modified time)? (10 Replies)
Discussion started by: rupeshkp728
10 Replies

12. Shell Programming and Scripting

If then logic with TIME

Hi all, Can anyone suggest how to formulate the if/then when TIME equals a certain time, in this case 23:55:00 export TIME=`date +%T` function tnsrec { if $TIME = 23:55:00; then otherfunction else exit fi } Thanks in advance. jd (6 Replies)
Discussion started by: jonnyd
6 Replies

13. Shell Programming and Scripting

What does this mean?

Hello all, I am a newbie in shell scripting. I want to know what does the below text means? 6.355u 1.679s 0:12.68 63.2% 0+0k 0+0io 0pf+0w I am getting this line (on terminal) after every successful execution of my script. Thanks in advance . . :) -MD (15 Replies)
Discussion started by: manands07
15 Replies

14. UNIX for Dummies Questions & Answers

&& meaning in UNIX

(6 Replies)
Discussion started by: Archana Batta
6 Replies

15. Shell Programming and Scripting

How to pick system time of the file placed on UNIX?

Hi ,I got one data file from external source and I have to load it in database through sql loader. I want to add 2 columns in database,one is file name and one is time of the file received on server. -rwxr-x--- 1 user user 238 Jun 03 16:32 90936264971326030616.ctr From above case,... (21 Replies)
Discussion started by: Ruchika
21 Replies