- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: HPUX 11, how to find most recent created file
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
Discussions
Discussions
Discussions
Forums
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
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
тАО02-04-2007 10:26 PM
тАО02-04-2007 10:26 PM
HPUX 11, how to find most recent created file
Thanks
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 10:32 PM
тАО02-04-2007 10:32 PM
Re: HPUX 11, how to find most recent created file
maybe you can try this:
touch
find
Hth
regards
pg
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 10:33 PM
тАО02-04-2007 10:33 PM
Re: HPUX 11, how to find most recent created file
regards,
ivan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 10:35 PM
тАО02-04-2007 10:35 PM
Re: HPUX 11, how to find most recent created file
and welcome to the forums !
Please see this earlier thread:
http://forums1.itrc.hp.com/service/forums/questionanswer.do?threadId=1037903
ls -lrt would list the files in a directory in reverse time order, but you are after a whole moiunt-pount, so the solution will have to include find.
Please also read:
http://forums1.itrc.hp.com/service/forums/helptips.do?#33 on how to reward any useful answers given to your questions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 11:01 PM
тАО02-04-2007 11:01 PM
Re: HPUX 11, how to find most recent created file
when i run find MP -type f -newer MP/newfile -exec ls -l{}\;
I get error -exec not terminated with ";"
Please advise
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 11:06 PM
тАО02-04-2007 11:06 PM
Re: HPUX 11, how to find most recent created file
you need a space between -l and the brackets and a space between brackets and backslash.
ls -l {} \;
^ ^
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 11:38 PM
тАО02-04-2007 11:38 PM
Re: HPUX 11, how to find most recent created file
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 11:42 PM
тАО02-04-2007 11:42 PM
Re: HPUX 11, how to find most recent created file
This command will display the 10 largest files under /path which were modified less than 3 days ago:
# find /path -type f -mtime -3 -exec ll \+ | sort -rn -k5 | head -n 10
Feel free to experiment with different values until you get a useful result. Note that UNIX has no notion of when a file was created. It is possible to infer this from a file's mtime (last modified timestamp) provided that the file has not be modified since its creation.
PCS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 11:44 PM
тАО02-04-2007 11:44 PM
Re: HPUX 11, how to find most recent created file
# find /path -type f -mtime -3 -exec ll \+ | sort -rn -k5 | head -n 10 > /tmp/find.out
Then to read it:
# more /tmp/find.out
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-04-2007 11:47 PM
тАО02-04-2007 11:47 PM
Re: HPUX 11, how to find most recent created file
Paul
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-05-2007 01:27 AM
тАО02-05-2007 01:27 AM
Re: HPUX 11, how to find most recent created file
before you close this thread, summarising the solution, could you please read:
http://forums1.itrc.hp.com/service/forums/helptips.do?#28 onwards on how to reward any useful answers given to your questions.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-05-2007 01:31 AM
тАО02-05-2007 01:31 AM
Re: HPUX 11, how to find most recent created file
Job Done
Paul