News Stay informed about the latest enterprise technology news and product updates.

SAVLIB -- Save Library

SAVLIB -- Save Library

Definition provided courtesy of the iSeries Information Center

The SAVLIB command saves the entire library; this includes the library description, the object descriptions, and the contents of the objects in the library. For job queues, message queues, output queues, data queues, and logical files, only the object definitions are saved, not the contents. Logical file access paths may be saved, however, by using the ACCPTH parameter.

The contents of a save file can be saved by using the Save Save File Data (SAVSAVFDTA) command or by using the SAVFDTA parameter on the SAVLIB command. The libraries and their objects are not affected in the system unless the command specifies that the storage is to be freed. However, unless UPDHST(*NO) is specified, the description of each library and each object is updated with the date, place, and time it was last saved. If a group of libraries is saved by specifying *NONSYS, *ALLUSR, or *IBM for the LIB parameter, the date, time, and place are updated in the history information for a data area in QSYS (data area QSAVLIBALL, QSAVALLUSR, or QSAVIBM).

The types of objects saved by this command are the same as those listed for the OBJTYPE parameter in with the addition of *DTADCT. Certain OS/400 system objects that are not contained in user libraries (such as user profiles) are not saved by this command. They can be saved by the Save System (SAVSYS) or Save Security Data (SAVSECDTA) commands.

Note: This command ignores all file overrides currently in effect for the job, except for the listing file.

Tips that involve the SAVLIB command:

  • Possible to run SAVLIB *ALLUSR command from scheduled CL job?
  • SAVLIB command exception report
  • Provide a report for user to verify backups
  • E-mail that file/lib quickly

  Return to featured topic.

Dig Deeper on Data backup, storage and retrieval on iSeries