Skip to content
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

download of bigger files on samba backend abort if connect via slow dsl wan #26621

Closed
jankowa opened this issue Nov 14, 2016 · 7 comments
Closed

Comments

@jankowa
Copy link

jankowa commented Nov 14, 2016

Steps to reproduce

  1. Owncloud Setup 9.1.1 on debian stable inside a lxc-container
  2. Samba Server (4.2.10) on another container with ldap user backend
  3. external samba storage in owncloud
  4. connection via a not very fast dsl connection with nat (1200 kbit up / 17000 down)

Probably It's not easy to reproduce. On one of my setups this works on another configured nearly identically it doesn't.

Expected behaviour

Download of files stored on samba backend should work.

Actual behavior

  • from local lan download works independent of file size (no matter if files stored on samba backend or in owncloud directly)
  • from wan (connected via dsl and nat) download of files not stored on samba backend (but in owncloud file storage) works independently of file size
  • from wan download of files stored on samba backend with file size up to 2 MB works
  • from wan download of files stored on samba backend with file size bigger then 2 MB abort
  • from wan download of files stored on the same samba server but are attached via sFTP works independently of file size

Maybe also interesting: Becaus this is working on another setup, I tried to access owncloud via ssh-reverse tunnel and nginx proxy:

from client -> nginx on internet -> through ssh-reverse proxy to apache on owncloud server

This improves it but doesn't solve the issue. Instead of 2 MB, files are downloadable until 14 MB ;-)

Server configuration

Operating system:

Debian Stable

Web server:

apache2 2.4.10

Database:

mysql

PHP version:

libapache2-mod-php5 5.6.24

ownCloud version: (see ownCloud admin page)

9.1.1

Updated from an older ownCloud or fresh install:

fresh install

Where did you install ownCloud from:

from debian package or directly from owncloud - tried both.

Signing status (ownCloud 9.0 and above):

No errors have been found.

List of activated apps:

external files

The content of config/config.php:


{
    "system": {
        "updatechecker": false,
        "instanceid": "ocpzgfjzylzr",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "dbox-owncloud",
            "cloud.example.org",
            "owncloud.example.org"
        ],
        "datadirectory": "\/srv\/oc_data",
        "overwrite.cli.url": "https:\/\/cloud.example.org\/owncloud",
        "dbtype": "mysql",
        "version": "9.1.1.3",
        "dbname": "owncloud",
        "dbhost": "localhost",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "logtimezone": "UTC",
        "installed": true,
        "mail_from_address": "info",
        "mail_smtpmode": "php",
        "mail_domain": "example.org",
        "maintenance": false,
        "loglevel": 2
    }
}

Are you using external storage, if yes which one: local/smb/sftp/...

smb, sftp

Are you using encryption: yes/no

no

Are you using an external user-backend, if yes which one: LDAP/ActiveDirectory/Webdav/...

ldap

Client configuration

Browser:

chrome, firefox, others

Operating system:

problem independent of os

Logs

Web server error log

  • no Errors in apach2 access/error log
  • no errors in php log (debugging enabled)

ownCloud log (data/owncloud.log)

  • nothing in owncloud log

Browser log

GET 
https://cloud.example.org/owncloud/remote.php/webdav/mein-home/Downloads/gimp-2.8.0-setup.exe [HTTP/1.1 200 OK 42112ms]
GET 
XHR 
https://cloud.example.org/owncloud/ocs/v2.php/apps/notifications/api/v1/notifications [HTTP/1.1 200 OK 1657ms]
GET 
XHR 
https://cloud.example.org/owncloud/ocs/v2.php/apps/notifications/api/v1/notifications [HTTP/1.1 200 OK 1883ms]

nothing more

@jvillafanez
Copy link
Member

Hopefully the samba server holds more information. It could be caused by some kind of timeout, but I'm not sure if it's client or server side.

Checked http://www.eetimes.com/document.asp?doc_id=1272058 specially the part of:

To complicate matters further, Windows clients can time out and stop transferring files on a slow connection. Even if the underlying TCP connection is still active, the CIFS clients will time out waiting for data and close the connection. The user has no choice but to retry the transfer, which, of course, might fail again.

Although it mentions Windows clients, libsmbclient might apply something similar.

If you could provide the logs for the samba server we could check if something is wrong.

@jankowa
Copy link
Author

jankowa commented Dec 20, 2016

For now I didn't get any further information from the samba logs. As a workaround I set up a nginx proxy directly in front of owncloud inside the lan. Accessed through the reverse proxy anything works.

I don't know if this can lead to the conclusion, that the problem maybe is not directly related to samba.

Maybe the problem results in a "double nat". I'll try further to change the network to avoid the second nat.

@Blogshot
Copy link

Any update on this?

After nearly three months and an upgrade to 9.1.4 I'm still experiencing this error. Environment is nearly the same (apache instead of nginx).

@jvillafanez
Copy link
Member

@Blogshot No updates on this topic.

Any information you can provide is very apreciated, specially any log (not only about ownCloud, but also about the SMB server) regarding the communication between ownCloud and SMB. Right now, it's not clear which component is causing the issue: ownCloud or the SMB server.

@jvillafanez
Copy link
Member

Please check if the php-libsmbclient is installed and being used by ownCloud. Quoting myself (#21171 (comment))

It's recommended that php-libsmbclient is installed and being used. I've detected an issue downloading a file in a slow connection using the smbclient wrapper, which shouldn't happen with the native php-libsmbclient library. Make sure the php-libsmbclient version is 0.9.0 or greater.

@PVince81
Copy link
Contributor

PVince81 commented Aug 7, 2017

closing as likely environment issue, please see previous comment

@lock
Copy link

lock bot commented Jul 31, 2019

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.

@lock lock bot locked as resolved and limited conversation to collaborators Jul 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants