LinearTapeFileSystem / ltfs

Reference implementation of the LTFS format Spec for stand alone tape drive
BSD 3-Clause "New" or "Revised" License
256 stars 77 forks source link

Introduce Index mount mode #330

Closed piste-jp closed 2 years ago

piste-jp commented 2 years ago

Summary of changes

Introduce a feature to mount LTFS with an index file. And also a few improvements are provided.

Description

Introduce a feature to mount LTFS with an index file. The feature includes

  1. Mount a tape with an index file and tape, contents of tape can be accessible on read-only
  2. Mount a tape only with index, meta-data in the index file can be accessible

When both -o devname and -o rollback_mount=[file_name] is specified, the ltfs command tries to mount a tape by normal read-only mode with an index and a tape. User can read the contents of files.

When only -o rollback_mount=[file_name] is specified, the ltfs command tries to mount a tape by meta-dta read-only mode only with an index. User shall have EAGAIN when they try to read the contents of files.

In addition, a few functions and improvements are introduced too.

Type of change

Please delete items that are not relevant.

Checklist: