[LU-5268] HSM: importing with copytool can lead to data corruption Created: 27/Jun/14 Updated: 31/Jan/22 Resolved: 31/Jan/22 |
|
| Status: | Resolved |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | Lustre 2.5.0, Lustre 2.5.1 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Minor |
| Reporter: | Frank Zago (Inactive) | Assignee: | WC Triage |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | HSM | ||
| Issue Links: |
|
||||||||
| Severity: | 3 | ||||||||
| Rank (Obsolete): | 14701 | ||||||||
| Description |
|
This is a hypothetical bug. When importing a file with the posix copytool, a hardlink is done at the end to link from the archvie of the file being restored to the new archive file (hash of the new fid). When restoring a complete filesystem, it is very possible that the new fid being allocated already existed on the old filesystem (and thus in the HSM archive). In which case the new archive filename will already exist. At that point the hard link operation in import_one() will fail, which leaves the imported file pointing to the archive of another file, and restoring that file will lead to data corruption. Solution: link the new archive to a new directory; ie have --hsm-root and --hsm-root-import options. Then, optionally, let the user merge back both directories once the import is done. |
| Comments |
| Comment by Robert Read (Inactive) [ 27/Jun/14 ] |
|
Yet another reason to not use FIDs as the index of an external archive... |
| Comment by Thomas LEIBOVICI - CEA (Inactive) [ 02/Jul/14 ] |
|
Following this recovery procedure avoids fid conflicts when reimporting from the archive:
This should be added to the Lustre manual. |
| Comment by Frank Zago (Inactive) [ 02/Jul/14 ] |
|
Thanks Thomas. That looks like another good way to solve that problem. |