nextcloud / desktop

💻 Desktop sync client for Nextcloud
https://nextcloud.com/install/#install-clients
GNU General Public License v2.0
2.99k stars 784 forks source link

[Bug]: Endless 'connection closed' error on certain files #5464

Open anonbergine opened 1 year ago

anonbergine commented 1 year ago

⚠️ Before submitting, please verify the following: ⚠️

Bug description

Note: This is not the same as #4278, although the two could be related

For whatever reason, some files fail to upload due to "connection closed" error. Those files then persistently throw that error on subsequent syncs.

The only workaround I've found so far is to alter the file name, usually one character at a time, until the file eventually uploads. If I don't do that, the file will just endlessly sync fail with "connection closed" errors.

As an example, one of dozens of files I have that are currently 'connection closed' bugged is chatham-standup-2019-sep_48734822492_o.jpg. If I rename that to chatham-standup-2019-sep_48734822492_ (removed last char, but any change to the filename would suffice) then nc does at least try and sync it properly thinking it's a new file. However, single name change doesn't always fix the problem - sometimes I have to do several tweaks to filename to get nc to actually upload something.

Steps to reproduce

IDK what causes triggers a file to encounter "connection closed" error, but once it does that error is permanent for that file and it will keep throwing same error every sync attempt - even though other files are uploading just fine.

It seems to occur mainly for media files (jpg, mp4, etc) - of all sizes. Larger files (eg. over 60MB) seem to encounter it more often than smaller ones, but I've had it occur on files as small as 7MB (that I've seen so far, that isn't necessarily a hard size limit).

Expected behavior

Sync, the single most important component of nextcloud, should actually.... sync.

I suspect the lack of resume is part of the problem - having to restart a failed upload from scratch is entirely ludicrous in 2023. There is maybe also problem on serverside if it's for some reason thinking the original upload attempt is still in progress or something?

Which files are affected by this bug

Completely random as far as I can tell

Operating system

Windows

Which version of the operating system you are running.

windows-10.0.19045

Package

Other

Nextcloud Server version

Latest stable (admin updated it few days ago)

Nextcloud Desktop Client version

Version 3.7.3 (Windows)

Is this bug present after an update or on a fresh install?

Updated from a minor version (ex. 3.4.2 to 3.4.4)

Are you using the Nextcloud Server Encryption module?

Encryption is Enabled

Are you using an external user-backend?

Nextcloud Server logs

I don't have access to server. Even if I did, given what I've seen of the client logs, I doubt I would be able to upload due to infestation of PII.

Additional info

I'd really love to upload logs, btw, but there's just too much PII in them.

Have you ever had death threats and gangs of psychos trying to murder you just because of who you are (for real, I'm not embellishing)? I suspect not, because if you had you'd know the importance of not asking users to upload PII infested log files.

Zachhambo commented 2 days ago

Still getting this issue running latest desktop client for windows, with multiple files about 20mb experiencing connection closed error. Renaming does not fix

junglivre commented 1 day ago

bump. same issue happening here.

oussjarrousse commented 1 day ago

To me too!

determ1ne commented 10 hours ago

occ maintenance:repair solved my problem.

I got the same issue and checked the server access log. While normally after PROPFIND /remote.php/dav/files/[filename] a POST /remote.php/dav/bulk would be done, but this time the request was PROPFIND /remote.php/dav/uploads/[username]/[number] and server responded with 404. I was using sqlite3 as db, so I tried occ maintenance:repair and it worked. Sadly, the db converter is not available now.

junglivre commented 7 hours ago

my db is MySQL, I will try repairing