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

Windows Desktop App often uses upload/delete instead of move #7838

Closed
joholm2 opened this issue Apr 4, 2020 · 85 comments · Fixed by #8459
Closed

Windows Desktop App often uses upload/delete instead of move #7838

joholm2 opened this issue Apr 4, 2020 · 85 comments · Fixed by #8459
Milestone

Comments

@joholm2
Copy link

joholm2 commented Apr 4, 2020

Expected behaviour
In Windows explorer make any change to a file or folder, within the same sync area, which can be carried out by a move/rename.

eg...

  • Rename a folder
  • Rename a file
  • Move a file from one folder to another

All of these can be accomplished by a simple move operation.

Actual behaviour
Sometimes a “move” is used
Sometimes files are deleted on the server and re-uploaded.
I see no obvious pattern in how it chooses what method to use.

I thought maybe it depended on file size, but even moving a large (500 MB file) into a sub-folder and later back again resulted in a “move” first (Ok) and later a totally unnecessary upload/delete on returning to the original folder.

This is very inefficient and there is no obvious reason for it.

It can also lead to a very bad situation when renaming a folder containing a large quantity of data.
In cases where Owncloud chooses the upload/delete route the resulting upload can take hours - all totally unnecessary. Aborting such an upload leads to a further catastrophe with potential loss of data.

Steps to reproduce
As described above in Expected behaviour.
Check OwnCloud "Activity" in desktop app.

Example here is for creation of a new (empty) folder and repeated renaming (with idle time of a few seconds between each step). Activity log ordering - bottom to top.
Annotation 2020-04-04 175051
In this case adding the "_test" suffix results in a Move and removing the "_test" suffix results in an Upload followed by a Delete.

Server configuration
Operating system:Ubuntu 18.04

Web server: Apache/2.4.29 (Ubuntu)

Database: mySQL Ver 15.1 Distrib 10.1.43-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2

PHP version: 7.2.24 and now 7.3.16-1

ownCloud version: 10.3.2.2 and now 10.4.0.4

Storage backend (external storage): SMB attached drive

Client configuration
Client version: 2.6.0 and now 2.6.1

Operating system: Windows 10

@michaelstingl
Copy link
Contributor

