Upload bricht ab Chunks on server do not sum up to with files of size

Hallo,
ich bin mit meinem Nextcloud von einem virtuellen auf einen rootserver umgezogen. Soweit hat das alles ganz wunderbar geklappt. Doch leider kann ich keine Datei hochladen. Der Ladebalken läuft zwar durch, doch leider ist die Datei nur 1023KB groß, bzw. es erscheint die Meldung:
Sabre\DAV\Exception\BadRequest: Chunks on server do not sum up to 126769907 but to 13512604 bytes

/var/www/clients/client1/web6/web/apps/dav/lib/Upload/ChunkingPlugin.php - line 57: OCA\DAV\Upload\ChunkingPlugin->verifySize()

Das ist jedoch nicht alles. Das passiert meist bei jpg oder exe Dateien. DWGs oder ZIPs und RARs gehen durch? Ich habe nicht die AntiVirus App installiert. Der Ransomeware Schutz ist ausgeschaltet.

Hello, there,
i moved my Nextcloud from a virtual to a rootserver. So far it all worked out wonderfully. But unfortunately I can’t upload a file. The loading bar runs through, but unfortunately the file is only 1023KB large, or the message appears:
Sabre\DAV\Exception\BadRequest: Chunks on server do not sum up to 126769907 but to 13512604 bytes

/var/www/clients/client1/web6/web/apps/dav/lib/Upload/ChunkingPlugin.php - line 57: OCA\DAV\Upload\ChunkingPlugin->verifySize()

But that’s not all. This usually happens with jpg or exe files. DWGs or ZIPs and RARs go through? I did not install the AntiVirus App. The Ransomeware protection is disabled.

The client normally splits a file in chunks of 12 or 13 MB, and then recombines them afterwards. In your case you have a 120MB file and it seems like there is only one chunk left. You’ve already disabled some apps that you suspected might cause a problem. Let’s go a bit further, do you mind trying first that you can upload a large file (at least 120 MB) directly via web interface and webdav?

Your folder structure implies that you use some sort of management tools. I’d suspect that they change some settings that don’t allow to create the different chunks. Perhaps they have documented that somewhere, or you find some indications in logfiles of that system. Or they clean out these files very often, then you can set this parameter in the config/config.php file:

/**
* TTL of chunks located in the cache folder before they're removed by
* garbage collection (in seconds). Increase this value if users have
* issues uploading very large files via the Nextcloud Client as upload isn't
* completed within one day.
*
* Defaults to ``60*60*24`` (1 day)
*/
'cache_chunk_gc_ttl' => 60*60*24,

Or if they put too many ristrictions on the temporary folder, a dedicated temporary folder could help:

/**
* Override where Nextcloud stores temporary files. Useful in situations where
* the system temporary directory is on a limited space ramdisk or is otherwise
* restricted, or if external storages which do not support streaming are in
* use.
*
* The Web server user must have write access to this directory.
*/
'tempdirectory' => '/tmp/nextcloudtemp',

This however indicates, that your system has some additional checks that block this. Check the management software if there is such a functionality. Perhaps try as well on a different client, where you don’t use the same security software (Antivirus, Firewall).

Vielen Dank, erstmal, für diesen Hinweis.

Ich glaube, das ich nicht ausdrücklich erwähnt habe, das es sich um ein Restore nach einem Umzug von einem virtuellen auf root-Server handelt. Die Datenbank sowie die Verzeichnisstruktur ist 1:1 übertragen worden. Die Dateirechte wurden auf 644 oktal und die Verzeichnisrechte auf 755 oktal eingestellt.

Nachdem ich die config.php angepasst habe, muss ich leider feststellen, das Upload Dateien weiterhin in dem alten Verzeichnis gespeichert werden. Obwohl die Vorschrift hinsichtlich des neu angelegten Verzeichnisses eingetragen wurden. Das alte und das neue Verzeichnis gehören dem Nextcloud Eigentümer. Es handelt sich um einen Server der mit ISPCONFIG verwaltet wird.

Ganz merkwürdig ist der Umstand, das Uploads über iOs oder Android Geräte ohne abschneiden der Dateien gelingen. Wenn ich eine beliebige Datei mit einem dieser Geräte uploade, werden diese Dateien vollständig gespeichert.

Das sieht alles ziemlich merkwürdig aus.

Thank you so much for that clue.

I don’t think I explicitly mentioned that this is a restore after moving from a virtual to a root server. The database as well as the directory structure has been transferred 1:1. The file permissions have been set to 644 octal and the directory permissions to 755 octal.

After I adjusted the config.php, I unfortunately have to state that the upload files are still stored in the old directory. Although the new directory rule has been entered. The old and the new directory belong to the Nextcloud owner. It is a server managed by ISPCONFIG.

Very strange is the fact that uploads via iOs or Android devices succeed without truncating the files. If I upload any file with one of these devices, these files will be saved completely.

It all looks pretty weird.

Ich habe da noch eine Erweiterung mit Informationen aus dem Logfile:
Error no app in context JSCombiner: unable to cache: merged.js

vorformatierten Text mit 4 Leerzeichen einrücken
	file_exists(): 
		open_basedir restriction in effect. 
		File(
		/var/www/vhosts/xxxxxx.net
		/httpdocs/core/js/merged-template-prepend.json) is not within the allowed path(s): 
		(/var/www/clients/client1/web6/web:
		/var/www/clients/client1/web6/private:
		/var/www/clients/client1/web6/tmp:
		/var/www/xxxxxx.net/web:
		/srv/www/xxxxxx.net/web:
		/usr/share/php5:
		/usr/share/php:
		/tmp:
		/usr/share/phpmyadmin:
		/etc/phpmyadmin:
		/var/lib/phpmyadmin:
		/dev/random:
		/dev/urandom) 
		at /var/www/clients/client1/web6/web/lib/private/Template/JSCombiner.php#139

Diese Hinweise werden immer nach misslungenen Uploads gezeigt. Ich habe schon im gesamten Verzeichnisbaum und auch in der Datenbank nach dem Eintrag “/httpdocs/core/js/merged-template-prepend.json” gesucht aber nichts gefunden. Könnte ich diesen Eintrag lokalisieren und der Verzeichnisstruktur des neuen Servers anpassen, könnte ich wohl meine Schwierigkeiten gelöst haben?

English:
I have an extension with information from the logfile:
Error no app in context JSCombiner: unable to cache: merged.js

indent preformatted text with 4 blanks
	file_exists(): 
		open_basedir restriction in effect. 
		File(
		/var/www/vhosts/xxxxxx.net
		/httpdocs/core/js/merged-template-prepend.json) is not within the allowed path(s): 
		(/var/www/clients/client1/web6/web:
		/var/www/clients/client1/web6/private:
		/var/www/clients/client1/web6/tmp:
		/var/www/xxxxxx.net/web:
		/srv/www/xxxxxx.net/web:
		/usr/share/php5:
		/usr/share/php:
		/tmp:
		/usr/share/phpmyadmin:
		/etc/phpmyadmin:
		/var/lib/phpmyadmin:
		/dev/random:
		/dev/urandom) 
		at /var/www/clients/client1/web6/web/lib/private/Template/JSCombiner.php#139

These hints are always shown after unsuccessful uploads. I already searched the whole directory tree and the database for the entry “/httpdocs/core/js/merged-template-prepend.json” but found nothing. Could I locate this entry and adapt it to the directory structure of the new server, could I have solved my problems?