Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add file:repair-tree documentation #9509

Merged
merged 3 commits into from
Jan 18, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 19 additions & 3 deletions admin_manual/configuration_server/occ_command.rst
Original file line number Diff line number Diff line change
Expand Up @@ -655,9 +655,10 @@ File operations
``occ`` has three commands for managing files in Nextcloud::

files
files:cleanup cleanup filecache
files:scan rescan filesystem
files:scan-app-data rescan the AppData folder
files:cleanup Cleanup filecache
files:repair-tree Try and repair malformed filesystem tree structures
files:scan Rescan filesystem
files:scan-app-data Rescan the AppData folder
files:transfer-ownership All files' and folders' ownerships are moved to another
user. Outgoing shares are moved as well.
Incoming shares are not moved by default because the
Expand Down Expand Up @@ -750,6 +751,21 @@ Cleanup
``files:cleanup`` tidies up the server's file cache by deleting all file
entries that have no matching entries in the storage table.

Repair-Tree
^^^^^^^^^^^

``files:repair-tree`` try and repair malformed filesystem tree structures.
If for any reason the path of an entry in the filecache doesn't match with
it's expected path, based on the path of it's parent node, you end up with an
entry in the filecache that exists in different places based on how the entry
is generated. For example, if while listing folder ``/foo`` it contains a file
``bar.txt``, but when trying to do anything with ``/foo/bar.txt`` the file
doesn't exists.

This command attempts to repair such entries by querying for entries where the path
doesn't match the expected path based on it's parent path and filename and resets it's
path to the expected one.

Transfer
^^^^^^^^

Expand Down