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

Vfs with suffix files crashes in discovery when server has virtual files uploaded #6953

Closed
ckamm opened this issue Jan 8, 2019 · 13 comments
Closed
Assignees
Labels
feature:vfs native virtual files and placeholder implementation ReadyToTest QA, please validate the fix/enhancement type:bug
Milestone

Comments

@ckamm
Copy link
Contributor

ckamm commented Jan 8, 2019

To reproduce upload

test
test.owncloud
test.owncloud.owncloud

to the server. The discovery will get confused and crash in ASSERT(_dirItem && _dirItem->_instruction == CSYNC_INSTRUCTION_RENAME);.

@HanaGemela
Copy link
Contributor

macOS 10.14.5 and Windows 10 when VFS off:
File type is virtual file - Is that OK?
image

macOS 10.14.5 when VFS on:
only test.owncloud in the client

Windows 10 when VFS on:
only test and test.owncloud in the client

What exactly is the expected result here?

@ckamm
Copy link
Contributor Author

ckamm commented Jul 23, 2019

macOS 10.14.5 and Windows 10 when VFS off

This looks right, all three files are synced as-is.

macOS 10.14.5 when VFS on

Looks good too, all .owncloud files on the server are ignored, so only "test" gets propagated as "test.owncloud".

Windows 10 when VFS on

That's odd. I'd have imagined all three files to be around - with the cfapi plugin the client doesn't even know about the .owncloud suffix. Will try to reproduce.

@HanaGemela
Copy link
Contributor

Thanks, let me know if you can reproduce

@ckamm
Copy link
Contributor Author

ckamm commented Jul 24, 2019

@HanaGemela I can't reproduce. Steps:

  • Create "test", "test.owncloud", "test.owncloud.owncloud" on the server
  • sync on a 2.6 branch client with cfapi vfs enabled
    -> see test, test.owncloud, test.owncloud.owncloud in the filesystem

I've also tested that the "Free up space" and "Always available on this device" actions work on them.

@HanaGemela
Copy link
Contributor

Tried again and cannot reproduce either.
But I double checked

Looks good too, all .owncloud files on the server are ignored, so only "test" gets propagated as "test.owncloud".

And the content of the file is empty so I can't verify. The same issue as #7338

@ckamm
Copy link
Contributor Author

ckamm commented Jul 25, 2019

@HanaGemela I don't quite understand your message. What exactly can't you verify? How does this issue relate to #7338. If you still see an issue (in particular with today's build) can you give me updated steps (or create a new issue if unrelated)?

@HanaGemela
Copy link
Contributor

@ckamm You said that test.owncloud is ignored on the server and test is synced as test.owncloud. I just wanted to verify if it really works this way by looking at the content of the file. But the file is empty and I think it might be cased by #7338

@ckamm
Copy link
Contributor Author

ckamm commented Jul 29, 2019

I've tested the following:

  • upload test, test.owncloud, test.owncloud.owncloud to the server. They all have different contents.
  • create sync folder with suffix vfs
  • test.owncloud is created. downloading it downloads "test" file contents

But there are still some hickups around .owncloud files existing on the server. I'll create a ticket for 2.6.1.

@HanaGemela Can this be closed?

@ckamm ckamm added the feature:vfs native virtual files and placeholder implementation label Jul 29, 2019
@HanaGemela
Copy link
Contributor

@ckamm you said that .owncloud files are ignored on the server. Does that mean that they should not be synced when VFS is off? They currently are synced

@HanaGemela
Copy link
Contributor

I've observed strange behaviour that I cannot recreate. The only unusual thing was that the client was in different time zone than the server. Log were not saved. I've uploaded the files on the server and the Linux client kept adding test.owncloud virtual file every two seconds over and over again.

image

In the same test on the macOS client with VFS off all 3 files have been downloaded. Once I hydrated test.owncloud on the Linux client, test.owncloud disappeared from macOS client.

@HanaGemela
Copy link
Contributor

Also the notification is wrong. The notification says that all 3 files have been added and in the logs I can see things like
08-07 01:49:38:278 [ info sync.discovery ]: Processing "Once more/test.owncloud.owncloud" | valid: false/false/true | mtime: 0/0/1563960721 | size: 0/0/16 | etag: ""//"40def6a0b835c3927848a4519818a5fa" | checksum: ""//"SHA1:5bc110031ebf379964dac0801b8f9cd757e9e15c" | perm: //WDNVR | fileid: ""//"00002670oc9hhs3phb8b" | inode: 0/0/ | type: 3/3/0

@ckamm
Copy link
Contributor Author

ckamm commented Aug 7, 2019

@HanaGemela If suffix vfs is off, there's no special handling for suffixed files on the server or on the client. So what you observe is correct.

Having suffixed files on the server or suffixed and unsuffixed files with the same name locally has a bunch of edge cases that will be addressed for 2.6.1 with #7367 - the current behavior is inconsistent.

@HanaGemela
Copy link
Contributor

@ckamm OK, I've moved the wrong notification into #7261

The original issue reported here works as expected, client 2.6.0beta1 (build 1269), Ubuntu 19.04

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature:vfs native virtual files and placeholder implementation ReadyToTest QA, please validate the fix/enhancement type:bug
Projects
None yet
Development

No branches or pull requests

2 participants