Request for occ documentation and fix for OOM on upload to external storage
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 272
- Forks
- 37
- PR merge metrics
- No merged PRs in 30d
Description
Nextcloud 23.0.4 running Backup 1.0.6, Ubuntu 16.04 server, PHP 7.3, MariaDB 10.2
Attempting to run Backup exclusively with the backup occ commands.
sudo -u www-data php /var/www/nextcloud/occ backup:point:create
sudo -u www-data php /var/www/nextcloud/occ backup:point:pack [point id]
sudo -u www-data php /var/www/nextcloud/occ backup:point:upload
Partial success on backup of 190 GB (have yet to try restore) with local external storage configured.
- first pass of full backup is quite slow at 2 hours and 50 minutes (maintenance mode enabled)
- second pass (packing) is very slow (encryption disabled, compression enabled) but maintenance mode is disabled so the Nextcloud instance is available
- packing process states "Removing old chunk file" but data folders/files (170 GB) are not removed from the appdata folder
- third stage (upload to external storage) fails with error after approximately 5% of "parts" have been moved to local external storage
mmap() failed: [12] Cannot allocate memory
PHP Fatal error: Out of memory (allocated 14036226048) (tried to allocate 139810216 bytes) in /var/www/nextcloud/apps/backup/lib/Service/PackService.php on line 606
This appears to be the same issue as reported in #154, #158, #205, #237, #244 , #268
I see some documentation on occ commands in README.md but there appears to be so much more:

Does anyone know if documentation on the full set of occ commands for Backup exists?
If not, when will this documentation be available (similar to what's available in the Nextcloud Administration documentation for other occ commands)?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with README.md, the listed occ commands, and apps/backup/lib/Service/PackService.php around line 606; review related issues #154, #158, #205, #237, #244, and #268. Reproduce the upload failure on the described setup if possible, and identify the full Backup occ command set and the expected outcome for the memory issue.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend, documentation
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100