@joholm2 thank you very much for your feedback. Please provide a few lines of the client debug log from the time of the incident. (see https://doc.owncloud.org/desktop/2.6/troubleshooting.html#log-files)

@joholm2
Copy link
Author

joholm2 commented Apr 5, 2020

Hi,

I enabled logging as you said and carried out a short test...

  • Created a new folder
  • Named it
  • Renamed it
  • Set name back to original
  • Created file in folder
  • Name file
  • Renamed file
  • Set file name back to original
  • Renamed folder again
  • Set folder name back to original

The activity log shows both "Moves" and "Upload/Deletes" - where just Moves should have been used.

Annotation 2020-04-06 005031

I don't yet understand the logging process but appear to have acquired multiple log files; attached here...

Edit... removed numerous log files and will post more specific case below..

@michaelstingl
Copy link
Contributor

I don't yet understand the logging process but appear to have acquired multiple log files; attached here...

Desktop app checks for new changes after 30 second wait period. From every sync run, the log is written to a new file.

@joholm2
Copy link
Author

joholm2 commented Apr 7, 2020

I don't see any 30 delay in syncing. When I create a "New folder" and rename it as fast as I can, the App always jumps in and uploads "New folder" and then uploads the renamed one and deletes "New folder". Better if it did wait a few moments.

But how ar the log files? Do they show why it does so many unnecessary upload & deletes?

@michaelstingl
Copy link
Contributor

I don't see any 30 delay in syncing. When I create a "New folder" and rename it as fast as I can, the App always jumps in and uploads "New folder" and then uploads the renamed one and deletes "New folder".

Sorry, I didn't explain precise. Local changes get synced immediately. Desktop app always checks for new server-side changes after 30 second wait period.

But how ar the log files? Do they show why it does so many unnecessary upload & deletes?

Didn't check the log files yet.

@joholm2
Copy link
Author

joholm2 commented Apr 10, 2020

One new log file attached.

Two step test... (what I did)

  1. "Test_document.docx" renamed to ""Test_document_renamed.docx"´
  2. "Test_document_renamed.docx" renamed back to "Test_document.docx"

Result (what Desktop client did)
Step 1 was carried out by a rename
Step 2 was carried out by an upload/delete.

The log covers the period of Step 2.
I have changed the server URL to "https://{server}:{nnnn}" - note port number in the URL.

I notice that a rename is attempted but fails...
Line 22: "Can't rename because the etag has changed or the directory is gone"
...and prior to that there are some "404 Not Found" errors.

owncloud_rename_fails.txt

Any help, advice or suggestions would be much appreciated.

@joholm2
Copy link
Author

joholm2 commented Apr 11, 2020

I collected logs from both client and server during a simple test similar to the one above; in this case just renaming a file (with result upload/delete).

I see the same "Can't rename because the etag has....." in the client log; and on the server there is an equivalent error when trying to access the file to be renamed.... ...."message":"Exception: HTTP/1.1 404 File with name {filename} could not be located:

One thing I don't understand in the server log is large numbers of pairs of lines...

updateToken","method":"DELETE","url":"{url-to-file}","message":"updating token ddd, last check is now dddddddddd"}
...followed immediately by a "getToken" for the same file...
getToken","method":"DELETE","url":"{url-to-file}","message":"token hhhhhhh...really-long-hexadec.....hhhhhhh does not exist"

The method (DELETE in example above) varies between DELETE, PROPFIND and PUT; but the pattern is the same.

Can anyone say whether these getToken responses are normal or an error?

@joholm2
Copy link
Author

joholm2 commented Apr 16, 2020

Hi,

There doesn't seem to be much in the way or responses or help here.

Is this all I can expect from OwnCloud?

For us It's a very big issue - if there is no help or support what else can we do?

@michaelstingl
Copy link
Contributor

Team is busy with other tasks like 2.6.3 and 2.7.0 release and customer requests, and this problem is nothing that can be solved in the short term.

For professional support with guaranteed response times, you'll find options on the bottom of this page:
https://owncloud.org/help/

@joholm2
Copy link
Author

joholm2 commented Apr 16, 2020

Thanks, but i don't need it to be solved in the short term. I just need some help on the way. Anyone who understands these logs could give me some hints as to what they mean in a couple of minutes.

@joholm2
Copy link
Author

joholm2 commented Apr 25, 2020

Just to add that we have set up an owncloud docker image server and repeated the tests.

The results are the same, the issue exists even there; so presumably that rules out any server misconfiguration as the cause of the issue.

@joholm2
Copy link
Author

joholm2 commented Apr 27, 2020

Another test - I installed the latest Windows client on another PC, connected to the same docker image mentioned in my last post and sync'd with the test folder.

a) Same results when moving or renaming folders and files. Most often an upload & delete is used instead of the expected move.

b) When one sync'd PC does the unwanted upload & delete the second PC does a corresponding download & delete.

This is not good - to say the least!

@joholm2
Copy link
Author

joholm2 commented May 17, 2020

I have to ask again...
Is anyone looking into this?
Is the cause of the fault known and understood?
Are there any more logs we can get or tests we can do to help?

It really is an intolerable fault - I just needed to rename a directory containing 4.37 GB of pictures.
Now the Owncloud client is uploading them all again - the time estimate is hovering around 50 minutes.

I've learnt from previous experience that it's best to let it complete it's wasteful upload - in the past, interrupting it has caused even more trouble.

@michaelstingl
Copy link
Contributor

Is anyone looking into this?

Sorry, as mentioned before, nothing planned before 2.6.3 and 2.7.0 release.

ownCloud desktop sync client relies heavily on filesystem events to detect local changes. There are edge cases where the client does not get reliable information. Quite some effort has already been done to detect changes (e.g. checksum comparison), but the remaining cases are really hard to solve. Ensuring the integrity of the data is the higher goal than saving some GB.

I performed a quick test and it detected simple MOVE very reliably. (Using a 2.7 pre-release build on macOS)

Start Docker

docker run --rm -d \
  --name owncloud \
  -p 18080:8080 \
  -e ADMIN_USERNAME=admin \
  -e ADMIN_PASSWORD=admin \
  owncloud/server:latest

Start sync client

% /Applications/testpilotcloud.app/Contents/MacOS/testpilotcloud --logfile ~/tmp/tpc.log --logdebug

Debug log output

You can filter for the folderwatcher

% tail -f -n 1000 tmp/tpc.log | grep "info gui\.folderwatcher"
05-18 00:02:36:944 [ info gui.folderwatcher ]:	Detected changes in paths: QSet("/Users/mstingl_oc/testpilotcloud/Test_document_renamed.docx", "/Users/mstingl_oc/testpilotcloud/Test_document.docx")
05-18 00:02:38:772 [ info gui.folderwatcher ]:	Detected changes in paths: QSet("/Users/mstingl_oc/testpilotcloud/Test_document.docx", "/Users/mstingl_oc/testpilotcloud/Test_document_renamed.docx")
05-18 00:02:41:909 [ info gui.folderwatcher ]:	Detected changes in paths: QSet("/Users/mstingl_oc/testpilotcloud/Test_document_renamed.docx", "/Users/mstingl_oc/testpilotcloud/Test_document.docx")
05-18 00:02:43:484 [ info gui.folderwatcher ]:	Detected changes in paths: QSet("/Users/mstingl_oc/testpilotcloud/Test_document.docx", "/Users/mstingl_oc/testpilotcloud/Test_document_renamed.docx")
05-18 00:03:40:891 [ info gui.folderwatcher ]:	Detected changes in paths: QSet("/Users/mstingl_oc/testpilotcloud/Test_document_renamed.docx", "/Users/mstingl_oc/testpilotcloud/Test_document.docx")

Simple log in sync dir

This log isn't really useful for serious debugging

% tail -f -n 1000 testpilotcloud/.owncloudsync.log | grep Test_document
21:48:51||Test_document.docx -> Test_document_renamed.docx|4|1|1589750679|c39fad53988f3fa4a6e6c2a4b015ac01|6069226|00000011ocbk0cx8s7e9|4||201|0|0|d86b4eaa-c56b-46bc-b92b-d0aed72661d0|
22:01:19||Test_document_renamed.docx -> Test_document.docx|4|1|1589750679|c39fad53988f3fa4a6e6c2a4b015ac01|6069226|00000011ocbk0cx8s7e9|4||201|0|0|df7cbf9a-8548-45c6-a19f-8b9bd7b942f3|
22:01:32||Test_document.docx -> Test_document_renamed.docx|4|1|1589750679|c39fad53988f3fa4a6e6c2a4b015ac01|6069226|00000011ocbk0cx8s7e9|4||201|0|0|975b71f6-84b6-4b91-bb28-7868d7c57ca1|
22:01:59||Test_document_renamed.docx -> Test_document.docx|4|1|1589750679|c39fad53988f3fa4a6e6c2a4b015ac01|6069226|00000011ocbk0cx8s7e9|4||201|0|0|7815c036-2651-4826-88fd-f0c4856f6ed8|
22:02:08||Test_document.docx -> Test_document_renamed.docx|4|1|1589750679|c39fad53988f3fa4a6e6c2a4b015ac01|6069226|00000011ocbk0cx8s7e9|4||201|0|0|a7d31c93-d0c3-454c-ad54-230bf420c8af|
22:03:42||Test_document_renamed.docx -> Test_document.docx|4|1|1589750679|c39fad53988f3fa4a6e6c2a4b015ac01|6069226|00000011ocbk0cx8s7e9|4||201|0|0|523fbd88-2dad-4485-986c-e7b8989f2c5a|

Docker log

