-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem to download big file with php7 and owncloud 9 #23788
Comments
Can you try with 64 bit OS? also try to patch Sapi.php to add $contentLength = $response->getHeader('Content-Length');
if ($contentLength !== null) {
+ $contentLength = intval($contentLength);
$output = fopen('php://output', 'wb'); |
No sorry i can't try with 64 bit OS i only have Owncloud installed on my Raspbian. So i tried to remove the $contentLength on stream_copy_to_stream call (sorry i didn't find how to display the line breaks) : if ($contentLength !== null) {
$output = fopen('php://output', 'wb');
if (is_resource($body) && get_resource_type($body) == 'stream') {
stream_copy_to_stream($body, $output);
} else {
fwrite($output, $body, $contentLength);
}
... That fixed my problem but i don't know the collateral effects... Moreover, I didn't have this problem with owncloud 8.2.3 and PHP 5. Which one of these upgrades bringed the problem ? Thanks for you help :) |
3rdparty problem. Closing here. |
it means the problem will not be solved because it concerns a 3rd party API included in Owncloud and not Owncloud core itself ? |
Well we can't fix it, once the thridparty (Sabre/http) fixed the issue, we will simply update it. |
Ok I understand but when i used Owncloud 8.2 and PHP 5 i didn't have this problem. I'am asking because if some day i have to reinstall my raspbian, i need to know which versions of the components i shoud install to avoid issues. |
I'd be keen to hear of some offical Rasbian support for the core. |
Same observed on Nextcloud: |
A patch to fix the problem is mentioned here: |
New Ticket and PR created, here: |
just released https://github.com/fruux/sabre-http/releases/tag/4.2.3 which contains a workaround for the 32bit file size problems |
Backref to another issue: #27395 |
Created #28133 and requested to update sabre-http to 4.2.3 |
Confirmed that sabre-http 4.2.3 fixes the issue. Please merge #28133 so we can solve this ticket. |
This is no pull request so it can't be merged. Its just a request to update sabre-http to 4.2.3 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Steps to reproduce
Expected behaviour
It should download the file
Actual behaviour
The download doesn't start and after about 1 minute Chrome stops the download which has never stared --> empty temporary file
Server configuration
Operating system:
Raspbian last update on a raspberry Pi 3
Web server:
Nginx 1.6.2
Database:
MySQL 5.5.44
PHP version:
PHP 7.0.3-3~bpo8+1
ownCloud version: (see ownCloud admin page)
Owncloud 9.0.0 (stable)
Updated from an older ownCloud or fresh install:
Updated manually from Owncloud 8.2.3
Where did you install ownCloud from:
I downloaded the tarball from Owncloud download page
Signing status (ownCloud 9.0 and above):
No errors have been found.
List of activated apps:
Enabled:
Disabled:
The content of config/config.php:
{
"system": {
"instanceid": "_",
"passwordsalt": "REMOVED SENSITIVE VALUE**",
"secret": "_REMOVED SENSITIVE VALUE",
"trusted_domains": [
"cloud.**.com"
],
"datadirectory": "/media/usbdisk/owncloud/data",
"overwrite.cli.url": "https://cloud..com/owncloud",
"dbtype": "mysql",
"version": "9.0.0.19",
"dbname": "owncloud",
"dbhost": "localhost",
"dbtableprefix": "oc",
"dbuser": "REMOVED SENSITIVE VALUE**",
"dbpassword": "_REMOVED SENSITIVE VALUE*",
"logtimezone": "UTC",
"installed": true,
"appstore.experimental.enabled": true,
"loglevel": 2,
"maintenance": false,
"theme": "",
"memcache.local": "\OC\Memcache\APCu",
"asset-pipeline.enabled": true,
"default_language": "fr"
}
}
Are you using external storage, if yes which one: local/smb/sftp/...
local
Are you using encryption: yes/no
no
Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/...
no
Web server error log
None
ownCloud log (data/owncloud.log)
{"reqId":"ywywVbU1oKTwIgu8yUuS","remoteAddr":"192.168.1.102","app":"PHP","message":"stream_copy_to_stream() expects parameter 3 to be integer, string given at /var/www/owncloud/3rdparty/sabre/http/lib/Sapi.php#78","level":3,"time":"2016-04-04T19:38:09+00:00"}
Browser log
None
The text was updated successfully, but these errors were encountered: