Doc-cirrus MongoDB Plugin Install Challenges

I’ve successfully compiled the Doc-Cirrus Orthanc-MongoDB plugin. When attempting to install into Orthanc 1.2.0 I get a “LoadLibrary” error. Orthanc 1.2.0 is running on Windows Server platform. Has anyone had luck installing the Orthanc-MongoDB plugin? If so would you be willing to share any tips you learned in installing, and possibly the contents of the config parameters you are using?

Any help would be appreciated,

Brian Napora

Hi Brian,

that’s not much to go one and we haven’t tried this on Windows, so I can’t give you qualified info, only questions:

  • Is the DLL available and installed so that orthanc can reach it?
  • Is the Orthanc.json config correct? Especially the mongoDB URL.
  • Is the mongoDB port reachable (windows firewall)?

I have simply put the OSX “dylib” right next to the Orthanc executable and Osimis dylibs.
My configs for OSX follow:

“Plugins” : [








“MongoDB” : {

“EnableIndex” : true,

“EnableStorage” : true,

“ConnectionUri” : “mongodb://localhost:27017/orthanc_db”,

“ChunkSize” : 1048576




Did you make sure the MongoDB DLL and Orthanc executables have been built for the same architecture (32/64 bits) ? If not, that would generate a “LoadLibrary failure”

Thanks for quick response. I’ve confirmed that the “Orthanc.exe” build and the “OrthancMongoDB…dll’s” are both compiled in x64. I’ve also installed the dll’s to the same directory as “Orthanc.exe”. Below are the Plugin connection details included in “orthancroot.json” (my config file.):

“Plugins” : [
// MongoDB plugin configuration section:
“MongoDB” : {
“EnableIndex” : true, // false to use default SQLite
“EnableStorage” : true, // false to use default SQLite
“ConnectionUri” : “mongodb://localhost:27017/orthanc”,
“ChunkSize” : 261120
I tested the ConnectionUri using Mongo Studio and connected okay, so don’t believe its a MongoDB connection issue.

Below is the trace logging output:

W1109 11:20:25.070033 main.cpp:1238] Orthanc version: 1.2.0

W1109 11:20:25.071536 OrthancInitialization.cpp:125] Reading the configuration from: “./orthancroot.json”

W1109 11:20:25.073038 FromDcmtkBridge.cpp:189] Loading the embedded dictionaries

I1109 11:20:25.094169 FromDcmtkBridge.cpp:201] Loading the embedded dictionary of private tags

W1109 11:20:25.115254 OrthancInitialization.cpp:488] Registering JPEG Lossless codecs

W1109 11:20:25.115254 OrthancInitialization.cpp:493] Registering JPEG codecs

W1109 11:20:25.124247 main.cpp:632] Loading plugin(s) from: ../ModalityWorklists.dll

W1109 11:20:25.193507 PluginsManager.cpp:268] Registering plugin ‘worklists’ (version 1.2.0)

W1109 11:20:25.193507 PluginsManager.cpp:167] Sample worklist plugin is initializing

T1109 11:20:25.194492 OrthancPlugins.cpp:2849] Calling service 7 from plugin ../ModalityWorklists.dll

T1109 11:20:25.194492 OrthancPlugins.cpp:2849] Calling service 13 from plugin ../ModalityWorklists.dll

W1109 11:20:25.195479 PluginsManager.cpp:167] Worklists server is disabled by the configuration file

W1109 11:20:25.196512 main.cpp:632] Loading plugin(s) from: ../OrthancMongoDBIndex.dll

E1109 11:20:25.198486 SharedLibrary.cpp:64] LoadLibrary(../OrthancMongoDBIndex.dll) failed: Error 126

W1109 11:20:25.198486 PluginsManager.cpp:218] Unregistering plugin ‘worklists’ (version 1.2.0)

W1109 11:20:25.198486 PluginsManager.cpp:167] Sample worklist plugin is finalizing

E1109 11:20:25.198486 main.cpp:1264] Uncaught exception, stopping now: [Error while using a shared library (plugin)] (code 25)

W1109 11:20:25.199490 main.cpp:1297] Orthanc has stopped

When testing with other plugins (eg. ModalityWorklists.dll) they were able to load just fine. If this prompts any other ideas, I’d love to hear it. I’m also including the two OrththanMongoDB dll’s if anyone is willing to test against their Orthanc 1.2.0 on Windows installation (rename extension from ‘txt’ back to ‘dll’.


OrthancMongoDBIndex.txt (239 KB)

OrthancMongoDBStorage.txt (113 KB)

I think your DLL references other DLLs that are not on your system. If you have a chance to build the orthanc mongo plugin statically that should solve your issue (or, you’ll need to add all referenced DLL next to the plugin DLL)

Inline image 1

Good idea on putting the dependencies in same folder. I did that but still got same error message.

I have not been able to get the MongoDB to build statically.



As a consequence, I highly recommend you to fill an issue directly on Doc Cirrus’ GitHub repository:


Thanks Sebastien!

Will do,