% docker logs --follow owncloud | grep Test_document
creating sqlite db
[Sun May 17 21:23:29.850702 2020] [mpm_prefork:notice] [pid 181] AH00163: Apache/2.4.41 (Ubuntu) configured -- resuming normal operations
[Sun May 17 21:23:29.850779 2020] [core:notice] [pid 181] AH00094: Command line: '/usr/sbin/apache2 -f /etc/apache2/apache2.conf -D FOREGROUND'
172.17.0.1 - admin [17/May/2020:21:48:51 +0000] "MOVE /remote.php/dav/files/admin/Test_document.docx HTTP/1.1" 201 651 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:01:18 +0000] "PROPFIND /remote.php/dav/files/admin/Test_document_renamed.docx HTTP/1.1" 207 971 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:01:19 +0000] "MOVE /remote.php/dav/files/admin/Test_document_renamed.docx HTTP/1.1" 201 651 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:01:32 +0000] "MOVE /remote.php/dav/files/admin/Test_document.docx HTTP/1.1" 201 651 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:01:59 +0000] "PROPFIND /remote.php/dav/files/admin/Test_document_renamed.docx HTTP/1.1" 207 971 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:01:59 +0000] "MOVE /remote.php/dav/files/admin/Test_document_renamed.docx HTTP/1.1" 201 651 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:02:08 +0000] "MOVE /remote.php/dav/files/admin/Test_document.docx HTTP/1.1" 201 651 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:03:42 +0000] "PROPFIND /remote.php/dav/files/admin/Test_document_renamed.docx HTTP/1.1" 207 971 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"
172.17.0.1 - admin [17/May/2020:22:03:42 +0000] "MOVE /remote.php/dav/files/admin/Test_document_renamed.docx HTTP/1.1" 201 651 "-" "Mozilla/5.0 (Macintosh) mirall/2.7.0daily20200516 (ownCloud Testpilot Edition, osx-19.4.0 ClientArchitecture: x86_64 OsArchitecture: x86_64)"

Interesting in your log owncloud_rename_fails.txt

  • Strange, no single line containing [ info gui.folderwatcher ]
  • What is your local storage? Is the sync directory located on a network mount? From what I know, there are no filesystem events sent from network mount.
  • Remote SMB mounted storage probably adds an extra layer of complexity
  • Sync client tries hard to detect MOVE operation, but finally decides against it:

04-10 17:24:42:771 [ info sync.discovery ]: Processing "Data/TestFolder/Test_document_rename.docx" | valid: true/false/true | mtime: 1586126680/0/1586126680 | size: 0/0/0 | etag: "97a541031ff61287f051818cd564d844"//"97a541031ff61287f051818cd564d844" | checksum: "SHA1:da39a3ee5e6b4b0d3255bfef95601890afd80709"//"SHA1:da39a3ee5e6b4b0d3255bfef95601890afd80709" | perm: WDNVR//WDNVR | fileid: "00107897ocyhh4g4hc51"//"00107897ocyhh4g4hc51" | inode: 122593/0/ | type: 0/3/0

I'd say your log file is worth another look from more knowledgable experts. I totally understand the inconvenience for you, and I wish the team finds ways to improve here in the future, but there is nothing critical or urgent about it.

@joholm2
Copy link
Author

joholm2 commented May 18, 2020

Hi Michael,

Thanks, we really appreciate your reply.

It's a shame you tested on macOS - we are using Windows so I don't know how closely they match.

Interesting you mention SMB storage. Are you referring to the PC files or the sever file system?

On the PCs we have mainly files on the single hard disk, but one is on a Micro-SD card in a "built in" slot.

On the sever we have a separate Raid storage unit mounted via SMB.

In our setup using Docker we have sync'd only local HD storage on the PC and presumably Docker uses purely local storage on the sever. Since the Docker setup shows the same problems it's hard to draw any conclusions.

@michaelstingl
Copy link
Contributor

Since the Docker setup shows the same problems it's hard to draw any conclusions.

Strange, in my Docker tests, I wasn't able to reproduce. I'll need to have another look when time allows…

@joholm2
Copy link
Author

joholm2 commented May 18, 2020

Thanks, as I mentioned you used a new client on macOS and we have 2.6.1 client on Windows10 - so not directly comparable.

@joholm2
Copy link
Author

joholm2 commented Jun 6, 2020

It's now 3 weeks since I renamed a directory containing about 5 GB of files on my windows PC, and OwnCloud client decided to re-upload the whole lot rather than just rename/move the directory on the server.

I use a program called FreeFileSync to keep a local backup up to date and run that sporadically - often every few weeks. So almost 3 weeks after the "rename" I ran FreeFileSync and watched to see what it did with the directory.

With no problem at all it saw it as a "move" and simply moved it on the backup drive.

So if FreeFileSync can figure it out correctly after 3 weeks it can't be that hard for OwnCloud client after just a few seconds.

