- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- find command - how to exclude subdirectories and f...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2003 01:34 PM
06-19-2003 01:34 PM
Here's what I have so far:
find /tmp -name \* -a -mtime +48 -print
Any help would be appreciated.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2003 01:40 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2003 01:40 PM
06-19-2003 01:40 PM
Re: find command - how to exclude subdirectories and files within subdirectories
find /tmp -path "/tmp/*" -prune -mtime +48 -print
HTH
-- Rod Hills
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2003 01:42 PM
06-19-2003 01:42 PM
Re: find command - how to exclude subdirectories and files within subdirectories
# find /tmp -prune -type f -mtime +2 -exec ll {} \; > /tmp/old_files
Also, please note that the number given with mtime is calculated in days and not hrs.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2003 01:48 PM
06-19-2003 01:48 PM
Re: find command - how to exclude subdirectories and files within subdirectories
First, if you really mean 2-days then the -mtime argument should be +2 not +48 :-))
Use this:
# cd /tmp
# find . -path "./*" -prune -type f -mtime +2 -exec ls -l {} \;
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-19-2003 01:52 PM
06-19-2003 01:52 PM
Re: find command - how to exclude subdirectories and files within subdirectories
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0xb2f95f260cafd4118fef0090279cd0f9,00.html