You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: admin_manual/configuration_files/file_versioning.rst
+10-10Lines changed: 10 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -21,19 +21,19 @@ The Versions app never uses more than 50% of the user's currently available
21
21
free space. If the stored versions exceed this limit, Nextcloud deletes the
22
22
oldest file versions until it meets the disk space limit again.
23
23
24
-
The ``versions_retention_obligation`` setting behaves slightly differently
25
-
depending on whether version expiration is triggered by an *explicit job run*
26
-
(for example, via ``occ versions:expire`` or a scheduled background job) or by
27
-
*automatic expiry*.
24
+
Nextcloud manages file versions using a combination of on-save pruning and scheduled cleanup. This ensures that versions are retained while respecting storage quotas.
28
25
29
-
Explicit job-based expiration is *strict* and adheres closely to the configured
30
-
``versions_retention_obligation``.
26
+
During Version Creation
27
+
----------------------
31
28
32
-
Auto-expiry follows the same retention principles but may apply them more flexibly, allowing minor deviations when
33
-
necessary to maintain adequate free storage space.
29
+
Nextcloud automatically creates new file versions whenever a file is modified, allowing users to restore previous states when needed. After each new version is stored, the system automatically checks storage limits and retention rules. Versions are filtered according to the above pattern to keep representative versions and remove redundant ones. If the user’s quota is exceeded, auto-expiry is triggered.
30
+
When storage space runs low, Nextcloud sorts all versions from oldest to newest and removes the oldest ones first, while always preserving at least the two most recent versions to free up space.
34
31
35
-
This distinction can lead to different results depending on whether cleanup is
36
-
performed automatically or manually.
32
+
During the Regular Background Job
33
+
---------------------------------
34
+
35
+
Nextcloud runs a background cleanup task that automatically removes old file versions for each user. During this process, the system checks the user's version storage folder and identifies versions that are older than the configured maximum retention period or whose original files no longer exist.
36
+
When an outdated or orphaned version is found, it is safely deleted from both the filesystem and the version database to reclaim storage space and maintain consistency.
37
37
38
38
.. note:: Versions named by a user will never be deleted.
0 commit comments