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

File is empty, although server reported x size #3411

Closed
husim0 opened this issue Jul 4, 2020 · 2 comments
Closed

File is empty, although server reported x size #3411

husim0 opened this issue Jul 4, 2020 · 2 comments

Comments

@husim0
Copy link

husim0 commented Jul 4, 2020

How to use GitHub

  • Please use the 👍 reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Steps to reproduce

  1. Add a large folder (27 GB +) containing 11.000 pictures and videos in Nextcloud desktop.
  2. Upload seems to run okay.

Expected behaviour

Everything should run smoothly, no error message should appear in Nextcloud desktop. No file should be deleted.

Actual behaviour

"File is empty, although server reported x size" message appears in Nextcloud desktop. File is removed locally in my computer but exists in the server.

Server configuration

Operating system: Debian 10

Web server: apache2

Database: PostgreSQL

PHP version: 7.4.X

Nextcloud version: 19.0.0 (but pretty sure it existed also in 18.0.X)

Updated from an older Nextcloud/ownCloud or fresh install: fresh install (but pretty sure it existed too on my last installation upgraded from 18 to 19).

Where did you install Nextcloud from:

Signing status:

Signing status
No errors have been found.

List of activated apps:

App list
Enabled:
  - accessibility: 1.5.0
  - activity: 2.12.0
  - bruteforcesettings: 1.6.0
  - calendar: 2.0.3
  - cloud_federation_api: 1.2.0
  - comments: 1.9.0
  - contacts: 3.3.0
  - contactsinteraction: 1.0.0
  - dav: 1.15.0
  - encryption: 2.7.0
  - federatedfilesharing: 1.9.0
  - federation: 1.9.0
  - files: 1.14.0
  - files_pdfviewer: 1.8.0
  - files_rightclick: 0.16.0
  - files_sharing: 1.11.0
  - files_trashbin: 1.9.0
  - files_versions: 1.12.0
  - files_videoplayer: 1.8.0
  - firstrunwizard: 2.8.0
  - logreader: 2.4.0
  - lookup_server_connector: 1.7.0
  - mail: 1.4.0
  - nextcloud_announcements: 1.8.0
  - notifications: 2.7.0
  - oauth2: 1.7.0
  - password_policy: 1.9.1
  - photos: 1.1.0
  - privacy: 1.3.0
  - provisioning_api: 1.9.0
  - recommendations: 0.7.0
  - richdocuments: 3.7.3
  - richdocumentscode: 4.2.503
  - serverinfo: 1.9.0
  - settings: 1.1.0
  - sharebymail: 1.9.0
  - spreed: 9.0.1
  - support: 1.2.1
  - survey_client: 1.7.0
  - systemtags: 1.9.0
  - tasks: 0.13.1
  - text: 3.0.1
  - theming: 1.10.0
  - twofactor_backupcodes: 1.8.0
  - updatenotification: 1.9.0
  - viewer: 1.3.0
  - workflowengine: 2.1.0
Disabled:
  - admin_audit
  - files_external
  - user_ldap

Nextcloud configuration:

Config report
{
    "system": {
        "htaccess.RewriteBase": "\/",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "memcache.distributed": "\\OC\\Memcache\\Redis",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": 6379
        },
        "apps_paths": [
            {
                "path": "\/var\/www\/html\/apps",
                "url": "\/apps",
                "writable": false
            },
            {
                "path": "\/var\/www\/html\/custom_apps",
                "url": "\/custom_apps",
                "writable": true
            }
        ],
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "nextcloud.nealta.fr"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "objectstore": {
            "class": "\\OC\\Files\\ObjectStore\\S3",
            "arguments": {
                "bucket": "nealta-nextcloud-data",
                "autocreate": true,
                "key": "***REMOVED SENSITIVE VALUE***",
                "secret": "***REMOVED SENSITIVE VALUE***",
                "hostname": "s3.nl-ams.scw.cloud",
                "port": 443,
                "use_ssl": true,
                "region": "nl-ams"
            }
        },
        "dbtype": "pgsql",
        "version": "19.0.0.12",
        "overwrite.cli.url": "https:\/\/nextcloud.nealta.fr",
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "overwritehost": "nextcloud.nealta.fr",
        "overwriteprotocol": "https",
        "mail_smtpmode": "smtp",
        "mail_smtpsecure": "tls",
        "mail_sendmailmode": "smtp",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpauth": 1,
        "mail_smtpauthtype": "PLAIN",
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "587",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true
    }
}

Are you using external storage, if yes which one:

S3 is used as backend system. But on my previous installation I had the same problem with a SFTP external storage.

Are you using encryption: yes

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

Client configuration

Browser: Firefox 77

Operating system: Fedora

Logs

Web server error log

Web server error log
Can't find any relevant log

Nextcloud log (data/nextcloud.log)

Nextcloud log
[no app in context] Error: Couldn't re-calculate unencrypted size for files/Photos/0000 - Numérisations/Numérisations/NUM1161.jpeg

GET /remote.php/dav/files/xxx/Photos/0000%20-%20Num%C3%A9risations/Num%C3%A9risations/NUM1161.jpeg
from 82.XX.64.XXX by xxx at 2020-07-04T18:57:31+00:00

[webdav] Fatal: Sabre\DAV\Exception\BadRequest: Expected filesize of 293879 bytes but read (from Nextcloud client) and wrote (to Nextcloud storage) 229376 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/apps/dav/lib/Connector/Sabre/Directory.php line 154
   OCA\DAV\Connector\Sabre\File->put(null)
1. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 1104
   OCA\DAV\Connector\Sabre\Directory->createFile("NUM739.jpg", null)
2. /var/www/html/3rdparty/sabre/dav/lib/DAV/CorePlugin.php line 527
   Sabre\DAV\Server->createFile("files/xxx/P ... g", null, null)
3. /var/www/html/3rdparty/sabre/event/lib/WildcardEmitterTrait.php line 89
   Sabre\DAV\CorePlugin->httpPut(Sabre\HTTP\Request {}, Sabre\HTTP\Response {})
4. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 474
   Sabre\DAV\Server->emit("method:PUT", [Sabre\HTTP\Requ ... }])
5. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 251
   Sabre\DAV\Server->invokeMethod(Sabre\HTTP\Request {}, Sabre\HTTP\Response {})
6. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 319
   Sabre\DAV\Server->start()
7. /var/www/html/apps/dav/lib/Server.php line 320
   Sabre\DAV\Server->exec()
8. /var/www/html/apps/dav/appinfo/v2/remote.php line 35
   OCA\DAV\Server->exec()
9. /var/www/html/remote.php line 167
   require_once("/var/www/html/a ... p")

PUT /remote.php/dav/files/xxx/Photos/0000%20-%20Num%C3%A9risations/Num%C3%A9risations/NUM739.jpg
from 82.XX.64.XXX by xxx at 2020-07-04T18:55:51+00:00

[webdav] Fatal: Sabre\DAV\Exception\BadRequest: Expected filesize of 314560 bytes but read (from Nextcloud client) and wrote (to Nextcloud storage) 0 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/apps/dav/lib/Connector/Sabre/Directory.php line 154
   OCA\DAV\Connector\Sabre\File->put(null)
1. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 1104
   OCA\DAV\Connector\Sabre\Directory->createFile("NUM744.jpg", null)
2. /var/www/html/3rdparty/sabre/dav/lib/DAV/CorePlugin.php line 527
   Sabre\DAV\Server->createFile("files/xxx/P ... g", null, null)
3. /var/www/html/3rdparty/sabre/event/lib/WildcardEmitterTrait.php line 89
   Sabre\DAV\CorePlugin->httpPut(Sabre\HTTP\Request {}, Sabre\HTTP\Response {})
4. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 474
   Sabre\DAV\Server->emit("method:PUT", [Sabre\HTTP\Requ ... }])
5. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 251
   Sabre\DAV\Server->invokeMethod(Sabre\HTTP\Request {}, Sabre\HTTP\Response {})
6. /var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php line 319
   Sabre\DAV\Server->start()
7. /var/www/html/apps/dav/lib/Server.php line 320
   Sabre\DAV\Server->exec()
8. /var/www/html/apps/dav/appinfo/v2/remote.php line 35
   OCA\DAV\Server->exec()
9. /var/www/html/remote.php line 167
   require_once("/var/www/html/a ... p")

PUT /remote.php/dav/files/xxx/Photos/0000%20-%20Num%C3%A9risations/Num%C3%A9risations/NUM744.jpg
from 82.XX.64.XXX by xxx at 2020-07-04T18:59:19+00:00

Browser log

Browser log
Can't find any relevant log

Strange thing is that I don't have this problem with any other synced folder.

Thank you !

@szaimen szaimen transferred this issue from nextcloud/server Jun 7, 2021
@camilasan
Copy link
Member

Hi, Could you try to run the most recent desktop client and server to check if you still have this issue? The latest version can be seen by checking https://nextcloud.com/install/#install-clients and https://nextcloud.com/install/#instructions-server respectively.

If you still have this problem with the latest desktop client, please re-open the issue.

Thanks!

@isdnfan
Copy link

isdnfan commented Mar 1, 2022

duplicate of #1946

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants