nextcloud / desktop

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

[Bug] Explorer hangs if network share is inaccessible #4304

Open tryallthethings opened 2 years ago

tryallthethings commented 2 years ago

Expected behavior

Nextcloud Desktop sync client should just mark the folder sync as error if the network share is not reachable at the moment.

Actual behavior

tldr: Nextcloud Desktop sync client causes explorer.exe and related processes to hang or have a huge delay in response.

I got 3 Folder Syncs configured in my desktop sync client. One of those was a Samba network share on an Ubuntu server. Last week I retired that server. Naturally, the share wasn't available anymore after that. This caused the Nextcloud client to behave weirdly. When it was started during after logging into Windows or via Start menu, it almost never got to a responsive state. Neither right nor left click worked on the icon in the taskbar to change the settings. Sometimes (after right-clicking and waiting for 10-15 minutes), I could select settings. The settings window would open and immediately be unresponsive again. So I was never able to remove or change the folder sync location. Additionally, while Nextcloud was running, Windows Explorer wouldn't open at all or freeze (application is not responding) during copy / pasting and especially while opening the context menu on files inside and outside of Nextcloud sync folders. The start menu was showing similar issues (late response / freezes). As soon as I "killed" the nextcloud.exe process via task manager, my system would work as normal. (In case it's relevant: I tried removing and reinstalling the client with the same result. Sync configuration was kept between installations) In the end, I had to edit nextcloud.cfg manually to change the folder sync to the new path. I can reproduce the issue by switching the server hostname in the nextcloud.cfg between the old (offline) and new server share.

Steps to reproduce

  1. Have a folder sync configured to a samba network share
  2. Switch off server
  3. Reboot client pc

Client configuration

Client version: 3.4.2 Operating system: Windows 10 Pro 21H1 OS language: en-us Installation path of client: default (C:\Program Files\Nextcloud)

Server configuration

Nextcloud version: 22.2.5

Logs

  1. Client logfile: As I couldn't upload the debug archive as a single file (~34MB in size) I split it into 2: nextcloud_1.zip nextcloud_2.zip
github-actions[bot] commented 2 years ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

tryallthethings commented 2 years ago

Issue still present in version 3.4.4.

github-actions[bot] commented 2 years ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

tryallthethings commented 2 years ago

Could someone please at least acknowledge this bug, so it doesn't go stale every 30 days?

github-actions[bot] commented 2 years ago

This bug report is getting automatically closed due to no answer since the issue has been staled. Thank you!

Xansala commented 2 years ago

Same issue for me too. The hanging does not last that long for me (maybe ~30 seconds) but it is still annoying. Also once a folder is loaded in the explorer it does not hang again. Interestingly this issue applies to folders that are actually not synced with Nextcloud like "Desktop" or "Downloads". On an additional note: this issue also arises even if the folder synced over network is set to "Paused".

I am using the latest version 3.5.0. The issue only happened for the last year or so. Hence it must be something that came during that time.

Could someone please at least acknowledge this bug, so it doesn't go stale every 30 days?

github-actions[bot] commented 2 years ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

tryallthethings commented 2 years ago

Reporting bugs for Nextcloud sure is annoying.

Xansala commented 2 years ago

Reporting bugs for Nextcloud sure is annoying.

@FlexW: Can you please remove the stale flag from this bug report? We have at least two users with this issue who confirmed.

github-actions[bot] commented 2 years ago

This bug report is getting automatically closed due to no answer since the issue has been staled. Thank you!

Xansala commented 2 years ago

This bug report is getting automatically closed due to no answer since the issue has been staled. Thank you!

The bug remains... please keep it open!

github-actions[bot] commented 2 years ago

This bug report is getting automatically closed due to no answer since the issue has been staled. Thank you!

github-actions[bot] commented 2 years ago

This bug report is getting automatically closed due to no answer since the issue has been staled. Thank you!

Xansala commented 2 years ago

Issue remains with 3.6.0

joneuhauser commented 2 years ago

I have the same issue, Nextcloud client 3.6.0. The symptoms are identical (Nextcloud is almost never responsive, Explorer freezes up, right click hangs even on non-Nextcloud files, and after closing Nextcloud, everything is working again). However, I don't have any inaccessible share, just one, perfectly accessible (at least in the browser) nextcloud drive.

MingLin-home commented 2 years ago

I have the same issue with 3.6.1 and 3.5.X.

Bizikneidi commented 2 years ago

Same problem here on version 3.6.1, after opening the explorer it just freezes for ~15 seconds, after this initial freeze it just behaves normally, even after closing and reopening the explorer. Only after a restart or after waking from sleep the issue comes up again, really annoying. The problems started after switching to virtual file support and persisted since then.

Xansala commented 2 years ago

Issue remains with 3.6.2

zBeeble42 commented 1 year ago

I believe I'm affected by this issue, too.

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

Xansala commented 1 year ago

Issue remains with 3.6.4 ...

Xansala commented 1 year ago

Issue remains with 3.7.1

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

tryallthethings commented 1 year ago

Issue remains with 3.7.3

Xansala commented 1 year ago

Issue remains with 3.8.0

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

Xansala commented 1 year ago

Issue remains with 3.8.1

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

Xansala commented 1 year ago

Remains with 3.8.2

nihues commented 1 year ago

Started getting on 3.9.0 after moving to 27 branch... (and changed dns configuration), so not sure exactly where is the cause, but it's annoying as hell.

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

Xansala commented 1 year ago

Remains in 3.9.1

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

tryallthethings commented 1 year ago

I wasn't able to reproduce with version 3.9.3. Can you please check if you can? @Xansala @nihues @Bizikneidi

Small update: While my Explorer seems unaffected so far, the Nextcloud itself is unresponsive and opening the settings from the taskbar takes minutes.

Xansala commented 1 year ago

I wasn't able to reproduce with version 3.9.3. Can you please check if you can? @Xansala @nihues @Bizikneidi

Small update: While my Explorer seems unaffected so far, the Nextcloud itself is unresponsive and opening the settings from the taskbar takes minutes.

Unfortunately the issue remains for me. It is a bit different now. When booting the PC and the network location is not reachable, then it seems to work. But when I open Firefox, Print a page and save as PDF, the explorer still hangs with 3.9.3.

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

tryallthethings commented 1 year ago

Still an issue

github-actions[bot] commented 1 year ago

This bug report did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

Xansala commented 1 year ago

Remains with 3.10.1

pspeter commented 10 months ago

I experience the same or at least very similar issues right now. However, my Nextcloud Server is still available and reachable (I can log into it using the browser). In fact, I believe the issues started when I added a semi-big chunk of files to my local Nextcloud folder to get synced (it did not start immediately, only after some time, maybe after a reboot).

Clicking the Nextcloud tray icon (right or left) does nothing. Hovering over it displays the tooltip "Nextcloud: Sync is running".

My Windows Explorer is completely messed up:

Closing the nextcloud client via task manager fixes the explorer.

Looking at the task manager, it doesn't seem like nextcloud is actually syncing anything, the network traffic is 0%. image

In the logs, there's lots of warnings that look like this:

2024-01-11 22:26:13:442 [ warning nextcloud.sync.propagator.directory C:\Users\User\AppData\Local\Temp\windows-19197\client-building\desktop\src\libsync\owncloudpropagator.cpp:1251 ]: Useless task found for file "path/to/file" instruction CSyncEnums::CSYNC_INSTRUCTION_SYNC

and a few:

2024-01-11 22:26:13:442 [ warning nextcloud.gui.activity C:\Users\User\AppData\Local\Temp\windows-19197\client-building\desktop\src\gui\tray\usermodel.cpp:840 ]:   Item  "other/file"  retrieved resulted in error  "Ignored because of the \"choose what to sync\" blacklist"

At the end, there's a few of these info logs before it completely stops and does not continue:

2024-01-11 22:26:13:454 [ info nextcloud.sync.propagator.bulkupload C:\Users\User\AppData\Local\Temp\windows-19197\client-building\desktop\src\libsync\bulkpropagatorjob.cpp:189 ]: "different/file/path" transmission checksum "64fd03305a37a12d0e3d9360c81fd3b9" "C:/Users/local/different/file/path"
pspeter commented 10 months ago

I experienced the same or at least very similar issues. However, my Nextcloud Server was still available and reachable (I can log into it using the browser). In fact, I believe the issues started when I added a semi-big chunk of files to my local Nextcloud folder to get synced (it did not start immediately, only after some time, maybe after a reboot).

Clicking the Nextcloud tray icon (right or left) does nothing. Hovering over it displays the tooltip "Nextcloud: Sync is running".

My Windows Explorer is completely messed up:

Closing the nextcloud client via task manager fixes the explorer.

Looking at the task manager, it doesn't seem like nextcloud is actually syncing anything, the network traffic is 0%. image

In the logs, there's lots of warnings that look like this:

2024-01-11 22:26:13:442 [ warning nextcloud.sync.propagator.directory C:\Users\User\AppData\Local\Temp\windows-19197\client-building\desktop\src\libsync\owncloudpropagator.cpp:1251 ]: Useless task found for file "path/to/file" instruction CSyncEnums::CSYNC_INSTRUCTION_SYNC

and a few:

2024-01-11 22:26:13:442 [ warning nextcloud.gui.activity C:\Users\User\AppData\Local\Temp\windows-19197\client-building\desktop\src\gui\tray\usermodel.cpp:840 ]:   Item  "other/file"  retrieved resulted in error  "Ignored because of the \"choose what to sync\" blacklist"

At the end, there's a few of these info logs before it completely stops and does not continue:

2024-01-11 22:26:13:454 [ info nextcloud.sync.propagator.bulkupload C:\Users\User\AppData\Local\Temp\windows-19197\client-building\desktop\src\libsync\bulkpropagatorjob.cpp:189 ]: "different/file/path" transmission checksum "64fd03305a37a12d0e3d9360c81fd3b9" "C:/Users/local/different/file/path"

I managed to fix it by deleting the folder mentioned in the bulkupload line at the end.

Xansala commented 4 months ago

Issue remains with 3.13.2

joshtrichards commented 3 months ago

@tryallthethings Your original report says "network share". Are you referring to a server-side Nextcloud External Storage mount?

tryallthethings commented 3 months ago

@joshtrichards My original network post said "Samba network share". Or call it a windows share / SMB protocol if you like.

joshtrichards commented 3 months ago

Yes, but where/how is the network share associated with the client? Is it an SMB-based External Storage mount on the Nextcloud Server? Or are you referring to an SMB mount you have on your client device?

Xansala commented 2 months ago

@joshtrichards thanks a lot for your help and looking into this annoying bug!

I let @tryallthethings answer as well for his situation ;) . For me it is a SMB mount I have on the client device that I sync only once a while for a backup into the cloud. To be concrete: it is a picture folder I have on my NAS for which I have a backup in the cloud on my VPS and I use nextcloud to sync it. However, the NAS is not always running, so when the NAS is not connected, the client is hanging.

tryallthethings commented 2 months ago

My apologies, I assumed my initial post was clear on that matter, and I was under the impression that folder sync is only available in the desktop client.

I got 3 Folder Syncs configured in my desktop sync client. One of those was a Samba network share on an Ubuntu server.

Steps to reproduce

  1. Have a folder sync configured to a samba network share
  2. Switch off server
  3. Reboot client pc

So my setup at the time I raised the issue was very similar to what @Xansala is using. I just tried to reproduce the issue with the latest desktop client (3.13.3). While I still saw some issues with the Windows Explorer behaving odd / slow, I couldn't get it to freeze up completely as it did before. So I'd assume the issue is still present. At least the client stays mostly responsive, and I can get into the settings or show the status

image