Maybe some developer here can take a look at the FreeFileSync code.

@joholm2
Copy link
Author

joholm2 commented Sep 13, 2020

Hi,

We've been waiting now over 7 months and so far no useful help or solution.

We really need to be able to sort out our photo collection without Owncloud continuously up & down-loading gigabytes of files every time we move or rename a folder.

If Owncloud can't function properly we'll need to move on to something which can.

@joholm2
Copy link
Author

joholm2 commented Nov 21, 2020

Today on Windows 10 the ownCloud App updated to 2.1.1

I made a quick test of the synchronisation to my test area in a completely standard Docker/ownCloud.

Moving a sub-folder containing files from one folder to another (in the same sync folder) resulted in a move on the sever. Good - although it beats my why the log shows both folder move and then individual file moves - surely carrying out a proper move of a folder means all the files are included anyway.

But next - move the sub-folder onward to another folder (still within same sync area). This time all the files are upload as if new to the server and the originals are deleted. Bad!

Third try. move te sub-folder back to te starting folder - another upload/delete session - completely unnecessary.

I made several more moves in Windows but no sign of any move operations in the sync log - always uploads and deletes.

So there is no improvement this new version of the Windows app.

This is a critical issue - when will it be fixed?

@joholm2
Copy link
Author

joholm2 commented Dec 5, 2020

I have just completed a switch from Owncloud to Nextcloud.

Same server
Same Linux (Ubunti)
Same data storage device
Same client PC

Tested renaming and moving of folders and files and Nextcloud gets it right every time.

Goodbye Owncloud !!!

@sfadschm
Copy link

Hi all,
as there has not been any action for some time, I decided to add my two cents here.

This behavior is still an issue and I think it is an important one that affects a core functionality of OwnCloud.

The unreliable detection of move/rename operations is a significant efficiency reduction. While I understand the raised point that data consistency is more important than sparing bandwidth, the issue also affects consistency.
Take the following example case:

  1. Move a folder with some file on client A to a different folder (such that reuploading gets triggered).
  2. Abort the reupload process by shutting down (or whatever other way).
  3. Open OwnCloud on a second synced client.

Depending on the sync status when shutting down client 1, the delete operation of the old folder will be processed by the server or not. This can result in the moved files being reuploaded by client 2 to the old location and hence duplicate data.

On another note, the reupload process also destroys the moved files history (because they get deleted and recreated).

IMO, these are two major problems (inconsistent data, corrupted file history, along with unnecessary syncing times) for OwnClouds core functionality that should be addressed, even if they are complicated to resolve.
However, moving files around is working perfectly nice with other clients (e.g. Dropbox, Seafile) so detection based on OS behavior should be possible in principle.

@joholm2 Can you confirm that this still works reliably with NextCloud? There seem to be similar open issues in the tracker (e.g, nextcloud/desktop#2132).

@TheOneRing TheOneRing added this to Qualification in Releases via automation Feb 18, 2021
@TheOneRing TheOneRing moved this from Qualification to Desktop Testing in Releases Feb 18, 2021
@joholm2
Copy link
Author

joholm2 commented Feb 18, 2021 via email

@TheOneRing TheOneRing added this to the 2.8.0 milestone Feb 18, 2021
@gabi18
Copy link
Contributor

gabi18 commented Feb 22, 2021

@joholm2 Could you please confirm that for the last tests the ownCloud client was updated to 2.7.1.. Which ownCloud server version was installed?

@joholm2
Copy link
Author

joholm2 commented Feb 22, 2021

@joholm2 Could you please confirm that for the last tests the ownCloud client was updated to 2.7.1.. Which ownCloud server version was installed?

Yes. I see there is a typo in my comment Nov 2020 where it says 2.1.1. In earlier posts i had already mentioned using 2.6.1, so the November version was undoubtedly 2.7.1.

Owncloud server was always kept up to date, so was whatever was current in November 2020.

@gabi18
Copy link
Contributor

gabi18 commented Feb 22, 2021

Thank you for the quick response!

@sfadschm
Copy link

Just to add to this:
I last experienced the issue yesterday, running client 2.7.6 and server 10.6.0.5.

I also tried playing around with the various ways of moving files in Windows Explorer, but couldn't find any way to work around the issue. Namely, neither using the context menu Cut -> Paste nor the shortcut Strg+X + Strg+V nor simple drag and drop is working consistently. It also does not seem to matter whether the move operation takes place inside the same Explorer window or across two windows.

@TheOneRing
Copy link
Member

I see you have a different way of handling faults than i'm used to. In my day a fault report remained open during anaysis, implementation of a solution, testing, delivery and verification by the user. Then it was only closed when the user confirmed acceptance of the fix.

I tend to test my code, I definitely fixed a bug. If the issue would continue we would have more than one bug involved.

@jnweiger your discovery is unrelated to this issue

I've seen two new types of errors in the logs:

02-25 03:21:34:562 [ info sync.discovery ]:     Processing "Photos/Portugal.jpg" | valid: false/true/db | mtime: 0/1614219677/0 | size: 0/243733/0 | etag: ""//"" | checksum: ""//"" | perm: 0x7f161e4cdd58//0x7f161e4cdd58 | fileid: ""//"" | inode: 0/657847/ | type: CSyncEnums::ItemTypeSkip/CSyncEnums::ItemTypeFile/CSyncEnums::ItemTypeFile
02-25 03:21:34:562 [ debug sync.database.sql ]  [ OCC::SqlQuery::bindValue ]:   SQL bind 1 657847
02-25 03:21:34:562 [ debug sync.database.sql ]  [ OCC::SqlQuery::exec ]:        SQL exec "SELECT path, inode, modtime, type, md5, fileid, remotePerm, filesize,  ignoredChildrenRemote, contentchecksumtype.name || ':' || contentChecksum FROM metadata  LEFT JOIN checksumtype as contentchecksumtype ON metadata.contentChecksumTypeId == contentchecksumtype.id WHERE inode=?1"
02-25 03:21:34:562 [ info sync.discovery ]:     Not a move, no item in db with inode 657847
02-25 03:21:34:562 [ info sync.discovery ]:     Discovered "Photos/Portugal.jpg" CSyncEnums::CSYNC_INSTRUCTION_NEW OCC::SyncFileItem::Up CSyncEnums::ItemTypeFile

We couldn't find any information about the file we detected as move origin in the db.
Not sure this is an issue.

and

02-25 03:18:53:592 [ info sync.discovery ]:     Processing "Portugal.jpg" | valid: false/true/false | mtime: 0/1614219503/0 | size: 0/243733/0 | etag: ""//"" | checksum: ""//"" | perm: 0x7f72fcb4bd58//0x7f72fcb4bd58 | fileid: ""//"" | inode: 0/657848/ | type: CSyncEnums::ItemTypeSkip/CSyncEnums::ItemTypeFile/CSyncEnums::ItemTypeFile
02-25 03:18:53:592 [ debug sync.database.sql ]  [ OCC::SqlQuery::bindValue ]:   SQL bind 1 657848
02-25 03:18:53:592 [ debug sync.database.sql ]  [ OCC::SqlQuery::exec ]:        SQL exec "SELECT path, inode, modtime, type, md5, fileid, remotePerm, filesize,  ignoredChildrenRemote, contentchecksumtype.name || ':' || contentChecksum FROM metadata  LEFT JOIN checksumtype as contentchecksumtype ON metadata.contentChecksumTypeId == contentchecksumtype.id WHERE inode=?1"
02-25 03:18:53:592 [ info sync.discovery ]:     Not a move, base file still exists at "Photos/Portugal.jpg"
02-25 03:18:53:592 [ info sync.discovery ]:     Discovered "Portugal.jpg" CSyncEnums::CSYNC_INSTRUCTION_NEW OCC::SyncFileItem::Up CSyncEnums::ItemTypeFile

This one indicates that by the time we want to populate the move the move was already reverted by your script

If you remove the && break clauses from the loops, then you should see move operations again after a while, followed by another round of delete+create, and so on ...

If you find out that move detection on linux is unreliable please open a new issue.

@sfadschm
Copy link

You can test-drive with tomorrows 2.7.x daily builds:
https://download.owncloud.com/desktop/

I might be blind, but the latest testpilot and daily builds I can find are from 21 February for 2.7.7 and 08 February for 2.7.6.

@michaelstingl
Copy link
Contributor

Mac & Win built this morning. Looks like an issue with the Linux builds:

@sfadschm
Copy link

Okay, will try to test them.
Strange enough the modification dates and names do not seem to match then.

Testpilotcloud

(Sorted by modification date or name ascending.)

@sfadschm
Copy link

Issue persists with testpilotcloud-2.7.7-daily20210221.3401.x64.msi.
Maybe I'm just to dumb to download the newest daily build...

@gabi18
Copy link
Contributor

gabi18 commented Mar 1, 2021

It seems the daily build isn't working. There are no new builds with the bug-fix available.

Confirmed the bug-fix with a local build from github on Linux:
renaming inside a sync folder connection now always triggers a move.

@sfadschm
Copy link

sfadschm commented Mar 1, 2021

@gabi18 if you tested on Linus, is this #8458 then?

@gabi18
Copy link
Contributor

gabi18 commented Mar 1, 2021

No, my test is valid for this issue.

The problem with upload/delete using a folder sync connection is reproducible on Linux. I got similar error messages '404 Not Found' and 'Can't rename because the etag has changed or the directory is gone...' in the logfile.

20210301_0637_client_2-7-6.log.0.gz

Testing the client compiled from source code containing the bug-fix on Linux shows the desired behavior, only moves resp. renames are done (-> Rename detected (up)...).

20210301_1335_client_2-7-7git.log.0.gz

@gabi18
Copy link
Contributor

gabi18 commented Mar 1, 2021

The up-to-date daily win-build will be available soon.

@sfadschm
Copy link

sfadschm commented Mar 2, 2021

Can confirm the issue to be resolved on Win10 using testpilotcloud-2.7.7-daily20210302.3418.x64.msi with multiple file renames, moving in and out of folder and moving between subfolders.

@jnweiger jnweiger assigned jnweiger and unassigned jnweiger Mar 3, 2021
@gabi18 gabi18 mentioned this issue Mar 11, 2021
43 tasks
@jnweiger jnweiger modified the milestones: 2.9.0, 2.8.0 Apr 15, 2021
@jnweiger jnweiger removed this from Desktop Testing in Releases Apr 15, 2021
@Darkexy
Copy link

Darkexy commented Aug 18, 2021

Hi there,
I hope I don't have to open an new issue, but can use this. I'm actually facing the same problem as joholm2 last year.

A few days ago I recognized that my selfhosted OwnCloud on a Raspi 4 within my home network got very slow download. I have both, the Raspi and my Desktop on a 1Gbit-Switch, but the download drops (partly) under 1 MB/s. I saw that there is a new OwnCloud Version, so I started the update to latest stable (10.8.0.4). After that it started to happen, that instead of moving files from folder to folder, it starts to delete and reupload them. Renaming files still works as "move". I'm using the Client Version 2.8.2 (build 4246) btw.

If I move the files on the webDAV, the Client works fine and moves my files on my Desktop as well.

I never had this problem before in the 3-4 years I use Owncloud. Is there any solution to solve this?

@michaelstingl
Copy link
Contributor

@Darkexy the problem described in this issue was fixed in the 2.8.2 release. Please update.

If you still see problems, please open a new issues, to help the team to better understand your problem.

@Darkexy
Copy link

Darkexy commented Aug 18, 2021

@Darkexy the problem described in this issue was fixed in the 2.8.2 release. Please update.

If you still see problems, please open a new issues, to help the team to better understand your problem.

@michaelstingl Hi, like I wrote, I'm using Client version 2.8.2 (build 4246). I even reinstalled it yesterday since I thought this propably can fix it, but unfortuantly it didn't.

@onurba
Copy link

onurba commented Feb 14, 2023

I could move a folder on iPhone files app.

There is a curl command here if needed:
https://doc.owncloud.com/webui/next/classic_ui/files/access_webdav.html

curl -u user:pass -X MOVE --header 'Destination: https://example.com/owncloud/remote.php/dav/files/USERNAME/target.jpg' https://example.com/owncloud/remote.php/dav/files/USERNAME/source.jpg

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

Successfully merging a pull request may close this issue.

8 participants