Expected filesize of 25700274 bytes but read

Support intro

Sorry to hear you’re facing problems :slightly_frowning_face:

help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.

In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:
I have in client alot of errors and also when I check logs on nextcloud.

[webdav] Fatal: Sabre\DAV\Exception\BadRequest: Expected filesize of 25700274 bytes but read (from Nextcloud client) and wrote (to Nextcloud storage) 4816896 bytes. Could either be a network problem on the sending side or a problem writing to the storage on the server side. at <>

  1. /var/www/html/nextcloud/apps/dav/lib/Connector/Sabre/Directory.php line 156
    OCA\DAV\Connector\Sabre\File->put(null)
  2. /var/www/html/nextcloud/apps/dav/lib/Upload/UploadFolder.php line 47
    OCA\DAV\Connector\Sabre\Directory->createFile(“00000000”, null)
  3. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php line 1096
    OCA\DAV\Upload\UploadFolder->createFile(“00000000”, null)
  4. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php line 525
    Sabre\DAV\Server->createFile(“uploads/herc/3750203665/00000000”, null, null)
  5. <>
    Sabre\DAV\CorePlugin->httpPut(Sabre\HTTP\Reque … "}, Sabre\HTTP\Response {})
  6. /var/www/html/nextcloud/3rdparty/sabre/event/lib/EventEmitterTrait.php line 105
    call_user_func_array([Sabre\DAV\CorePlugin {},“httpPut”], [Sabre\HTTP\Requ … }])
  7. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php line 479
    Sabre\Event\EventEmitter->emit(“method:PUT”, [Sabre\HTTP\Requ … }])
  8. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php line 254
    Sabre\DAV\Server->invokeMethod(Sabre\HTTP\Reque … "}, Sabre\HTTP\Response {})
  9. /var/www/html/nextcloud/apps/dav/lib/Server.php line 319
    Sabre\DAV\Server->exec()
  10. /var/www/html/nextcloud/apps/dav/appinfo/v2/remote.php line 35
    OCA\DAV\Server->exec()
  11. /var/www/html/nextcloud/remote.php line 165
    require_once("/var/www/html/n … p")

PUT /remote.php/dav/uploads/herc/3750203665/00000000
from 86.61.77.130 by herc at 2020-07-20T09:07:12+00:00

Or for longer, use three backticks above and below the code snippet:

longer

here

Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can :heart:

Nextcloud version (eg, 18.0.2): 18.0.6
Operating system and version (eg, Ubuntu 20.04): Centos 7.7
Apache or nginx version (eg, Apache 2.4.25): Apache 2.4.25
PHP version (eg, 7.1): php 7.2

The issue you are facing:

Is this the first time you’ve seen this error? (Y/N):

Steps to replicate it:

The output of your Nextcloud log in Admin > Logging:

[webdav] Fatal: Sabre\DAV\Exception\BadRequest: Expected filesize of 25700274 bytes but read (from Nextcloud client) and wrote (to Nextcloud storage) 4816896 bytes. Could either be a network problem on the sending side or a problem writing to the storage on the server side. at <<closure>>

 0. /var/www/html/nextcloud/apps/dav/lib/Connector/Sabre/Directory.php line 156
    OCA\DAV\Connector\Sabre\File->put(null)
 1. /var/www/html/nextcloud/apps/dav/lib/Upload/UploadFolder.php line 47
    OCA\DAV\Connector\Sabre\Directory->createFile("00000000", null)
 2. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php line 1096
    OCA\DAV\Upload\UploadFolder->createFile("00000000", null)
 3. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/CorePlugin.php line 525
    Sabre\DAV\Server->createFile("uploads/herc/3750203665/00000000", null, null)
 4. <<closure>>
    Sabre\DAV\CorePlugin->httpPut(Sabre\HTTP\Reque ... "}, Sabre\HTTP\Response {})
 5. /var/www/html/nextcloud/3rdparty/sabre/event/lib/EventEmitterTrait.php line 105
    call_user_func_array([Sabre\DAV\CorePlugin {},"httpPut"], [Sabre\HTTP\Requ ... }])
 6. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php line 479
    Sabre\Event\EventEmitter->emit("method:PUT", [Sabre\HTTP\Requ ... }])
 7. /var/www/html/nextcloud/3rdparty/sabre/dav/lib/DAV/Server.php line 254
    Sabre\DAV\Server->invokeMethod(Sabre\HTTP\Reque ... "}, Sabre\HTTP\Response {})
 8. /var/www/html/nextcloud/apps/dav/lib/Server.php line 319
    Sabre\DAV\Server->exec()
 9. /var/www/html/nextcloud/apps/dav/appinfo/v2/remote.php line 35
    OCA\DAV\Server->exec()
10. /var/www/html/nextcloud/remote.php line 165
    require_once("/var/www/html/n ... p")

PUT /remote.php/dav/uploads/herc/3750203665/00000000
from 86.61.77.130 by herc at 2020-07-20T09:07:12+00:00

The output of your config.php file in /path/to/nextcloud (make sure you remove any identifiable information!):

<?php
$CONFIG = array (
  'instanceid' => '',
  'passwordsalt' => '',
  'secret' => '',
  'trusted_domains' => 
  array (
    0 => 'nextcloud.mydomain.net',
  ),
  'datadirectory' => '/data/nextcloud',
  'tempdirectory' => '/var/www/html/nextcloud/tmp',
  'overwrite.cli.url' => 'http://nextcloud.mydomain.net',
  'dbtype' => 'mysql',
  'version' => '18.0.6.0',
  'dbname' => 'nextcloud',
  'dbhost' => 'localhost',
  'dbport' => '',
  'dbtableprefix' => 'oc_',
  'dbuser' => 'nextcloud',
  'dbpassword' => 'xxxxx',
  'installed' => true,
  'debug' => false,
  'force_language' => 'sl',
  'knowledgebaseenabled' => true,
  'memcache.local' => '\\OC\\Memcache\\APCu',
  'memcache.locking' => '\\OC\\Memcache\\Redis',
  'redis' => 
  array (
    'host' => 'localhost',
    'port' => 6379,
  ),
  'mail_from_address' => 'myname',
  'mail_smtpmode' => 'smtp',
  'mail_domain' => 'mydomain.net',
  'maintenance' => false,
  'trashbin_retention_obligation' => 'auto',
  'logtimezone' => 'UTC',
  'theme' => '',
  'loglevel' => 2,
  'preview_max_x' => 800,
  'preview_max_y' => 800,
  'preview_max_scale_factor' => 1,
  'mail_smtphost' => 'localhost',
  'mail_smtpport' => '25',
  'mysql.utf8mb4' => true,
  'has_rebuilt_cache' => true,
  'app_install_overwrite' => 
  array (
    0 => 'admin_notifications',
    1 => 'files_reader',
  ),
);

The output of your Apache/nginx/system log in /var/log/____:

 
![2020-07-20 12_20_12-Window|690x122](upload://7PxZKxcXwE8BlrmNhu9NjZjhUpX.png)