[ From:	CRDGW2::CRDGW2::MRGATE::"SMTP::CRVAX.SRI.COM::RELAY-INFO-VAX" 16-AUG-1990 01:48:52.55  To:	MRGATE::"ARISIA::EVERHART" CC:	 Subj:	re: dir/date=read?  * Received:  by crdgw1.ge.com (5.57/GE 1.70)) 	 id AA15584; Thu, 16 Aug 90 01:31:05 EDT R Received: From UNIX.SRI.COM by CRVAX.SRI.COM with TCP; Wed, 15 AUG 90 22:04:48 PDT= Received: from yale!LRW.COM!lrw by unix.sri.com (4.1/SMI-4.0) ( 	id AA25150; Wed, 15 Aug 90 22:01:33 PDT- Received: by harvard.harvard.edu (5.54/a0.25) Q 	(for sri-unix!KL.SRI.COM!INFO-VAX@husc6) id AA19943; Wed, 15 Aug 90 23:30:06 EDT T Received: from lrw.UUCP by BULLDOG.CS.YALE.EDU via UUCP; Wed, 15 Aug 90 23:06:58 EDT4 Message-Id: <9008160306.AA03854@BULLDOG.CS.YALE.EDU>+ Received: by lrw.UUCP (DECUS UUCP w/Smail); %           Wed, 15 Aug 90 22:01:09 EDT ! Date: Wed, 15 Aug 90 22:01:09 EDT Q From: Jerry Leichter (LEICHTER-JERRY@CS.YALE.EDU) <yale!LRW.COM!leichter@harvard>  To: INFO-VAX@KL.sri.com  Subject: re: dir/date=read? H X-Vms-Mail-To: UUCP%"ccnucd.Denver.Colorado.EDU!PKLAMMER%cudnvr",INFOVAX  F 	We would really like to be able to implement a file-culling mechanismA 	based on least-recently-used (LRU) file access dates like (sigh) G 	TOPS-20's "reaper" and archiving.  I see there is no DIR/DATE=READ nor G 	/DATE=ACCESS command; am I right in presuming that no such date-of-use F 	is hidden anywhere in the VMS file system?  Surely this kind of issueG 	must have been volleyed in OS-war discussions, or at DECUS; has anyone 5 	come up with a way to retire apparently stale files?   N VMS actually has this feature; it just accomplishes it in a different way fromL many other systems.  Rather than a "date of last access", VMS has an expira-J tion date.  You can see it with DIR/DATE:EXPIRED.  If you try this, you'llK probably find that you get "<None specified>" for all your files, since you K have to take some action to get the date set.  For example, SET FILE/EXPIR- 0 ATION_DATE lets you set the date from DCL level.  M Much more to the point, you can have VMS maintain the expiration date automa- I tically.  You need to use the SET VOLUME/RETENTION command to enable this L feature for a given volume.  The general format is SET VOLUME/RET=(min,max).J This tells VMS that any time a file is accessed, VMS is to ensure that itsK expiration date is at least min in the future.  It does this by setting the M expiration date to max from now.  If both min and max are very small - say, a K second - then the expiration date is essentially a last access date:  Since K the expiration date will almost always have passed when a file is accessed, M it will be reset to a time very close to "now".  It's generally better to use N considerably larger values, trading off precision in your knowledge of exactlyJ when a file was accessed for fewer updates.  Files that have been accessedJ since min ago will have expiration dates later than "now", by at most max.   							-- Jerry   