nextcloud / nextcloud/updater

Available disk space check

Open
#523 2 comments 0 reactions 1 assignee View on GitHub

@joshtrichards is already working on this.

Since Dec 15, 2024.

1. to develop enhancement feature: backups feature: download feature: extraction feature: moving robustness 💪
Dominant language
PHP
Stars
51
Forks
40
Avg merge
2d 19h
Merged PRs (30d)
3

Description

For robustness as well as improved user experience we should consider adding proactive disk space availability checks in several spots[1] before proceeding with material disk using steps:

  • at start (a general check for the prevailing then system requirement/recommended amount of available space before doing an update/upgrade: e.g. 2 x 1GiB or whatever)
  • at start (a general check, based on the user's current installation, to make sure they have at least 2x their current installations space usage, excluding datadirectory, available)
  • createBackup() (e.g. enough space before proceeding with the backup)
  • downloadUpdate() (e.g. enough space for the download)
  • extractDownload() (e.g. enough space for the extraction)

Possible checks might include one or more of:

  • warn before proceeding with the step if disk space is lower than a baseline absolute number we consider necessarily to complete that step typically
  • use real numbers where it's an option (e.g. we may be able to know the download size before we download, we may be able to calculate the space needed to perform the pre-update backup)

Things to consider:

  • one check at the beginning isn't necessarily enough since systems are dynamic, but in some cases it's probably "good enough"

Benefits:

  • better user experience through enhanced transparency, preventing execution of steps that are likely to fail, and elimination of partial updates
  • lowered false bug reports (i.e. don't blame the Updater for local environment limitations)

[1] Or just one spot, at least to start, if we can cover something like 80% of the situations without needing new checks everywhere

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.