Failed to get transaction or CS lock for ...

Started by sinus, October 22, 2015, 11:26:21 AM

Previous topic - Next topic

sinus

Hi Mario
I know, that you want have usually the log-file.
But before I do this, maybe you have a clue, where I can first do some "investigations" myself.

When I update images (for example with the pencil), and IMatch displays in the Info "Reading Metadata" then I have often some of theses messsages, like the title here says (Failed to get ...) and it takes a long time (sometimes 2-4 minutes for 1 nef).

And this happens also, when I do use no panels (0 panel) and the default windows file (no variables).

Maybe you can give me a clue, otherwise I will send you a log-file, no problem.
(maybe I will first delete some cats, to see, if these are the problem).

10.22 11:09:17+    0 [0C24] 50  M>                    > 19 CIMCatalog::UpdateFile  'catalog\imcatalog.cpp(1459)'
10.22 11:09:17+    0 [0C24] 50  M>                    < 19 CIMCatalog::UpdateFile
10.22 11:09:17+    0 [0C24] 50  M>                    > 19 CIMCollectionManager::OnFileUpdate  'IMCollection.cpp(3220)'
10.22 11:09:18+ 1123 [12B8] 02  I>                    CIMCollection::InnerCalculate: Failed to get transaction or CS lock for 'Reject'
10.22 11:09:18+    0 [12B8] 10  M>                    < 19 [1170ms] CIMCollection::InnerCalculate
10.22 11:09:18+    0 [0C24] 50  M>                   < 18 [1123ms] CIMCollectionManager::OnFileUpdate



10.22 11:20:20+    0 [12B8] 10  I>                [73] 'This Week'
10.22 11:20:21+  827 [12B8] 02  I>               CIMCollection::InnerCalculate: Failed to get transaction or CS lock for 'This Week'
10.22 11:20:21+    0 [12B8] 10  M>               < 14 [827ms] CIMCollection::InnerCalculate
10.22 11:20:21+    0 [12B8] 02  I>              ##SLOWCAT 'c DIESE WOCHE'
10.22 11:20:25+ 4805 [09D4] 03  I>              # Process Memory Info: WSC: 1022MB, WSP: 1036MB, PF: 1628781
10.22 11:20:25+    0 [09D4] 50  I>              TryBeginTrans: 515 of 500, 17 loops
10.22 11:20:27+ 1497 [12B8] 10  M>               > 14 CIMCollection::InnerCalculate  'IMCollection.cpp(512)'
10.22 11:20:27+    0 [12B8] 10  I>                [71] 'Today'
10.22 11:20:28+  827 [12B8] 02  I>               CIMCollection::InnerCalculate: Failed to get transaction or CS lock for 'Today'
10.22 11:20:28+    0 [12B8] 10  M>               < 14 [827ms] CIMCollection::InnerCalculate
10.22 11:20:28+    0 [12B8] 02  I>              ##SLOWCAT 'b HEUTE'
10.22 11:20:34+ 6302 [12B8] 10  M>               > 14 CIMCollection::InnerCalculate  'IMCollection.cpp(512)'
10.22 11:20:34+    0 [12B8] 10  I>                [75] 'This Month'
10.22 11:20:35+  827 [12B8] 02  I>               CIMCollection::InnerCalculate: Failed to get transaction or CS lock for 'This Month'
10.22 11:20:35+    0 [12B8] 10  M>               < 14 [827ms] CIMCollection::InnerCalculate
10.22 11:20:35+    0 [12B8] 02  I>              ##SLOWCAT 'd DIESEN MONAT'
10.22 11:20:36+ 1061 [09D4] 50  I>              TryBeginTrans: 515 of 500, 17 loops
10.22 11:20:41+ 5242 [12B8] 10  M>               > 14 CIMCollection::InnerCalculate  'IMCollection.cpp(512)'
10.22 11:20:41+    0 [12B8] 10  I>                [76] 'Last Month'
10.22 11:20:42+  826 [12B8] 02  I>               CIMCollection::InnerCalculate: Failed to get transaction or CS lock for 'Last Month'
10.22 11:20:42+    0 [12B8] 10  M>               < 14 [826ms] CIMCollection::InnerCalculate
10.22 11:20:42+    0 [12B8] 02  I>              ##SLOWCAT 'e LETZTEN MONAT'
10.22 11:20:46+ 4462 [09D4] 50  I>              TryBeginTrans: 530 of 500, 18 loops
10.22 11:20:48+ 1841 [12B8] 10  M>               > 14 CIMCollection::InnerCalculate  'IMCollection.cpp(512)'
10.22 11:20:48+    0 [12B8] 10  I>                [74] 'Last Week'
10.22 11:20:49+  842 [12B8] 02  I>               CIMCollection::InnerCalculate: Failed to get transaction or CS lock for 'Last Week'
10.22 11:20:49+    0 [12B8] 10  M>               < 14 [842ms] CIMCollection::InnerCalculate
10.22 11:20:49+    0 [12B8] 02  I>              ##SLOWCAT 'a LETZTE WOCHE'
10.22 11:20:51+ 2216 [12B8] 10  M>               > 14 CIMCollection::InnerCalculate  'IMCollection.cpp(512)'
10.22 11:20:51+    0 [12B8] 10  I>                [10006] 'None'
10.22 11:20:52+  842 [12B8] 02  I>               CIMCollection::InnerCalculate: Failed to get transaction or CS lock for 'None'
10.22 11:20:52+    0 [12B8] 10  M>               < 14 [842ms] CIMCollection::InnerCalculate
10.22 11:20:52+    0 [12B8] 02  I>              ##SLOWCAT 'a kein rating'
10.22 11:20:57+ 4774 [09D4] 03  I>              # Process Memory Info: WSC: 1022MB, WSP: 1036MB, PF: 1628781
10.22 11:20:57+    0 [09D4] 50  I>              TryBeginTrans: 515 of 500, 17 loops
Best wishes from Switzerland! :-)
Markus

