The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
command execution time hashin_p Shell Programming and Scripting 5 07-06-2008 08:28 PM
specifying an execution time VGR UNIX for Advanced & Expert Users 7 03-19-2008 05:32 AM
script execution time calculation johnsonbryce Shell Programming and Scripting 9 02-25-2006 01:33 AM
last execution time cubs0729 UNIX for Dummies Questions & Answers 1 01-20-2006 08:45 PM
execution time ramki_rk High Level Programming 2 08-27-2003 10:23 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 09-03-2008
arghya_owen arghya_owen is offline
Registered User
  
 

Join Date: May 2008
Posts: 31
time of execution of script

i want to test whether a script has been executed in last 15 days or not....please help how can i do this...is there any copmmand there to know timings of last execution of any script
  #2 (permalink)  
Old 09-03-2008
era era is offline Forum Advisor  
Herder of Useless Cats (On Sabbatical)
  
 

Join Date: Mar 2008
Location: /there/is/only/bin/sh
Posts: 3,652
The file system keeps track of last access time; it's not exactly the same thing, but might work as an approximation. Certainly if the access time is further back, it has not been executed (or read, or written to) in that time period.
  #3 (permalink)  
Old 09-03-2008
vidyadhar85's Avatar
vidyadhar85 vidyadhar85 is offline Forum Staff  
Moderator(The Tutor)
  
 

Join Date: Jun 2008
Location: INDIA
Posts: 1,400
No. You can do a ls command with -l and use the -u option but if someone did a 'cat yourscript', then the time would be when that happened versus if someone actually ran the script.
  #4 (permalink)  
Old 09-03-2008
RahulJoshi's Avatar
RahulJoshi RahulJoshi is offline
Registered User
  
 

Join Date: Aug 2008
Location: PUNE
Posts: 98
YES ls -lu is working but ,can anyone can give solution which only show last time execution on script not include cat like command.
  #5 (permalink)  
Old 09-03-2008
arghya_owen arghya_owen is offline
Registered User
  
 

Join Date: May 2008
Posts: 31
should i write----
ls -lu <script_name> or ls -l -u <script_name>

plz suggest---
  #6 (permalink)  
Old 09-03-2008
RahulJoshi's Avatar
RahulJoshi RahulJoshi is offline
Registered User
  
 

Join Date: Aug 2008
Location: PUNE
Posts: 98
ls -lu <script name> is working
  #7 (permalink)  
Old 09-03-2008
arghya_owen arghya_owen is offline
Registered User
  
 

Join Date: May 2008
Posts: 31
thanks a lot...we can do it with find & atime command also
Closed Thread

Bookmarks

Tags
linux commands

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 05:09 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0