-
Notifications
You must be signed in to change notification settings - Fork 665
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] Junction links (symlinks) are being synced #5019
Comments
Quick tests: Linux symbolic links skipped by 2.2.2, but Windows directory symbolic links and junctions are uploaded. |
@ckamm yes, I agree on that. The question is if there is a way to detect the junction without mixing up with the network files. |
@dragotin The problem is that the code assumes the reparse point tag is a combination of flags, when it's just a value. I can fix that, but the patch will need testing for https://github.com/owncloud/enterprise/issues/1225 and #4056 . |
Thanks for looking into this. Personally I would have preferred symlinks and junctions to actually work but I understand that it's complicated - at least now it can hopefully be predictable again :) |
Fixes an accidental behavior change introduced in 055c2ef Affects owncloud#4056 and owncloud/enterprise#1225.
Hi: Junction points or symbolic links are not synced. Steps Executed Result Junction point or symlink are not synced and a two new entries at activity > not synced tab could be found : Symbolic links are not supported in syncing. Client OS: W7/8.1/10 Server OS: Ubuntu 14.04 |
I guess I started using ownCloud 2.2.2 just before this commit and was really appreciating its feature and its similarities to how most clients handle linked folders. I've now upgraded to ownCloud 2.2.3.6307 and was wondering if this feature to include linked folders could perhaps be optional instead of reverted/removed? |
I'd also love to have symlink support. It seems this was requested about 2 years ago already (#1440). Sucks that it's been put off for so long. I recommend closing this ticket and continuing the discussion on the other one. |
I agree! |
Thank you for reopening this issue (also sorry for not creating a new one). If I understand correct I'm hoping symbolic links |
guys, there are a couple of issues already. I thought I summarized a couple of questions that we have to clearify before we get going with symlinks, but can not find it. Let's start here.
Probably there is more to think about. @gladiac do you have input? Thanks! |
Here is a document that distinguishes between the differences fairly well.: A good way to start would be to answer the question: What should the default behaviour be? We need to take some things into consideration to answer this:
There are many different situations that come into play here, and having the default behaviour account for all of them would be nice, but perhaps not practical if the feature is to be released sooner than later. The goal for now could be to distinguish between all three different types of links, but treat them the same - that is, only synchronize the link and not the data. In this case, the server would not follow/open links, only synchronize them to clients. Having even this initial functionality available to users would be beneficial, and can be expanded on afterwards given that the functionality to distinguish between types of links would be available already. |
Seems like Windows 10 has improved symlink support now? https://blogs.windows.com/buildingapps/2016/12/02/symlinks-windows-10/#Z2PXD4EP0gBrsYmu.97 |
The way to handle junctions or symlinks seems clear to me: even under Windows these kinds of soft links are now handled transparently for windows applications. The ownCloud client is a windows application, so: handle it transparently! If you are afraid, that users are confused by a changed behaviour, then skip it by default (as it is done in Version 2.2.4), print a warning, but provide a checkbox in the settings to activate the syncing of junctions and symbolic links. If you think, this could be a security issue, then make a statement in the settings dialog, but let the user decide, if he wants to take the "risk". Another related issue is, that linked files should be linked again on the server. This is exactly, what dropbox does: if you have 2 symbolic links to a big file (e.g. video clip), the upload of the first link takes a while, but the upload of the second link is done very quickly - obviously client and server exchange checksums (or similar information) to detect duplicates. BTW: this logic of the dropbox sync protocol has nothing to do with client symbolic links, but would also works for "real" copies of big files at client side - the dropbox server simply avoids to store redundant data this way. |
@9k22: Full support from my side!!! |
@SamuAlfageme No. Detecting symlinks and junctions is something we already do during discovery. The main obstacle to synchronizing these is that one would need to think carefully about the desired behavior and implement that. And that's not been a priority so far. |
Exactly. BTW: the "need to think carefully about the desired behavior" is IMHO not that big thing: the strategy of e.g. dropbox is perfect: simple to understand, simple to communicate, totally Independent from the way it is organized on the client side, and behaves exactly as I need it. And this is really not "rocket science". I wonder, why not just copy and implement the dropbox behaviour ? Until this is not done, I cannot move from dropbox to owncloud. |
@ckamm didn't you do something related to this topic recently? |
@guruz What I did was make sure recursive deletions didn't delete data behind junctions in #6349. I agree with @9k22 that treating a symlink as transparent and just syncing the data behind it makes sense. Potential issues:
|
I agree with the identified issues. Proposed mitigation: |
Make it optional. Also, https://xkcd.com/1172/ :)
Rename: Rename the symlink without touching its target
A broken symlink should be treated as nothing, as it barely provides any more data than a file that does not exist. A symlink entering the broken state is the same as a file being deleted (which is what is happening to the targeted file, anyway) |
I guess this is the same as #1440 |
Closing as duplicate of #1440 |
Since the 2.2.2 update the client has started syncing directories linked by junction points (symlinks on Windows).
I am syncing My Documents folder, on Windows this contains a "My Games" folder which often gets very large. I have created a junction point to another drive to save space on c:.
Earlier versions of the OC client did not sync these, I believe junctions stopped syncing some 1.x release. Now they are suddenly back to working, and I did not find any thing in the release log to explain why they would now work when before they did not. If they now are expected to work I have to rethink my folder setup.
Steps to reproduce
Expected behaviour
I would expect links (junction points) to not be synced
Actual behaviour
The files in the linked folder are synced
Server configuration
Owncloud 9.0
I don't own the server, it's a shared hosting solution.
I assume this is a client issue.
Client configuration
Client version: 2.2.2
Operating system: Windows 10 Pro, x64
OS language: English UK
Installation path of client: d:\bin\ownCloud\
Logs
Will provide if needed.
The text was updated successfully, but these errors were encountered: