Sets the expiration date for existing dump levels.
Synopsis
backup setexp -dump <dump level name>+ [-expires <expiration date>]
[-localauth] [-cell <cell name>] [-help]
backup se -d <dump level name>+ [-e <expiration date>]
[-l] [-c <cell name>] [-h]
Description
The backup setexp command sets or changes the expiration date associated with each specified dump level, which must already exist in the dump hierarchy.
All dumps made at a dump level inherit the level's expiration date. The Backup System refuses to overwrite a tape until all dumps in the dump set to which the tape belongs have reached their expiration date, unless the operator uses the backup labeltape to relabel the tape. If a dump level does not have an associated expiration date, then dumps created at the dump level expire immediately (tapes made at the dump level can be recycled immediately).
Define either an absolute or relative expiration date:
If the command is used to change an existing expiration date associated with a dump level, the new date applies only to dumps created after the change. Existing dumps retain the expiration date assigned at the time they were created.
Options
[at] {NEVER | mm/dd/yyyy [hh:MM] }
where the optional word at is followed either by the string NEVER, which specifies that dumps created at the dump level never expire, or by a date value with a required portion (mm for month, dd for day, and yyyy for year) and an optional portion (hh for hours and MM for minutes).
Omit the hh:MM portion to use the default of midnight (00:00 hours), or provide a value in 24-hour format (for example, 20:30 is 8:30 p.m.). Valid values for the year range from 1970 to 2037; higher values are not valid because the latest possible date in the standard UNIX representation is in February 2038. The command interpreter automatically reduces later dates to the maximum value.
Relative expiration dates have the following format:
[in] [yearsy] [monthsm] [daysd]
where the optional word in is followed by at least one of a number of years (maximum 9999), months (maximum 12), or days (maximum 31), each followed by the required units abbreviation (y, m, or d respectively). If providing more than one of the three, list them in the indicated order. If the date that results from adding the relative expiration value to a dump's creation time is later than the latest possible date in the UNIX time representation, the Backup System automatically reduces it to that date.
Note: In the command's syntax statement, a plus sign follows this argument only because it accepts a multi-word value, not because it accepts multiple dates. The command accepts only one date definition, and associates it with each dump level specified by the -dump argument.
Examples
The following example associates an absolute expiration date of 10:00 p.m. on 31 December 1999 with the dump level /1998/december:
% backup setexp -dump /1998/december -expires at 12/31/1999 22:00
The following example associates a relative expiration date of 7 days with the two dump levels /monthly/week1 and /monthly/week2:
% backup setexp -dump /monthly/week1 /monthly/week -expires 7d
Privilege Required
The issuer must be listed in the /usr/afs/etc/UserList file on every machine where the Backup Server is running, or must be logged onto a server machine as the local superuser root if the -localauth flag is included.
Related Information