[GNC] could not obtain lock message when opening GnuCash
David Long
davidvernonlong at gmail.com
Thu Apr 17 11:06:36 EDT 2025
Hi,
thanks for this reply and others. It could have been that GnuCash did not
close down properly as mentioned after a power failure, but the error
message stuck around. It could also be that I opened GnuCash before Dropbox
had synchronised, although I was aware that could be an issue so generally
waited a while. However , if Dropbox had not opened on one of the machines,
and I did not notice, that could have happened, so will be more aware from
now on. As suggested, I have now updated to the latest version of GnuCash.
Where I am now is that one of the machines (thats the desktop at home),
would not open GnuCash at all, even with the latest version of GnuCash, and
this is the machine I had been using most recently. Even if I selected an
old backup file, it briefly opened and then closed. I restarted my Desktop
also, but still I could not open GnuCash.
Then, I opened GnuCash on my laptop I use when travelling, and it opened
the file even though it was running an old version of GnuCash. I saved the
file under a new name. My Desktop was able to open the newly named file
with no error message. I updated GnuCash on my laptop after updating to the
latest version. It was also able to open the file with no error message.
So I think my lessons from this are:
Save, if I take a break from GnuCash and not leave GnuCash idle for a long
time when there could be some kind of a disruption to cause an improper
close down.
Make sure Dropbox has fully synchronised on both machines before switching
machines and check the time of the saved file is the same on all machines.
Have the same and latest version on both machines.
David
On Wed, Apr 16, 2025 at 7:01 PM R Losey <rlosey at gmail.com> wrote:
>
>
> On Tue, Apr 15, 2025 at 2:18 PM David Long <davidvernonlong at gmail.com>
> wrote:
>
>> Hi,
>>
>> I am using GNucash on 3 machines, who share the file on Dropbox. I make
>> sure only one version is open at any one time. When opening GnuCash, I get
>> the message * GnuCash could not obtain the lock to( folder\filename). That
>> database may be in use by another user, in which case you should not open
>> it." I always ignore the message and open it anyway, as the backups give
>> me the same message. I am worried that this might give me problems at some
>> stage. What should I do?
>> thanks
>> David
>>
>
> Hello!
> I'm also running GnuCash on three machines - three operating systems
> (MacOS, Windows 10, and Linux [Ubuntu]).
>
> You should not be getting that message on a regular basis... when GnuCash
> starts, it creates a "lock" file that is deleted when GnuCash is shut
> down. If you start GnuCash and the "lock" file exists, it implies that
> GnuCash is running somewhere else, and you get the warning.
>
> Therefore, if something happened such that GnuCash didn't shut down
> cleanly, the "lock" file may stick around.
>
> Or perhaps one of the machines doesn't have write access to the GnuCash
> directory?
>
> Perhaps you're running an older version of GnuCash that isn't shutting
> down cleaning. (What version are you running?) One of the earlier 5.x
> versions had an issue in which GnuCash did not shut down all the way and
> left the lock file in place.
>
>
> --
> _________________________________
> Richard Losey
> rlosey at gmail.com
> Micah 6:8
>
More information about the gnucash-user
mailing list