05-08-2008
Quote:
Originally Posted by
ystee
Is there a simple command to find or check if a file has been modified within the last minute? The mtime parameter from find cmd only allow days.
Try replacing
mtime by
mmin and don't forget to read man find.
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi All:
I'm having a problem with transferring files from a CD to my AIX machine. I don't know if I am using the mount command properly. My problem is that when I take a CD that I have burned on my PC over to my AIX machine, whent the CD is mounted the file names have been changed (a more thorough... (3 Replies)
Discussion started by: GoEagles
3 Replies
2. UNIX for Dummies Questions & Answers
How can I tell what user last updated a file? (1 Reply)
Discussion started by: kirkm76
1 Replies
3. Shell Programming and Scripting
Hi
I have many file initial size zero(empty) after some munipulation , one or more file will be greater than zero. I need to send those file names if they return to zero again.
Ex.
Initially the files are zero size
Size filename
0 AAA
0 BBB
0 CCC
0 DDD... (1 Reply)
Discussion started by: Bluetoot
1 Replies
4. Homework & Coursework Questions
Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted!
1. The problem statement, all variables and given/known data:
The program should search all files in current directory and it's subdirectories and list out the newest file by... (8 Replies)
Discussion started by: petel1
8 Replies
5. Shell Programming and Scripting
Hey guy's,
How can I schedule this script using AWK, what I require is it runs every minute as new data will be added to the file? And I need to capture these data and save it to the output file.
I tried using sleep 1 to allow the file to be processed but is not working.
awk '
... (35 Replies)
Discussion started by: James_Owen
35 Replies
6. Shell Programming and Scripting
Anyone knows how to use AWK to achieve the following
Sun Feb 12 00:41:01-00:41:59 Success:2 Fail:2
Sun Feb 12 00:42:01-00:42:59 Success:1 Fail:2
Sun Feb 12 01:20:01-01:20:59 Success:1 Fail:2
Mon Feb 13 22:41:01-22:41:59 Success:1 Fail:1
log file:
Success
Success
Fail
Fail
... (9 Replies)
Discussion started by: timmywong
9 Replies
7. Shell Programming and Scripting
Hi, I've been trying to develop a script that performs the parsing of a log every 1 minute and then generating some statistics. I'm fairly new to programming and this is why I come to ask if I can lend a hand.
this is my log:
xxxx 16/04/2012 17:00:52 - xxxx714 - E234 - Time= 119 ms.... (8 Replies)
Discussion started by: jockx
8 Replies
8. Shell Programming and Scripting
Hi All,
I have to work in the late nights some times for server maintenance and in a hurry to complete I am accidentally changing ownership or permission of directories :(
which have similar names ( /var in root and var of some other directory ).:confused:
Can some one suggest me with the... (1 Reply)
Discussion started by: shiek.kaleem
1 Replies
9. Shell Programming and Scripting
Hi All,
Need your help on how i can sum up the values. I have a file that contains the count and the time. I wanted to add up all the first column having the same datestamp. Please see below.
INPUT
1721 2015-12-26 00:01
1440 2015-12-26 00:02
1477 2015-12-26 00:02
411 ... (4 Replies)
Discussion started by: ernesto
4 Replies
10. Shell Programming and Scripting
Hello,
I have a list of files, an example below:
-rw-r--r-- 1 smf_oper esg 910773 Jul 6 12:52 am1slc02_ACS_201607061242571_20346.cdr
-rw-r--r-- 1 smf_oper esg 995838 Jul 6 12:52 am1slc01_ACS_201607061243125_19895.cdr
-rw-r--r-- 1 smf_oper esg 557235 Jul 6 12:52... (5 Replies)
Discussion started by: nms
5 Replies
GMMKTIME(3) 1 GMMKTIME(3)
gmmktime - Get Unix timestamp for a GMT date
SYNOPSIS
int gmmktime ([int $hour = gmdate("H")], [int $minute = gmdate("i")], [int $second = gmdate("s")], [int $month = gmdate("n")], [int
$day = gmdate("j")], [int $year = gmdate("Y")], [int $is_dst = -1])
DESCRIPTION
Identical to mktime(3) except the passed parameters represents a GMT date. gmmktime(3) internally uses mktime(3) so only times valid in
derived local time can be used.
Like mktime(3), arguments may be left out in order from right to left, with any omitted arguments being set to the current corresponding
GMT value.
PARAMETERS
o $hour
- The number of the hour relative to the start of the day determined by $month, $day and $year. Negative values reference the hour
before midnight of the day in question. Values greater than 23 reference the appropriate hour in the following day(s).
o $minute
- The number of the minute relative to the start of the $hour. Negative values reference the minute in the previous hour. Values
greater than 59 reference the appropriate minute in the following hour(s).
o $second
- The number of seconds relative to the start of the $minute. Negative values reference the second in the previous minute. Values
greater than 59 reference the appropriate second in the following minute(s).
o $month
- The number of the month relative to the end of the previous year. Values 1 to 12 reference the normal calendar months of the
year in question. Values less than 1 (including negative values) reference the months in the previous year in reverse order, so 0
is December, -1 is November, etc. Values greater than 12 reference the appropriate month in the following year(s).
o $day
- The number of the day relative to the end of the previous month. Values 1 to 28, 29, 30 or 31 (depending upon the month) refer-
ence the normal days in the relevant month. Values less than 1 (including negative values) reference the days in the previous
month, so 0 is the last day of the previous month, -1 is the day before that, etc. Values greater than the number of days in the
relevant month reference the appropriate day in the following month(s).
o $year
- The year
o $is_dst
- Parameters always represent a GMT date so $is_dst doesn't influence the result.
Note
This parameter has been removed in PHP 7.0.0.
RETURN VALUES
Returns a integer Unix timestamp.
CHANGELOG
+--------+---------------------------------------------------+
|Version | |
| | |
| | Description |
| | |
+--------+---------------------------------------------------+
| 7.0.0 | |
| | |
| | $is_dst parameter has been removed. |
| | |
| 5.1.0 | |
| | |
| | As of PHP 5.1.0, the $is_dst parameter became |
| | deprecated. As a result, the new timezone han- |
| | dling features should be used instead. |
| | |
+--------+---------------------------------------------------+
EXAMPLES
Example #1
gmmktime(3) basic example
<?php
// Prints: July 1, 2000 is on a Saturday
echo "July 1, 2000 is on a " . date("l", gmmktime(0, 0, 0, 7, 1, 2000));
?>
SEE ALSO
mktime(3), date(3), time(3).
PHP Documentation Group GMMKTIME(3)