Mario

These messages are normal, at least when IMatch is not running with good performance.

The part of IMatch which re-calculates collections in the background was unable to get access to the database within a certain amount of time. This does no harm, because the collection remains in the "needs update" state and IMatch continues. The same can happen when IMatch tries to calculate categories in the background, with the same result (the category stays in the "needs update" state and is re-calculated as soon as possible).

Usually such issues are caused by IMatch being too busy, or too many things going on at the same time. The user interface usually gets the higher priority, so background task will have to wait when the user interface needs to load or write data.

Your log file also complains about many "slow" categories, which means that these categories take an unusual amount of time to update. And this obviously interferes with the background calculation of collections, and causes them to wait.

I don't know how large your database is, where it is stored or how you have configured categories like "0 HEUTE" oder "DIESEN MONAT". If these are data-driven categories an the database is large (100,000+ files or so) and the disk cannot deliver the data fast enough and IMatch needs to calculate multiple categories and/or multiple collections in order to update the file window, the whole system will be quite busy for a time.

I would need more info about your database, these categories, what information you show in your file window panels, and the complete log file to tell you more.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

sinus

Thanks, Mario,
your answers helps me really, to understand, what IMatch is doing and what I can do, to avoid, that IMatch has to many things to do.

I will first look again at my categories, maybe delete some of them and if the "problem" still does appears, I will give you more informations.

But I can also avoid to give you more work, when I first look at it myself. Your answer is really good enough for me.

Best wishes from Switzerland! :-)
Markus

Mario

If you have a lot of data-driven categories and they slow down IMatch, maybe you can change then to 'manual recalc' for a test and see how this speeds up the system. Or disable background dd-category calculation entirely under Edit > Preferences > Background Processing. Just to see how this affects your system.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

sinus

Best wishes from Switzerland! :-)
Markus