[GNC] Locked out of gnucash

Stan Brown the_stan_brown at fastmail.fm
Sun Nov 17 02:21:37 EST 2019


In the two years I've been reading this list, I think the single most
common question has been about this "could not obtain the lock" message.
Seems like someone asks about it at least once a week.

The text "that database may be in use by another user," while literally
true, isn't helpful because it points to a less common case and gives no
guidance for the more common case. It's like hearing hoofbeats and
hypothesizing "zebra" instead of "horse".

I suggest that improving the message would be a huge boon to less
experienced GC users, and very little effort for the developers.

Why not replace the present text

        That database may be in use by another user, in which case you
        should not open the database. What would you like to do?

with this:

        If your previous session crashed, select Open Anyway. If this is
        a shared database, wait for other users to finish using it or
        select Open Read-Only. For more information, see (link to sec
        2.5.3 of Tutorial).

"What would you like to do?" can be omitted, in my opinion. Seeing
buttons, users will know that they need to pick one. What they _do_ need
is text that is relevant to their situation.

(I question the tutorial's advice to delete the lock files manually.
David Cousens reports:
>  My experience on Linux is that when you select Open
> Anyway, the previous .LNK and .LCK files will be deleted and new ones
> created which should then be deleted when GNucash is closed properly.
The same happens for me in Windows. Is there any OS where this desirable
behavior doesn't happen? If there is, the tutorial's advice should
mention those specific systems, or at least it should say that in
Windows and Linux GC will do this automatically when you reopen a data
file after the "could not obtain the lock" message.)

-- 
Regards,
Stan Brown
Tompkins County, New York, USA
https://BrownMath.com
http://OakRoadSystems.com


On 2019-11-16 20:27, David Cousens wrote:
> Kay
> 
> If GnuCash is not closed properly,e.g. a crash the .LNK and .LCK files
> created in your data directory prevent you from opening GnuCash. Section
> 2.5.3 of the Tutorial guide covers them.
> 
> .LCK file extensions.  My experience on Linux is that when you select Open
> Anyway, the previous .LNK and .LCK files will be deleted and new ones
> created which should then be deleted when GNucash is closed properly.


More information about the gnucash-user mailing list