-
-
Notifications
You must be signed in to change notification settings - Fork 871
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
Bug: Activity occurs out of order #3044
Comments
@sweharris
NFS mounted directories can cause issues with inotify - typically inotify does not support them, so it is interesting that this is even working for you ... Please read https://github.com/abraunegg/onedrive/blob/master/docs/usage.md#how-to-change-where-my-data-from-microsoft-onedrive-is-stored I will try and reproduce this on RHEL 7, however on Fedora, when actually using verbose logging (your output above is not verbose logging):
Exact same test without
So at this stage nothing is being sent out-of-order ......... and the correct file is being uploaded to Microsoft OneDrive when it changed, and, nothing is uploaded on the next sync cycle. So for the moment I am marking this as unable to reproduce. If I am unable to reproduce on RHEL7 (I will use RHEL 7.9, with and without an NFS mounted $HOME path) - I will mark this as a local environment issue and will not be solving/bug fixing this. Additionally, RHEL7 reached its end of maintenance support 2 phase June 30th 2024. Unless you can confirm you have valid ELS that supports through to June 30 2028, I wont be able to support any further as this is a end of support platform. |
The NFS/inotify issue you're thinking of occurs if I make changes to the tree on a machine other than where the daemon is running; eg if the daemon runs on clientA and I make changes on clientB then clientA does not get an inotify message and so the daemon doesn't wake up. If a change is made on clientA then it all works properly. I wonder if my vim config is causing a difference in behaviour; in
|
@sweharris
This shows the sequence, using
|
So this time I edited existing file ~/OneDrive/tmp/test-card-numbers. The log showed
OK, I've got a Rocky 9 machine that I configured the same way. Note that if I just installed "vim-minimal" then I see different behaviour. If I install the full "vim" then I see this. Rocky 9, vim-minimal:
No error there. But once full "vim" has been installed ("sudo dnf install vim") then I see
So I can replicate on Rocky9 but it needs full vim.
|
@sweharris The 'application' is what is reading / writing / issuing the delete. The operating system via inotify is processing these events in the order that they are received. |
The file remains on the local filesystem, so it's not a vim bug. I just think vim-minimal may not be honouring the vimrc directives (you can see it created the backup file with a ~ in the same directory, but with vim-enhanced the vimrc directives told it to store it in a different place). So it may require vim-enhanced and the ~/.vimrc file to generate the right (bad) sequence of events. |
@sweharris In the PR, I have added the suggested fix (I was unable to reproduce at the time) Please can you test PR #3045 running client version I am still getting my RHEL 7.9 system workable. |
@sweharris
|
Hmm, that looks a lot better. On Rocky9 I now see
And on RedHat 7 via systemd it also looks good
That's with
So I think this is good! (FWIW, I don't think you need to build 7.9 machine anymore since I could replicate on 9, and demonstrated the fix works for both) |
My testing on RHEL 7.9
RHEL 7.9 'master'
RHEL 7.9 using PR
|
@sweharris |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Describe the bug
If I use
vim
to edit a file then as part of saving it looks like the old file is deleted and the new file is written. But the app performs action in the wrong order and so the result is the file is deleted from OneDrive. On next (timed sync) the file is re-sent.At this point the file is deleted from OneDrive. Some time later a new sync starts
Operating System Details
Client Installation Method
From Source
OneDrive Account Type
Personal
What is your OneDrive Application Version
onedrive v2.5.3-24-gea7ed66
What is your OneDrive Application Configuration
What is your 'curl' version
Where is your 'sync_dir' located
Local
What are all your system 'mount points'
What are all your local file system partition types
How do you use 'onedrive'
Local onedrive agent sync'ing to personal Onedrive; $HOME/OneDrive is a subdirectory $HOME, which is mounted from NFS
Agent is running from systemd as myself.
Steps to reproduce the behaviour
% rpm -qf /usr/bin/vi
vim-minimal-7.4.629-8.el7_9.x86_64
vi ~/OneDrive/a_test_file
Make changes.
:wq
to save and exitComplete Verbose Log Output
Dec 11 20:50:46 XXX onedrive[28067]: The operating system sent a deletion notification. Trying to delete the item as requested Dec 11 20:50:46 XXX onedrive[28067]: Uploading modified file: Android_Sync/Documents/Health/Exercise.txt ... done Dec 11 20:50:47 XXX onedrive[28067]: The operating system sent a deletion notification. Trying to delete the item as requested Dec 11 20:50:47 XXX onedrive[28067]: Deleting item from Microsoft OneDrive: Android_Sync/Documents/Health/Exercise.txt
At this point the file is deleted from OneDrive. Some time later a new sync starts
Screenshots
No response
Other Log Information or Details
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: