[HPADM] find with prune command help

From: Cruz, Alfredo (Alfredo.Cruz@cancercare.on.ca)
Date: Sat Oct 25 2003 - 18:31:53 EDT


Hi,
 
I'm having trouble getting my find command to work with the -prune option.
What I basically want to do is find *.log on a mounted file system but
exclude the directory /<filesystem>.snapshot. When I ran the command, it
still goes to the .snapshot directory which is something I don't want to
happen. The .snapshot directory is a feature of Network Appliance NAS
server which are created for each mounted file systems. It contains
snapshots of the directories and files for the file system. The .snapshot
could have been just a regular subdirectories and the find command still
doesn't work.
 
The command I used is:
find /<filesystem> -name "*.log" -print -name ".snapshot" -exec rm {} \;
 
I even tried but this didn't work either:
 
find /<filesystem> -name "*.log" -print -path /<filesystem>/.snapshot -exec
rm {} \;
 
Any suggestions?
 
Thanks,
 
Alfredo

This e-mail message (and any attachments) may contain confidential and/or
privileged information for the sole use of the intended recipient. Any
review or distribution by anyone other than the person for whom it was
originally intended is strictly prohibited. If you have received this e-mail
in error, please contact the sender and delete all copies. Opinions,
conclusions or other information contained in this e-mail may not be that of
the organization.

--
             ---> 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:35 EDT