Closed cfiehe closed 8 hours ago
I can provide the stacktrace from an upload to a group folder. It really looks like the Nextcloud thinks that it must move the file to a different storage via a copy-delete sequence:
[10-Sep-2024 08:58:35] [pool nextcloud] pid 173903
script_filename = /var/www/html/nextcloud/remote.php
[0x00007373e3c15a00] dispatch() /var/www/html/nextcloud/3rdparty/mtdowling/jmespath.php/src/TreeInterpreter.php:56
[0x00007373e3c15870] dispatch() /var/www/html/nextcloud/3rdparty/mtdowling/jmespath.php/src/TreeInterpreter.php:32
[0x00007373e3c157f0] visit() /var/www/html/nextcloud/3rdparty/mtdowling/jmespath.php/src/AstRuntime.php:45
[0x00007373e3c15760] __invoke() /var/www/html/nextcloud/3rdparty/mtdowling/jmespath.php/src/Env.php:33
[0x00007373e3c156d0] search() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/Endpoint/PartitionEndpointProvider.php:117
[0x00007373e3c15590] mergePrefixData() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/Endpoint/PartitionEndpointProvider.php:99
[0x00007373e3c154e0] defaultProvider() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/S3/S3EndpointMiddleware.php:86
[0x00007373e3c15430] __construct() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/S3/S3EndpointMiddleware.php:66
[0x00007373e3c15390] Aws\S3\{closure}() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/HandlerList.php:302
[0x00007373e3c15300] resolve() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/AwsClientTrait.php:63
[0x00007373e3c15280] executeAsync() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/CommandPool.php:67
[0x00007373dd04de00] Aws\{closure}() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/EachPromise.php:205
[0x00007373e3c15230] next() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/EachPromise.php:205
[0x00007373e3c151c0] advanceIterator() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/EachPromise.php:231
[0x00007373e3c15150] step() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/EachPromise.php:176
[0x00007373e3c150b0] GuzzleHttp\Promise\{closure}() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:204
[0x00007373e3c14f80] callHandler() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:153
[0x00007373e3c14ee0] GuzzleHttp\Promise\{closure}() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/TaskQueue.php:48
[0x00007373e3c14e70] run() /var/www/html/nextcloud/3rdparty/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php:163
[0x00007373e3c14dc0] tick() /var/www/html/nextcloud/3rdparty/guzzlehttp/guzzle/src/Handler/CurlMultiHandler.php:189
[0x00007373e3c14d40] execute() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:248
[0x00007373e3c14ca0] invokeWaitFn() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:224
[0x00007373e3c14c20] waitIfPending() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:269
[0x00007373e3c14b90] invokeWaitList() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:226
[0x00007373e3c14b10] waitIfPending() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:269
[0x00007373e3c14a80] invokeWaitList() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:226
[0x00007373e3c14a00] waitIfPending() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:62
[0x00007373e3c14970] wait() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Coroutine.php:67
[0x00007373e3c148f0] GuzzleHttp\Promise\{closure}() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:248
[0x00007373e3c14850] invokeWaitFn() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:224
[0x00007373e3c147d0] waitIfPending() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:269
[0x00007373e3c14740] invokeWaitList() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:226
[0x00007373e3c146c0] waitIfPending() /var/www/html/nextcloud/3rdparty/guzzlehttp/promises/src/Promise.php:62
[0x00007373e3c14630] wait() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/Multipart/AbstractUploadManager.php:83
[0x00007373e3c145d0] upload() /var/www/html/nextcloud/3rdparty/aws/aws-sdk-php/src/S3/MultipartCopy.php:86
[0x00007373e3c14570] copy() /var/www/html/nextcloud/lib/private/Files/ObjectStore/S3ObjectTrait.php:215
[0x00007373e3c14470] copyObject() /var/www/html/nextcloud/lib/private/Files/ObjectStore/ObjectStoreStorage.php:666
[0x00007373e3c14390] copyFile() /var/www/html/nextcloud/lib/private/Files/ObjectStore/ObjectStoreStorage.php:648
[0x00007373e3c142b0] copyInner() /var/www/html/nextcloud/lib/private/Files/ObjectStore/ObjectStoreStorage.php:612
[0x00007373e3c141d0] copyFromStorage() /var/www/html/nextcloud/lib/private/Files/Storage/Common.php:705
[0x00007373e3c14130] moveFromStorage() /var/www/html/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php:601
[0x00007373e3c14090] moveFromStorage() /var/www/html/nextcloud/apps/files_trashbin/lib/Storage.php:235
[0x00007373e3c13fd0] moveFromStorage() /var/www/html/nextcloud/lib/private/Files/Storage/Wrapper/Jail.php:501
[0x00007373e3c13f30] moveFromStorage() /var/www/html/nextcloud/lib/private/Files/Storage/Wrapper/Quota.php:240
[0x00007373e3c13e80] moveFromStorage() /var/www/html/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php:601
[0x00007373e3c13de0] moveFromStorage() /var/www/html/nextcloud/lib/private/Files/Storage/Wrapper/Wrapper.php:601
[0x00007373e3c13d40] moveFromStorage() /var/www/html/nextcloud/apps/files_trashbin/lib/Storage.php:235
[0x00007373e3c13c80] moveFromStorage() /var/www/html/nextcloud/lib/private/Files/View.php:820
[0x00007373e3c13aa0] rename() /var/www/html/nextcloud/lib/private/Files/Node/Node.php:468
[0x00007373e3c139c0] move() /var/www/html/nextcloud/apps/dav/lib/Upload/ChunkingV2Plugin.php:353
[0x00007373e3c138d0] completeChunkedWrite() /var/www/html/nextcloud/apps/dav/lib/Upload/ChunkingV2Plugin.php:238
[0x00007373e3c136f0] beforeMove() /var/www/html/nextcloud/3rdparty/sabre/event/lib/WildcardEmitterTrait.php:89
[0x00007373e3c13610] emit() /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php:603
[0x00007373e3c13540] httpMove() /var/www/html/nextcloud/3rdparty/sabre/event/lib/WildcardEmitterTrait.php:89
[0x00007373e3c13460] emit() /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php:472
[0x00007373e3c133a0] invokeMethod() /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php:253
[0x00007373e3c132a0] start() /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php:321
[0x00007373e3c13250] exec() /var/www/html/nextcloud/apps/dav/lib/Server.php:385
[0x00007373e3c131d0] exec() /var/www/html/nextcloud/apps/dav/appinfo/v2/remote.php:35
[0x00007373e3c13140] [INCLUDE_OR_EVAL]() /var/www/html/nextcloud/remote.php:172
I am not sure and hope, that the issue can be fixed directly in the groupfolders plugin: https://github.com/nextcloud/groupfolders/pull/3205
⚠️ This issue respects the following points: ⚠️
Bug description
We use an S3 object store as primary storage for our Nextcloud cluster. We have recognized that uploads into a group folder cause a massive delay on the final file’s move operation, when the chunks are being assembled and the file gets created on the actual upload target:
Uploads of a
6 GB
file cause a delay of2.14 min
and a170 GB
file a delay of33 min
.When the upload appears outside of a group folder, the move operation does not cause any noticeable delay. During a normal upload the command sequence ends with a
CompleteMultipartUpload
. In case of group folder target, a lot of additionalCopyObjectPart
commands are being created and sent to the object storage. It depends on the file size, and the number of chunks, when the sequence ends.I have attached a trace (refer to: Additional info) on a test bucket on our MinIO-S3-storage, which shows, what is actually happening. It looks like a copy-delete sequence initiated by the Nextcloud. Maybe the server thinks, that source and target are located on different storage systems.
Steps to reproduce
Expected behavior
Uploads into a group folder should not cause any noticeable delay on the final move operation.
Nextcloud Server version
28
Operating system
None
PHP engine version
None
Web server
None
Database engine version
None
Is this bug present after an update or on a fresh install?
None
Are you using the Nextcloud Server Encryption module?
None
What user-backends are you using?
Configuration report
List of activated Apps
Nextcloud Signing status
Nextcloud Logs
No response
Additional info
minio-groupfolder-trace.txt