Sponsored Content
Top Forums Shell Programming and Scripting Mtime or the equivalent for HP-UX Post 303031165 by danielshell on Friday 22nd of February 2019 10:00:00 AM
Old 02-22-2019
I have tried a couple of things, but am still in the dark.

Code:
prod:/# which mtime
no mtime

lpstat -o |grep -v bytes |sort -nkb1 has to be run, so it seems a filter has to be plugged in...

The output of lpstat -o |grep -v bytes |sort -nkb1 is shown like below:

Code:
prod:/# lpstat -o |grep -v bytes |sort -nkb1
653e-8022           prod         priority 1  Feb 22 08:42 
850wb-1934          prod         priority 1  Feb 21 07:51 on 850wb
f01l-2151           prod         priority 1  Feb 21 08:17
f01l-2154           prod         priority 1  Feb 21 08:18
f01l-2159           prod         priority 1  Feb 21 08:20
f01l-2169           prod         priority 1  Feb 21 08:20
f01l-3931           prod         priority 1  Feb 21 12:06
f01l-7075           prod         priority 1  Feb 20 07:29
f01l-7079           prod         priority 1  Feb 20 07:29
f01l-7589           prod         priority 1  Feb 22 07:12
f01l-7592           prod         priority 1  Feb 22 07:13
f01l-7604           prod         priority 1  Feb 22 07:16
f01l-7627           prod         priority 1  Feb 22 07:18
f01l-7632           prod         priority 1  Feb 22 07:21
f01l-7642           prod         priority 1  Feb 22 07:22
f01l-7673           prod         priority 1  Feb 22 07:30
f01l-7675           prod         priority 1  Feb 22 07:32
f01l-7694           prod         priority 1  Feb 22 07:35
f01l-7709           prod         priority 1  Feb 22 07:38
f01l-7713           prod         priority 1  Feb 22 07:40
f01l-9315           prod         priority 1  Feb 20 13:51
f01l-9332           prod         priority 1  Feb 20 13:52
f01l-9333           prod         priority 1  Feb 20 13:53

Is there any way that 3 days filtered so that |awk {'print $1'} > prtlist can greb the ones older than 3 days?

Thank you!!
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

mtime vs ctime

:D i have a slight problem and would appreciate if someone could clarify the confusion.. i use find alot and so far i have done ok.. but it just struck me a couple of days ago that I am not quite sure what the difference between the modification time and the change time as in ctime and mtime and... (3 Replies)
Discussion started by: moxxx68
3 Replies

2. UNIX for Dummies Questions & Answers

find . -mtime

...what am i doing wrong?? I need to find all files older than 30 days and delete but I can't get it to pull details for ANY + times. The file below has a time stamp which is older than 1 day, however if I try and select it using any of the -time flags it just doesn't see it. (the same thing... (1 Reply)
Discussion started by: topcat8
1 Replies

3. UNIX for Dummies Questions & Answers

mtime help!!!!!

thank you for the help. (2 Replies)
Discussion started by: scooter17
2 Replies

4. Shell Programming and Scripting

mtime

hi, :) consider the following statement find . -type f -mtime -1 -print here what is the use of -1 option. any help? cheers RRK (7 Replies)
Discussion started by: ravi raj kumar
7 Replies

5. UNIX for Dummies Questions & Answers

-mtime +30

Hello, Can someone help me to understand the following: find /test/rman/ -mtime +30 -exec rm '{}' \; What does -mtime +30 mean? Thanks! (1 Reply)
Discussion started by: Blue68
1 Replies

6. Shell Programming and Scripting

mtime

Hi, I've some files of some past days and everyday some new files are also getting added to the same. Now how can i use mtime to get the files of the current date i.e if i want the files of 25th feb 2009 and if im finding the files on 25th 12:10 am then i should only get the files after... (4 Replies)
Discussion started by: ss_ss
4 Replies

7. UNIX for Dummies Questions & Answers

(find) mtime vs. (unix) mtime

Hi I've made some test with perl script to learn more about mtime... So, my question is : Why the mtime from findfind /usr/local/sbin -ctime -1 -mtime -1 \( -name "*.log" -o -name "*.gz" \) -print are not the same as mtime from unix/linux in ls -ltr or in stat() function in perl : stat -... (2 Replies)
Discussion started by: hiddenshadow
2 Replies

8. Shell Programming and Scripting

find -mtime +7

Dear all, find $ADMIN_DIR/$SID/arch/ -name '*.gz' -mtime +7 -exec rm {} \; is it retaining 7 days OR 8 days .gz files ? Thanks Prakash (10 Replies)
Discussion started by: prakashoracledb
10 Replies

9. Red Hat

-mtime command

Hello, what this command do. find /oracle/u01/app/oracle/admin/rdz/udump/ -name "*.trc" -mtime +1 Thanks, Umair (1 Reply)
Discussion started by: umair
1 Replies

10. Shell Programming and Scripting

Mtime issue

Dear all, i am trying to find all files created one day before, for example 26 October, and i am using this command: find . -type f -daystart -mtime 1 This command in fact lists all files created on 26 October, but the files between midnight 00:00 26 Oct and 01:00 26 Oct, does not shown... (4 Replies)
Discussion started by: arrals_vl
4 Replies
math(n) 							 Tcl Math Library							   math(n)

NAME
math - Tcl Math Library SYNOPSIS
package require Tcl 8.2 package require math ?1.2? ::math::cov value value ?value ...? ::math::integrate list of xy value pairs ::math::fibonacci n ::math::max value ?value ...? ::math::mean value ?value ...? ::math::min value ?value ...? ::math::prod value ?value ...? ::math::random ?value1? ?value2? ::math::sigma value value ?value ...? ::math::stats value value ?value ...? ::math::sum value ?value ...? DESCRIPTION
The math package provides utility math functions. COMMANDS
::math::cov value value ?value ...? Return the coefficient of variation expressed as percent of two or more numeric values. ::math::integrate list of xy value pairs Return the area under a "curve" defined by a set of x,y pairs and the error bound as a list. ::math::fibonacci n Return the n'th Fibonacci number. ::math::max value ?value ...? Return the maximum of one or more numeric values. ::math::mean value ?value ...? Return the mean, or "average" of one or more numeric values. ::math::min value ?value ...? Return the minimum of one or more numeric values. ::math::prod value ?value ...? Return the product of one or more numeric values. ::math::random ?value1? ?value2? Return a random number. If no arguments are given, the number is a floating point value between 0 and 1. If one argument is given, the number is an integer value between 0 and value1. If two arguments are given, the number is an integer value between value1 and value2. ::math::sigma value value ?value ...? Return the population standard deviation of two or more numeric values. ::math::stats value value ?value ...? Return the mean, standard deviation, and coefficient of variation as percent as a list. ::math::sum value ?value ...? Return the sum of one or more numeric values. KEYWORDS
math, statistics math 4.2 math(n)
All times are GMT -4. The time now is 04:05 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy