xybu / onedrive-d-old

Microsoft OneDrive client on Linux.
http://xybu.me/projects/onedrive-d/
GNU Lesser General Public License v3.0
821 stars 144 forks source link

Sync multiple times leads to multiple copies of files. #220

Open dforero0896 opened 7 years ago

dforero0896 commented 7 years ago

Hey there, I just installed onedrive-d-old and sync was well but after some time (couple hours I believe), it appears to have stopped. When restarting I get:

Loading configuration ... OK
[2017-01-19 13:46:33,862] DEBUG: MainThread: running in daemon node.
Stopping onedrive-d ... FAILED
ERROR: Timed out while waiting for process (PID 2175) to terminate

But status then shows:

Loading configuration ... OK
[2017-01-19 13:47:00,826] DEBUG: MainThread: running in daemon node.
onedrive-d -- not running

So I start it, but it seems to sync the same files I already have in my computer and adds the suffix (user). I've also got a folder of about 4Gb and it currently has 812 Mb and I don't know if it is due to sync stopping or that it's just very slow (so I can blame it on my connection).

Thanks

igavronski commented 7 years ago

See my response in #223 -- seems to be the same case.

paulkoan commented 7 years ago

This isn't just about the thread terminating, but about the multiple copies. It appears that when onedrive is restarted, it doesn't acknowledge that the file that has been already copied over. It then sees a conflict and sends a new copy over, with the ([computer name]) tag inserted before the suffix.

This then gets synced back again to the local store, and then is synced back again to onedrive with an additional ([computername]) suffix:

[2017-03-29 11:01:07,586] DEBUG: worker3: added task "dl" "/[redacted filename] (humfile) (humfile) (humfile) (humfile).xls".

I have around 120 files in my local store that are duplicates with the computer name inserted, and one has 7 duplicates - so the computer name is inserted 7 times.

I looked on onedrive, and there were 955 files with ([computername]) embedded in the filename. In each case (that I checked) the original file was there at the right size.