Osimis - PostGRE image cache?

Again, sorry for the repeat topic, but something has messed up my ability to post replies to that earlier topic.

I still wonder whether there is an image cache created somewhere by the Osimis viewer that becomes corrupted. If I could find and erase that cache, maybe I’d solve my problems.

Here’s why I wonder about the existence of an Osimis cache in the database:

  • Switching back to the standard Orthanc web viewer plugin works. Series that are problematic for Osimis work fine for the Orthanc web viewer.

  • Newer studies and series can be viewed just fine in the Osimis viewer. The problem seems to be restricted to older, formerly viewed studies.

  • Most importantly, downloading the problem studies (as a zip archive) and re-uploading fixes the problem.

  • This implies that the original DICOM are ok. (That’s also implied by the fact that the original web viewer plugin works.) It’s not the DICOM that are corrupted in the database.

  • During the round trip, I delete the original study from the database. I suspect that if there’s a temporary Osimis cache associated with the DICOM, it too is deleted so that when I use the Osimis viewer on the “new” re-uploaded series, the cache is re-created and works.

I could imagine the Osimis viewer generating images (jpeg? pnm?) and using the Orthanc facility to store them as attachments to the original DICOM. For whatever reason, I’m speculating this might be more efficient for viewing purposes. Those attachments are of course deleted when I delete the original study.

If this is what is happening, I should be able to go in and erase all the attachments to the original DICOM to force the Osimis viewer to re-create them.

That’s just what I don’t know - is this sort of viewer driven calculation of images at the base of my problems?

I suppose I can also go dig into the Osimis source code to answer my own question. :slight_smile:


Hi John,

Could you post the “WebViewer” section of your configuration file and tell us the version you’re using (this is displayed in the plugins page).
In some versions, there has been a cache that was storing information as Orthanc attachments.

Here’s the webviewer portion from the orthanc.json config file:

“WebViewer” : {
“CacheEnabled” : true,
“StudyDownloadEnabled” : true,
“CachePath” : “/media/storage/WebViewerCache”,
“CacheSize” : 100,
“Threads” : 4

I assumed that those settings only affected the original Orthanc Webviewer plugin. Did the older Osimis plugins also use this cache?

The plugin versions I have are:

  • dicom-web

    Implementation of DICOMweb (QIDO-RS, STOW-RS and WADO-RS) and WADO-URI.


  • osimis-web-viewer

    Provides a Web viewer of DICOM series within Orthanc.

  • postgresql-index

    Stores the Orthanc index into a PostgreSQL database.


  • postgresql-storage

    Stores the files received by Orthanc into a PostgreSQL database.

    By the way, I also tried renaming the above WebViewerCache directory temporarily (on the host) to see if I could trigger its re-creation, but my Osimis viewer didn’t appear to be affected. The Osimis viewer still worked for “good” cases and did not work for “bad” cases.


Yes, the “CacheEnabled” is used by the Osimis Webviewer and this cache is stored in the attachments:

“CachePath” was an Orthanc viewer setting that is not used anymore in the Osimis Webviewer:

You should disable this cache and your problems shall be solved. This cache will be removed from future release since it’s not stable as you’ve noticed.

Yes! I turned off CacheEnabled and my problem cases now load into the Osimis viewer. It hadn’t occurred to me that the Osimis viewer used some of the same settings as the original web viewer plugin.