Sabre\DAV\Exception\BadRequest: expected filesize 10485760 got 2554891

ok - can confirm this happens in a brand new install in a brand new directory without ssl with a basic httpd config and a new mysql database on freebsd-12. only other thing to check i guess is my.cnf

edit; download was directly https://download.nextcloud.com/server/releases/nextcloud-15.0.7.tar.bz2

and it still fails :frowning:

tried with sqlite instead of mysql56-server - still fails, same error. Expected filesize differs if a different file is chosen.

Hello … forum was down for a day! I think I found the answer, it worked for my user anyway.

https://httpd.apache.org/docs/2.4/mod/mod_reqtimeout.html


I added this to my vhost apache .conf and the problem went away:

<IfModule reqtimeout_module>
   RequestReadTimeout body=0
 </IfModule>
1 Like

heh. fixed my problem thanks firstly to you and also people on the github thread. Here’s what fixed it:


(basically commented out the loadmodule statement for mod_reqtimeout and restarted apache)

One thing that was confusing me though was that on an earlier installation, uploads were working. That one also has reqtimeout enabled and no extra config for it.

thanks again

4 Likes

I confirm this solution too.

To be more precise: The problem with mod_reqtimeout appeared with apache 2.4.39.

I had another identical hosting running 2.4.38 which did not show this problem at all. After updating that one to 2.4.39, it appeared there too.

Thanks to all for your postings!

1 Like

Thanks guys, this will be in the VM soon: https://github.com/nextcloud/vm/pull/843

Since it is appears as 1st result on google search result page, I would like to add this, which might save other’s time.

Check out your Nginx, Apache, php log, if you find nothing, please try to disable http2.

Details for your referrence:


1 Like

Is this Solution actual and where do i have to add this?

In the /etc/apache2/apache2.conf? Or in aviable-sites nextcloud.conf?

This is pretty old and I don’t think this fix is needed anymore, but if you want to try it: the latter, sites-available/nextcloud.conf.

Hmm because i get this error in the actual version.

Sabre\DAV\Exception\BadRequest: Expected filesize of 47186681 bytes but read (from Nextcloud client) and wrote (to Nextcloud storage) 44924928 bytes. Could either be a network problem on the sending side or a problem writing to the storage on the server side.

Sorry for another question. I am not very familiar with Apache.
Do i have to write it in the normal nextcloud.conf and the ssl.conf?

Apache doesn’t need it in more than one place. Try the nextcloud.conf, restart apache, and see if it helps.

1 Like