[HPADM] RE: find - limit search

From: Shaw, Matthew (Matt.Shaw@xwave.com)
Date: Fri May 09 2003 - 07:58:08 EDT


Guy:
 
find / var -type f -mtime +1 | head -1
 
Thanks
Matt Shaw
Technical Architect
xwave, An Aliant Company
Bus: 506-389-4641 (Mctn)
Bus: 506-444-9639 (Fred)
Cel: 506-863-8949
matt.shaw@xwave.com <mailto:matt.shaw@xwave.com>

        -----Original Message-----
        From: voychry@skynet.be [mailto:voychry@skynet.be]
        Sent: Thursday, May 08, 2003 3:05 PM
        To: hpux-admin@DutchWorks.nl
        Subject: [HPADM] find - limit search
        
        
         Hi,

                I'm searching on a way to 'limit' a find command to the
first match.
                For example :
                find /var -type f -mtime +1
                This lists ALL files in var older than one day..and
gives a lot of overhead because
                i only want to find the FIRST file in that filesystem
that's older than one day..
                 
                Any ideas ?
                 
                Regards,
                Guy
                 

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:29 EDT