[GNC] Could Not Obtain Lock

Michael or Penny Novack stepbystepfarm at comcast.net
Fri Aug 26 11:12:31 EDT 2022


On 8/26/2022 9:14 AM, rsbrux via gnucash-user wrote:
> This is an old topic, but I finally figured out what's wrong.
> On the Ubuntu desktop system where I run GnuCash (and little else), I set up a cron job to update prices at first logon each day, as described here:
> https://wiki.gnucash.org/wiki/Online_Quotes#Updating_enabled_Quotes_from_outside_GnuCash
> Unfortunately, starting GnuCash is often the first thing I want to do when I start up the system and I obviously haven't been waiting long enough for the cron job to finish.
> Is there a smarter way to make sure prices are collected online without having to wait and check that GC has finished the price update before I try to use it interactively?

Not EXACTLY an old topic. Most of what we have seen before is people 
asking about a false "cannot obtain lock" message << in other words, 
when there is NOT another use of the gnucash data going on >> You are 
asking about when it it TRUE.

In other words, the lock file mechanism is doing exactly what it is 
supposed to to to prevent concurrent access. When YOU are getting the 
message it means "not now, try again later".

Please explain exactly what you want to happen in all timing 
situations.  Think about all the possibilities (for example, you get 
gnucash open BEFORE this "update prices" has started to run)


Michael D Novack



More information about the gnucash-user mailing list