-
-
Notifications
You must be signed in to change notification settings - Fork 859
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
Gracefully fail when process cannot get exclusive database lock #7
Comments
Can you provide the log but without Can you also confirm that when you are running your command, you do not have any other onedrive process running via init.d or systemd |
I ran my command after a system fresh start, no other command was ran before, no browser were open on my desktop either if this matters. |
On fresh restart do you have 'onedrive' running as a system service?
Any open browsers has zero impact to the 'onedrive' client operating - they are two different application with zero interaction. When you experience 'database is locked' when running the client manually, please provide the following output:
|
Interesting link re sqlite & 'database is locked' http://beets.io/blog/sqlite-nightmare.html
In my system where I test everything I use sqlite 3.7.15.2 from Fedora 19, rebuilt using mock for my target system. When it is built - usleep support is detected:
Can you provide what OS version your running & what sqlite versions you are running |
@ms047 |
Hey, Here's my
and my
My OS is Ubuntu 16.04 The error happened again by the way, can't tell if it is anyhow different from the last one:
|
OK .. So you are running the 'onedrive' command manually whilst the service file for 'onedrive' is active and running ... This is why you are seeing |
Do you mean that OneDrive is monitoring the local directory automatically, without any manual intervention required at startup? When I modify files in my local directory, they are not being uploaded though. I guess I could manually kill this process and run Again, I literally turn on my computer, do not do anything else, and get this output for
Also, you could maybe make a specific error message raise and warn the user that the service file for 'onedrive' is active and running? |
Yes - you either have a systemd service configured or an init.d service configured to automatically start onedrive. You must have configured this at some point. Changing how the application handles the database lock to close out the error is how I was going to resolve this. |
I re-installed onedrive several times and have not configured it on purpose if I actually did. Would you know how to check if a systemd service configured or an init.d service configured, and how to reconfigure them? Thank you! |
I would refer to this: https://github.com/skilion/onedrive/wiki/Managing-the-onedrive-service
|
The 'database is locked' issue is resolved by 2576b69 When the application encounters this issue, it will now print the following message:
|
Great,
I’d also advise to print instructions to solve the problem, like “use
command xxx to kill the lrocess already open - it may be that your soft
opens at startup, to prevent this behavior from happening do yyy”
…On Fri 1 Jun 2018 at 21:21, abraunegg ***@***.***> wrote:
The 'database is locked' issue is resolved by 2576b69
<2576b69>
When the application encounters this issue, it will now print the
following message:
The database is currently locked by another process - cannot sync
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#7 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AYwEUVTAubsSoDUMPbocEZ1RkYNJByHNks5t4aI2gaJpZM4UOaOE>
.
|
I think this is better serviced via a wiki page so when people are searching for the error they can find out what to do, rather than the program spit out some details which they may not quite understand / get. If the patch provided resolves your issue, please can you close this case. |
@ms047 |
Hi, Sorry I did not find the time to test that earlier - it seemed to work, i.e. some uploads and downloads were performed as expected. Nevertheless, I am quite certain not to have set the automatic launch of onedrive service at startup anywhere, so this may happen to other users. It keeps happening to me even after having reinstalled onedrive with your patch. In this case, could you make onedrive automatically stop already opened services before starting? " systemctl --user stop onedrive" or "systemctl --user disable onedrive" could be automatically executed each time at the beginning, or something similar. Also, this error keeps popping up after several up/downloads - I guess I should open a new issue for it:
|
Your OS must be automatically configuring installed unit files to start on system boot. The Makefile simply copies the files over but does not activate or start them. It sounds like you need to raise a case with the folk that support your OS.
This to me sound like you have some sort of gateway content filtering going on that is parsing the content or that there is something going on with the Microsoft Graph service. I would first check to see if you have any gateway content filtering going on and if not raise a case against the OneDrive API |
Closing issue. Original issue of 'database is locked' is resolved, other items are environmental and outside of realm to resolve. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
A "database is locked" issue keeps happening to me, which suggests that there is an external soft trying to access my database. Though no obvious browser has OneDrive online open. Even if it did, this behavior would deserve a fix as well. Could be an app on a smartphone syncing in the background, maybe.
Here is my log for the command
onedrive -m --debug-https --verbose
, from the point when I add a new directory to the ~/onedrive directory (see this text file, the log is too long).The text was updated successfully, but these errors were encountered: