High CPU?


I have an Orthanc 0.8.5 running for a few weeks now and recently it has started using very high CPU, even when no clients are connected (according to netstat). Here's what I see when I run with --verbose:


I0417 08:09:42.866288 70 ServerContext.cpp:338] New instance stored
I0417 08:09:43.441397 70 ServerIndex.cpp:178] Change related to resource e1049c19-fd432535-822f262b-fadf3110-7963b6c6 of type Instance: NewInstance
I0417 08:09:43.442437 70 ServerIndex.cpp:178] Change related to resource a55cff1e-a0c6e8a3-baf4b71a-5131cf44-6c855b21 of type Series: NewChildInstance
I0417 08:09:43.442515 70 ServerIndex.cpp:178] Change related to resource 567cbcf6-2d46f225-f9d7adc0-ff7ee266-2d9282c9 of type Study: NewChildInstance
I0417 08:09:43.442572 70 ServerIndex.cpp:178] Change related to resource 95f92b2f-0cb53054-2d16d90a-6c2af59e-20759430 of type Patient: NewChildInstance

How can I debug this further to find out what all of these updates are about? In particular does Orthanc have a job queue of some kind in its sqlite database?


-- Carlo


This log indicates that new instances are continuously being stored by your instance of Orthanc, which explains the high CPU load.

If no DICOM client is sending these files and if no REST client is connected, then either a Lua script or a plugin is ill-behaving (maybe an infinite loop?).

I would suggest you to turn off the DICOM and HTTP servers (by setting respectively the configuration options “DicomServerEnabled” and “HttpServerEnabled” to false), and to empty the “LuaScripts” and “Plugins” options. You should see no CPU activity. Then, progressively restore the options to find the culprit.

To answer the second part of your question, Orthanc does not have a queue encoded in the SQLite database. All the processing queues are kept in memory.