Gateway Timeout, Connection closed/expired when uploading big files with sync client

10

#1

We have a distributed ownCloud with a tcp loadbalancer in front, 4 web servers(apache+php7.1-fpm) and openstack swift object storage as backend.

I was getting Gateway Timeout when uploading a 500mb file using my gnu/linux desktop sync client. After increasing Apache Timeout setting to 300 this 500mb file was uploaded smoothly. Then I uploaded a 1.2gb file and now I’m getting “Connection close”.

Timeout and connection close happens after all file chunks are uploaded and assembled in the web server. So it seems that timeout is triggered while there is a tcp established connection but no effective interaction between server and client, it’s like server is lacking to tell sync client that he is putting uploaded chunks together do upload to storage backend.

I don’t want to increase too much my connection timeout since this could run into performance issues.

I’m not sure if I was clear, any further information, just ask.

Steps to reproduce

  1. Upload 1gb file using desktop sync client to a server with object storage backend

Expected behaviour

File should be uploaded with no error

Actual behaviour

Upload get’s timeout or connection close while server is putting pieces together and uploading to object storage backend

Server configuration

Operating system: Ubuntu 14.04.5 LTS

Web server: Apache/2.4.34 (Ubuntu)

Database: mysqld Ver 5.5.54-1trusty for debian-linux-gnu on x86_64 ((Ubuntu), wsrep_25.20)
galera-3 25.3.23+1trusty

PHP version: 7.1.23-3+ubuntu14.04.1+deb.sury.org+1 (fpm-fcgi)

ownCloud version: 10.0.4

Updated from an older ownCloud or fresh install: Updated from 7, then from 9

Where did you install ownCloud from: tar.gz from owncloud.org

The content of config/config.php:

{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
           "***REMOVED SENSITIVE VALUE***",
        ],
        "trusted_proxies": [
           "***REMOVED SENSITIVE VALUE***",
        ],
        "forwarded_for_headers": [
            "HTTP_X_FORWARDED",
            "HTTP_FORWARDED_FOR"
        ],
        "allow_user_to_change_display_name": false,
        "appstoreenabled": false,
        "asset-pipeline.enabled": true,
        "custom_csp_policy": "default-src 'self'; script-src  'self' 'unsafe-eval' 'unsafe-inline'; style-src 'self' 'unsafe-inline'; frame-src *; img-src 'self' blob: *; font-src *  'self' data:; media-src *",
        "datadirectory": "\/var\/www\/owncloud\/data",
        "default_language": "pt_BR",
        "dbtype": "mysql",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "dbtableprefix": "oc_",
        "enable_avatars": false,
        "forcessl": true,
        "has_internet_connection": false,
        "installed": true,
        "knowledgebaseenabled": false,
        "log_type": "syslog",
        "logfile": "",
        "loglevel": "0",
        "logtimezone": "America\/Recife",
        "lost_password_link": "disabled",
        "mail_domain":"***REMOVED SENSITIVE VALUE***",
        "mail_from_address": "noreply",
        "mail_smtphost":"***REMOVED SENSITIVE VALUE***",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "000",
        "mail_smtpauth": true,
        "mail_smtpauthtype": "LOGIN",
        "mail_smtpmode": "smtp",
        "mail_smtpsecure": "tls",
        "maintenance": false,
        "session_lifetime": "2592000",
        "trashbin_retention_obligation": "auto, 30",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "memcache.distributed": "\\OC\\Memcache\\Memcached",
        "memcached_servers": [
        ],
        "memcached_options": {
            "14": 50,
            "15": 50,
            "19": 50,
            "20": 50,
            "8": 50,
            "-1001": true,
            "16": true,
            "18": true
        },
        "objectstore": {
            "class": "OCA\\AnolisOpenStack\\Service\\Swift",
            "arguments": {
                "***REMOVED SENSITIVE VALUE***",
            }
        },
        "guests": {
           "***REMOVED SENSITIVE VALUE***",
                }
            }
        },
        "overwrite.cli.url": "***REMOVED SENSITIVE VALUE***",
        "skeletondirectory": "",
        "updatechecker": false,
        "version": "10.0.4.4",
   }
}

List of activated apps:

Enabled:
  - account_closure: 0.0.3
  - activity: 2.3.6
  - anolis_guests: 0.0.1
  - anolis_openstack: 0.0.1
  - comments: 0.3.0
  - configreport: 0.1.1
  - customgroups: 0.3.6
  - dav: 0.3.2
  - edudrive_security: 0.0.1
  - federatedfilesharing: 0.3.1
  - federation: 0.1.0
  - feedback: 1.1
  - files: 1.5.1
  - files_external: 0.7.1
  - files_pdfviewer: 0.8.2
  - files_restriction: 1.0.0
  - files_sharing: 0.10.1
  - files_texteditor: 2.2.1
  - files_trashbin: 0.9.1
  - files_versions: 1.3.0
  - files_videoplayer: 0.9.8
  - folder_uploader: 0.0.1
  - gallery: 16.0.2
  - interactive_tutorial: 1.0
  - notifications: 0.3.2
  - oauth2: 0.2.1
  - provisioning_api: 0.5.0
  - systemtags: 0.3.0
  - templateeditor: 0.1
  - theme-edudrive: 1.0.0
  - updatenotification: 0.2.1
  - user_shib: 0.1

Are you using external storage, if yes which one: yes, openstack swift

Are you using encryption: no

Are you using an external user-backend, if yes which one: Yes, Shibboleth

Client configuration

Desktop Client: 2.4.3

Browser: Firefox 64.0 (64-bit)

Operating system: Gentoo, kernel 4.18.20

Logs

no logs


#2

Hey,

this looks to me like a quite outdated version of ownCloud (currently 10.0.10 is the most recent one). Have you considered to update to the latest version?