- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- access time of files
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
11-06-2001 07:09 AM
11-06-2001 07:09 AM
Has anybody got a shell script that can tell whether a file has been accessed in the last 10 minutes and then perform and action accordingly.
Cheers in advance
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-06-2001 07:15 AM
11-06-2001 07:15 AM
Re: access time of files
Try using the find command ( man find)
it should give you the option -newer file ( just create a new file every 10 minutes).
hope this will help
Gideon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-06-2001 07:17 AM
11-06-2001 07:17 AM
Re: access time of files
touch -t 0111061615 file(YYMMDDhhmm YY are the last 2 digits of the year, MM The mounth, DD the day of the month, hh the hour and mm the minutes)
find DIR -type f -newer file -print
Federico
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-06-2001 07:21 AM
11-06-2001 07:21 AM
Re: access time of files
The option frederico gave will work just at "a" for access time.
find DIR -type f -newer a file -print
Gideon
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-06-2001 07:28 AM
11-06-2001 07:28 AM
Re: access time of files
Does anybody have a script? Does a hog like slop?
Here is my standard perl script for determining if a file has been modified,accessed, or changed in a given number of seconds.
Simply execute fileage.pl without arguments for a full usage message.
By the way, being perl, it runs on Windows as well as UNIX.
Regards, Clay
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-06-2001 07:45 AM
11-06-2001 07:45 AM
SolutionHere's one:
***
NOW=`date +%H%M`
ACC=`ll -u $1 |awk '{print $8}' |sed 's/://'`
CHECK=`"echo $ACC-$NOW"|bc`
if [ $CHECK -le 10 ]
then
echo "YES, I was peered into"
else
echo "Nobody pryed into me"
fi
***
I just typed it in. There may be some gaps in the date logic, but the flow is right.
-raj