Re: find command tweak

Bob.Kelley_at_BRINKSINC.COM
Date: 03/12/04

  • Next message: cbaker_at_GOODYEAR.COM: "Re: find command tweak"
    Date:         Fri, 12 Mar 2004 13:29:27 -0600
    To: aix-l@Princeton.EDU
    
    

    Thanks for that. Now how to go about the compress on all the files except
    *.Z and output from that find command??? any slick ideas?

    Bobby Kelley Jr.
    972-877-5341

    |---------+----------------------------->
    | | "Harvey, Bruce T."|
    | | <BTHarvey@LMUS.LEG|
    | | GMASON.COM> |
    | | Sent by: IBM AIX |
    | | Discussion List |
    | | <aix-l@Princeton.E|
    | | DU> |
    | | |
    | | |
    | | 03/12/2004 01:12 |
    | | PM |
    | | Please respond to |
    | | IBM AIX Discussion|
    | | List |
    | | |
    |---------+----------------------------->
    >------------------------------------------------------------------------------------------------------------------------------|
      | |
      | To: aix-l@Princeton.EDU |
      | cc: |
      | Subject: Re: find command tweak |
    >------------------------------------------------------------------------------------------------------------------------------|

    what about ...

            find /archivefiles -type f -mtime +2 ! -name "*.Z" -print

    Assuming you're using 'compress' ... change to *.gz for gzip, etc.

    Bruce T. Harvey
    Legg Mason Wood Walker, Inc.
    Corporate Technology - UNIX Admin.
    Red Run 2nd Floor - Owings Mills, MD
    (410) 580-7383 - BTHarvey@LeggMason.com
    -------------------------------------------------------

    -----Original Message-----
    From: Bob.Kelley@BRINKSINC.COM [mailto:Bob.Kelley@BRINKSINC.COM]
    Sent: Friday, March 12, 2004 1:35 PM
    To: aix-l@Princeton.EDU
    Subject: find command tweak

    I'm trying to figure out a slick find and or ls command variation to do
    the following:

    I want to compress all files in "/archivefiles" with the following
    requirements:
    -files not already compressed
    -do not compress files modified in the last two days

    I was thinking something along the lines of:
    find . -type f -mtime -2 -print > /archivefiles/do_not_compress_these.out
    ls -lart|grep arch|grep -v Z|awk '{print $9}' >
    /archivefiles/all_files_list.out
    diff do_not_compress_these.out all_files_list.out >
    actual_files_to_compress.out

    Am I making this too hard?????????

    Bobby Kelley Jr.
    972-877-5341
    IMPORTANT: The security of electronic mail sent through the Internet
    is not guaranteed. Legg Mason therefore recommends that you do not
    send confidential information to us via electronic mail, including social
    security numbers, account numbers, and personal identification numbers.

    Delivery, and timely delivery, of electronic mail is also not
    guaranteed. Legg Mason therefore recommends that you do not send
    time-sensitive
    or action-oriented messages to us via electronic mail, including
    authorization to "buy" or "sell" a security or instructions to conduct any
    other financial transaction. Such requests, orders or instructions will
    not be processed until Legg Mason can confirm your instructions or
    obtain appropriate written documentation where necessary

    NOTICE TO BRINK'S EMPLOYEES:
    All electronic mail communications composed, sent, received or stored on or
    through Brink's equipment are subject to the Brink's Electronic
    Communications Policy. Employees should have no expectation of privacy in
    their use of the Company's electronic mail system.


  • Next message: cbaker_at_GOODYEAR.COM: "Re: find command tweak"

    Relevant Pages

    • Re: SMP processor activate/deactivate Command
      ... Legg Mason Wood Walker, Inc. ... Subject: SMP processor activate/deactivate Command ... The security of electronic mail sent through the Internet ...
      (AIX-L)
    • Re: for command
      ... Subject: for command ... The security of electronic mail sent through the Internet ... Legg Mason therefore recommends that you do not ... Such requests, orders or instructions will ...
      (AIX-L)
    • SMP processor activate/deactivate Command
      ... I'm blanking 'cause I haven't had to use the command in a few years and ... The security of electronic mail sent through the Internet ... Legg Mason therefore recommends that you do not ... Such requests, orders or instructions will ...
      (AIX-L)
    • Re: find command tweak
      ... That will go ahead and compress any files it finds so you don't have to run ... I'm trying to figure out a slick find and or ls command variation to do ... The security of electronic mail sent through the Internet ... Legg Mason therefore recommends that you do not ...
      (AIX-L)
    • Re: find command tweak
      ... I'm trying to figure out a slick find and or ls command variation to do ... The security of electronic mail sent through the Internet ... Legg Mason therefore recommends that you do not ... Such requests, orders or instructions will ...
      (AIX-L)