EXPSET Command

HSI Version: 6.0.0.p4 and beyond


Purpose: Set expiration time for the specified file(s)


Aliases: 


Command Format: 

  expset [-A] [-b c | m | n | t] [-c] [-d days] [-h hours] [-m minutes] [-s seconds] [-y years] [-R] [-t expireTime] [-v] path ...


Options: 

 -A : If specified, displays absolute pathnames for files whose expiration time is deleted.  Default is to display relative pathnames.

 -b : Set baseTime type as:

      c : file creation time

      m : modification time

      n : now (time at which expset command is issued)

      t : today at 00:00:00

 -c : Clear expiration time 

-d  : set number of days in expiration time calculation

-h  : set number of hours in expiration time calculation

-m  : set number of minutes in expiration time calculation

-s  : set number of seconds in expiration time calculation

-R : If specified, recursively deletes expiration times for files contained in subdirectories.

-t  : set expiration time in the form YYYY-MM-DD or optionally,

      YYYY-MM-DD-hh:mm:ss, where:

        YYYY is the year

        MM is the month number (1-12)

        DD is the day number (1-31, depending on the month and leap year)

        hh is the hour (0-23)

        mm is the minute (0-59)

        ss is the second (0-59)

-v  : enable verbose listing mode

-y  : set number of years in expiration time calculation


Keywords

 N/A


Usage Notes: 

  • if -b is not specified, "-b n” is assumed (base time is current time when command is issued)
  • h, -m, -s, -d and -y may be combined to specify base time + years/days/hours/minutes/seconds
  • -c and -t may not be combined with any other options
  • HPSS administrators may disable the file expiration feature, and may also restrict the use of this command.


Example: 


1. Set expiration time for all files that match the pattern “*.c” to their creation time + 2 years, 2 months and 8 days:

   expset -b c -y 2 -m 2 -d 8 *.c


2. Recursively set expiration time for all files in the directory OldProject to now + 30 days:

    expset -R -d 30 OldProject


3. Recursively set the expiration date for all files in the directory ~Joe to COB (5 PM) January 1, 2020:

    expset -R -t 2020-1-1-17:00:00 ~Joe


Related Command(s): 

expdelete expfind expls