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
lpusers(1M)						  System Administration Commands					       lpusers(1M)

NAME
lpusers - set printing queue priorities SYNOPSIS
lpusers -d priority-level lpusers -q priority-level -u login-ID-list lpusers -u login-ID-list lpusers -q priority-level lpusers -l DESCRIPTION
The lpusers command sets limits to the queue priority level that can be assigned to jobs submitted by users of the LP print service. The first form of the command (with -d) sets the system-wide priority default to priority-level, where priority-level is a value of 0 to 39, with 0 being the highest priority. If a user does not specify a priority level with a print request (see lp(1)), the default priority level is used. Initially, the default priority level is 20. The second form of the command (with -q and -u) sets the default highest priority-level (0-39) that the users in login-ID-list can request when submitting a print request. The login-ID-list argument may include any or all of the following constructs: login-ID A user on any system system_name!login-ID A user on the system system_name system_name!all All users on system system_name all!login-ID A user on all systems all All users on all systems Users that have been given a limit cannot submit a print request with a higher priority level than the one assigned, nor can they change a request that has already been submitted to have a higher priority. Any print requests submitted with priority levels higher than allowed will be given the highest priority allowed. The third form of the command (with -u) removes any explicit priority level for the specified users. The fourth form of the command (with -q) sets the default highest priority level for all users not explicitly covered by the use of the second form of this command. The last form of the command (with -l) lists the default priority level and the priority limits assigned to users. OPTIONS
The following options are supported: -d priority-level Set the system-wide priority default to priority-level. -l List the default priority level and the priority limits assigned to users. -q priority-level Set the default highest priority level for all users not explicitly covered. -q priority-level -u login-ID-list Set the default highest priority-level that the users in login-ID-list can request when submitting a print request. -u login-ID-list Remove any explicit priority level for the specified users. EXIT STATUS
The following exit values are returned: 0 Successful completion. non-zero An error occurred. ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWpsu | +-----------------------------+-----------------------------+ SEE ALSO
lp(1), attributes(5) SunOS 5.10 19 Aug 1996 lpusers(1M)
All times are GMT -4. The time now is 05:48 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy