tag name | repair-orphanage_2022-11-09 (9f0208f82596ddecb50999f78cb12805499ec2c2) |
tag date | 2022-11-09 19:10:22 -0800 |
tagged by | Darrick J. Wong <djwong@kernel.org> |
tagged object | commit 843cee45ac... |
xfs: move orphan files to lost and found
Orphaned files are defined to be files with nonzero ondisk link count
but no observable parent directory. This series enables online repair
to reparent orphaned files into the filesystem directory tree, and wires
up this reparenting ability into the directory, file link count, and
parent pointer repair functions. This is how we fix files with positive
link count that are not reachable through the directory tree.
This patch will also create the orphanage directory (lost+found) if it
is not present. In contrast to xfs_repair, we follow e2fsck in creating
the lost+found without group or other-owner access to avoid accidental
disclosure of files that were previously hidden by an 0700 directory.
That's silly security, but people have been known to do it.
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
-----BEGIN PGP SIGNATURE-----
iQIzBAABCgAdFiEEUzaAxoMeQq6m2jMV+H93GTRKtOsFAmNsa54ACgkQ+H93GTRK
tOspmQ//VrKiP5LiIMR5KD/TSezdgWXrDTMGVQBh9QOSzbJVuDo5JTZl+TQnvHns
jYXxkgcowfGAhz4coodiLvlBvVKE6P9g84nshWl5S8rhe1h+ZGWeM1r0bAUxdMJc
x5M3XeLn7Ves7JeTcZrDweUXOt0fwJfP5putsd9SCsSuidoh02qF6AUwJCJ5SBbL
SrMhZIndh7awpJMZjSfY4GoRlRzOEBdrU9O1UZtkyWrHNW8kIucuBYsunw5pnOfb
Fqd1SErZ9Y7ZtlaG61xmkyrSb41Bsr4yfFetfrDr2wJDBN2XyVPONMEr7lnj/QRk
3roPiygs706z0IDA1h6GC/iqbOMPe0Pp+uWqfq0JCRnFf4EAFddl06zZuUL7VwcM
aYTu290VL20yB9pfsyEEEB/0cU5PEgN6TUjWCHAQOXcFca0W/KXkTc+VxitGMyCN
V829XI9ziUhc+Sz7kUB+GEIqRaFwX2ciHS8t0TN80Mv/8jTzOsonFqvPTqGN2IWC
BKRzNZLqkiAIWCmk2Tc0rY8MEZ83T0hSamOqnwr0IUb2zBDf62h7t/awpNUZIuNh
+6zA0zRripYEVBjh28dHwH5dXZIo/BrerxTKL4fZdefqgMOzJ5j8CYvf6QgpBHcA
QBMEzWcJvRa98K0WcWnMFnbfxBqJwau+Q5MSp4bk8shoo0nDZ4o=
=i4jk
-----END PGP SIGNATURE-----