newbee problems

I am modifying the /etc/orthanc/orthanc.json file so I can use the default.

The command is:
ilan@ilan-Desktop:~$ /usr/sbin/Orthanc --verbose
W1030 13:40:07.159492 main.cpp:1222] Orthanc version: 1.1.0
W1030 13:40:07.164091 OrthancInitialization.cpp:230] Using the default Orthanc configuration
W1030 13:40:07.223959 FromDcmtkBridge.cpp:140] Loading the external DICOM dictionary "/usr/share/libdcmtk8/dicom.dic"
W1030 13:40:07.280794 FromDcmtkBridge.cpp:140] Loading the external DICOM dictionary "/usr/share/libdcmtk8/private.dic"
W1030 13:40:07.322914 OrthancInitialization.cpp:502] Registering JPEG Lossless codecs
W1030 13:40:07.323003 OrthancInitialization.cpp:507] Registering JPEG codecs
W1030 13:40:07.364661 OrthancInitialization.cpp:993] SQLite index directory: "/home/ilan/OrthancStorage"
W1030 13:40:07.365353 OrthancInitialization.cpp:1063] Storage directory: "/home/ilan/OrthancStorage"
I1030 13:40:07.367417 DatabaseWrapper.cpp:307] Version of the Orthanc database: 6
I1030 13:40:07.368230 ServerIndex.cpp:1857] Starting the monitor for stable resources (stable age = 60)
I1030 13:40:07.368363 ServerIndex.cpp:365] Starting the database flushing thread (sleep = 10)
W1030 13:40:07.368427 ServerScheduler.cpp:134] The server scheduler has started
W1030 13:40:07.369204 LuaContext.cpp:103] Lua says: Lua toolbox installed
W1030 13:40:07.369356 HttpClient.cpp:658] No certificates are provided to validate peers, set "HttpsCACertificates" if you need to do HTTPS requests
I1030 13:40:07.369400 HttpClient.cpp:140] Setting the default timeout for HTTP client connections: 0 seconds
I1030 13:40:07.369464 HttpClient.cpp:124] Setting the default proxy for HTTP client connections:
W1030 13:40:07.369504 ServerContext.cpp:168] Disk compression is disabled
I1030 13:40:07.369542 ServerContext.cpp:447] Storing MD5 for attachments: yes
W1030 13:40:07.369582 ServerIndex.cpp:1372] No limit on the number of stored patients
W1030 13:40:07.369750 ServerIndex.cpp:1389] No limit on the size of the storage area
W1030 13:40:07.371889 main.cpp:820] DICOM server listening with AET ORTHANC on port: 4242
I1030 13:40:07.371914 DicomServer.cpp:64] DICOM server started
W1030 13:40:07.372616 MongooseServer.cpp:954] HTTP keep alive is disabled
W1030 13:40:07.372675 MongooseServer.cpp:980] HTTP compression is enabled
W1030 13:40:07.387920 main.cpp:757] HTTP server listening on port: 8042
W1030 13:40:07.388062 main.cpp:644] Orthanc has started
I1030 13:40:20.712939 MongooseServer.cpp:723] GET /app/explorer.html
I1030 13:40:20.920874 MongooseServer.cpp:723] GET /app/libs/jquery.mobile.min.css
I1030 13:40:21.525843 MongooseServer.cpp:723] GET /app/libs/jqtree.css
I1030 13:40:21.527198 MongooseServer.cpp:723] GET /app/libs/jquery.mobile.simpledialog.min.css
I1030 13:40:21.527334 MongooseServer.cpp:723] GET /app/libs/jquery-file-upload/css/jquery.fileupload-ui.css
I1030 13:40:21.527477 MongooseServer.cpp:723] GET /app/libs/jquery-file-upload/css/style.css
I1030 13:40:21.528245 MongooseServer.cpp:723] GET /app/libs/slimbox2/slimbox2.css
I1030 13:40:21.962049 MongooseServer.cpp:723] GET /app/libs/jquery.min.js
I1030 13:40:22.379572 MongooseServer.cpp:723] GET /app/libs/jquery.mobile.simpledialog2.js
I1030 13:40:22.380792 MongooseServer.cpp:723] GET /app/libs/date.js
I1030 13:40:22.381189 MongooseServer.cpp:723] GET /app/libs/jqm.page.params.js
I1030 13:40:22.381676 MongooseServer.cpp:723] GET /app/libs/slimbox2.js
I1030 13:40:22.382035 MongooseServer.cpp:723] GET /app/libs/jquery.mobile.min.js
I1030 13:40:22.383438 MongooseServer.cpp:723] GET /app/libs/tree.jquery.js
I1030 13:40:22.806902 MongooseServer.cpp:723] GET /app/libs/jquery.blockui.js
I1030 13:40:22.807058 MongooseServer.cpp:723] GET /app/file-upload.js
I1030 13:40:22.807388 MongooseServer.cpp:723] GET /app/explorer.css
I1030 13:40:22.807599 MongooseServer.cpp:723] GET /app/libs/jquery-file-upload/js/vendor/jquery.ui.widget.js
I1030 13:40:22.807881 MongooseServer.cpp:723] GET /app/libs/jquery-file-upload/js/jquery.iframe-transport.js
I1030 13:40:22.807969 MongooseServer.cpp:723] GET /app/libs/jquery-file-upload/js/jquery.fileupload.js
I1030 13:40:23.205109 MongooseServer.cpp:723] GET /plugins/explorer.js
I1030 13:40:23.205227 MongooseServer.cpp:723] GET /app/query-retrieve.js
I1030 13:40:23.205683 MongooseServer.cpp:723] GET /app/explorer.js
I1030 13:40:23.460866 MongooseServer.cpp:723] GET /app/libs/images/ajax-loader.gif
I1030 13:40:23.729114 MongooseServer.cpp:723] GET /system
I1030 13:40:23.869546 MongooseServer.cpp:723] GET /patients
I1030 13:40:24.008837 MongooseServer.cpp:723] GET /app/libs/images/icons-18-white.png
I1030 13:40:28.985421 MongooseServer.cpp:723] GET /system
I1030 13:40:29.077925 MongooseServer.cpp:723] GET /modalities

The only thing I just changed is DicomAssociationCloseDelay is now zero.
I tried commenting out the contents of
  "Plugins" : [
    "/usr/share/orthanc/plugins/"
  ],
but nothing changed there as well. Somehow it seems better to leave that as is.

The log is
W1030 10:42:43.420697 main.cpp:1222] Orthanc version: 1.1.0
W1030 10:42:43.424849 OrthancInitialization.cpp:183] Scanning folder "/etc/orthanc/" for configuration files
W1030 10:42:43.425057 OrthancInitialization.cpp:135] Reading the configuration from: "/etc/orthanc/serve-folders.json"
W1030 10:42:43.425356 OrthancInitialization.cpp:135] Reading the configuration from: "/etc/orthanc/worklists.json"
W1030 10:42:43.425495 OrthancInitialization.cpp:135] Reading the configuration from: "/etc/orthanc/orthanc.json"
W1030 10:42:43.482997 FromDcmtkBridge.cpp:140] Loading the external DICOM dictionary "/usr/share/libdcmtk8/dicom.dic"
W1030 10:42:43.535033 FromDcmtkBridge.cpp:140] Loading the external DICOM dictionary "/usr/share/libdcmtk8/private.dic"
W1030 10:42:43.574235 OrthancInitialization.cpp:502] Registering JPEG Lossless codecs
W1030 10:42:43.574329 OrthancInitialization.cpp:507] Registering JPEG codecs
W1030 10:42:43.611037 main.cpp:632] Loading plugin(s) from: /usr/share/orthanc/plugins/
W1030 10:42:43.612011 PluginsManager.cpp:268] Registering plugin 'serve-folders' (version 1.1.0)
W1030 10:42:43.613247 PluginsManager.cpp:268] Registering plugin 'worklists' (version 1.1.0)
W1030 10:42:43.613291 PluginsManager.cpp:167] Sample worklist plugin is initializing
W1030 10:42:43.613689 PluginsManager.cpp:167] Worklists server is disabled by the configuration file
W1030 10:42:43.613770 OrthancInitialization.cpp:993] SQLite index directory: "/var/lib/orthanc/db-v6"
W1030 10:42:43.614339 OrthancInitialization.cpp:1063] Storage directory: "/var/lib/orthanc/db-v6"
W1030 10:42:43.706993 ServerScheduler.cpp:134] The server scheduler has started
W1030 10:42:43.707772 LuaContext.cpp:103] Lua says: Lua toolbox installed
W1030 10:42:43.707900 HttpClient.cpp:658] No certificates are provided to validate peers, set "HttpsCACertificates" if you need to do HTTPS requests
W1030 10:42:43.707946 ServerContext.cpp:168] Disk compression is disabled
W1030 10:42:43.707985 ServerIndex.cpp:1372] No limit on the number of stored patients
W1030 10:42:43.708069 ServerIndex.cpp:1389] No limit on the size of the storage area
W1030 10:42:43.710023 main.cpp:820] DICOM server listening with AET ORTHANC on port: 4242
W1030 10:42:43.710173 MongooseServer.cpp:954] HTTP keep alive is disabled
W1030 10:42:43.710205 MongooseServer.cpp:980] HTTP compression is enabled
W1030 10:42:43.718089 main.cpp:757] HTTP server listening on port: 8042
W1030 10:42:43.718185 main.cpp:644] Orthanc has started
W1030 10:43:21.518996 main.cpp:702] Orthanc is stopping
W1030 10:43:21.569596 main.cpp:762] HTTP server has stopped
W1030 10:43:21.777432 main.cpp:836] DICOM server has stopped
W1030 10:43:22.808586 PluginsManager.cpp:218] Unregistering plugin 'serve-folders' (version 1.1.0)
W1030 10:43:22.808768 PluginsManager.cpp:218] Unregistering plugin 'worklists' (version 1.1.0)
W1030 10:43:22.808806 PluginsManager.cpp:167] Sample worklist plugin is finalizing
W1030 10:43:22.809511 main.cpp:1280] Orthanc has stopped

orthanc.json (11.3 KB)

OK, so your problem is here:

ilan@ilan-Desktop:~$ /usr/sbin/Orthanc --verbose
W1030 13:40:07.159492 main.cpp:1222] Orthanc version: 1.1.0
W1030 13:40:07.164091 OrthancInitialization.cpp:230] Using the default Orthanc configuration

[…]

As written in the log, Orthanc uses its default configuration file… which is not the file you edited (you reported it was “/etc/orthanc/orthanc.json”). It is thus perfectly normal that Orthanc does not take your modifications into account. In order to manually start Orthanc with your edited configuration, you must type:

$ Orthanc /etc/orthanc/ --verbose

The proper way of using the official Ubuntu package is as follows (this is the same procedure than that of many Linux services):

$ sudo apt-get install orthanc
$ nano /etc/orthanc/orthanc.json (…update your configuration…)
$ sudo /etc/init.d/orthanc restart

HTH,
Sébastien-

Dear Sebastien,
My mistake was thinking "what you see is what you get" on the default configuration file. I thought it would take the defaults from that file.
Even Orthanc /etc/orthanc/orthanc.json --verbose didn't give what I expected. It wanted to put the stored file into etc/OrthancStorage which was not what I wanted.

Never mind. I copied orthanc.json to my home directory so it put OrthancStorage in my directory. Finally I could see some dicom servers. A big step forward.

I am still having trouble with dcm4chee, but I'm not at all sure it is completely installed correctly. This is one of the major reasons why orthanc is so attractive, i.e. it is much easier to install. Thus I won't bother you with messages from dcm4chee.

Conquest is much easier to install, and it shows signs of life. I tried to have orthanc query Conquest to see a list of patients. I get this:

I1031 10:17:52.978862 DicomUserConnection.cpp:888] Opening a DICOM SCU connection from AET "ORTHANC" to AET "CONQUESTSRV1" on host 192.168.0.104:5678 (manufacturer: Generic)
W: DcmItem: Invalid Element (0000,0000) found in data set
W: DcmItem: Invalid Element (0000,0002) found in data set
W: DcmItem: Invalid Element (0000,0100) found in data set
W: DcmItem: Invalid Element (0000,0120) found in data set
W: DcmItem: Invalid Element (0000,0800) found in data set
W: DcmItem: Invalid Element (0000,0900) found in data set
I1031 10:17:53.201623 MongooseServer.cpp:723] GET /system
I1031 10:17:53.331060 MongooseServer.cpp:723] GET /queries/0f33037f-2c6b-4c7b-9803-9d3fce257a01/answers
I1031 10:17:58.046241 ReusableDicomUserConnection.cpp:94] Closing the global SCU connection after timeout

There is the usual Invalid Element business, where these are studies from commercial vendors, so I assume I can ignore the warnings. In any case orthanc came back with an empty list, and that shouldn't be. I don't know what that number 0f3303.... is - if it should appear on Conquest or not.

If I make the query from Conquest, I see the study on Orthanc, with the usual Invalid Elements
I1031 10:46:11.241089 CommandDispatcher.cpp:491] Association Received from AET CONQUESTSRV1 on IP 192.168.0.104
I1031 10:46:11.243003 CommandDispatcher.cpp:689] Association Acknowledged (Max Send PDV: 16372)
W: DcmItem: Invalid Element (0000,0000) found in data set
W: DcmItem: Invalid Element (0000,0002) found in data set
W: DcmItem: Invalid Element (0000,0100) found in data set
W: DcmItem: Invalid Element (0000,0110) found in data set
W: DcmItem: Invalid Element (0000,0700) found in data set
W: DcmItem: Invalid Element (0000,0800) found in data set
I1031 10:46:11.244324 main.cpp:119] No limit on the number of C-FIND results at the Patient, Study and Series levels
I1031 10:46:11.244381 main.cpp:129] No limit on the number of C-FIND results at the Instance level
I1031 10:46:11.292684 OrthancFindRequestHandler.cpp:578] DICOM C-Find request at level: Patient
I1031 10:46:11.292832 OrthancFindRequestHandler.cpp:584] (0008,0052) QueryRetrieveLevel = PATIENT
I1031 10:46:11.292970 OrthancFindRequestHandler.cpp:584] (0010,0010) PatientName =
I1031 10:46:11.293157 OrthancFindRequestHandler.cpp:584] (0010,0020) PatientID =
I1031 10:46:11.296797 OrthancFindRequestHandler.cpp:678] Number of matching resources: 1
I1031 10:46:11.299135 CommandDispatcher.cpp:860] DUL Peer Requested Release
I1031 10:46:11.299212 CommandDispatcher.cpp:867] Association Release

So far, so good. Next I try to pull the study from Orthanc. After a couple of false starts, I got Conquest to pull the study from Orthanc.

Thus in one direction it works. In the other direction, not quite there yet.

Thanks for all you help,
Ilan

Hello,

Glad to read things are getting better for you. This is nice to know you are able to pull from Orthanc using Conquest.

Even Orthanc /etc/orthanc/orthanc.json --verbose didn’t give what I expected. It wanted to put the stored file into etc/OrthancStorage which was not what I wanted.

This is actually the purpose of the “StorageDirectory” and “IndexDirectory” configuration options:

https://bitbucket.org/sjodogne/orthanc/raw/Orthanc-1.1.0/Resources/Configuration.json

Conquest is much easier to install, and it shows signs of life. I tried to have orthanc query Conquest to see a list of patients. I get this:

I1031 10:17:52.978862 DicomUserConnection.cpp:888] Opening a DICOM SCU connection from AET “ORTHANC” to AET “CONQUESTSRV1” on host 192.168.0.104:5678 (manufacturer: Generic)
I1031 10:17:53.201623 MongooseServer.cpp:723] GET /system
I1031 10:17:53.331060 MongooseServer.cpp:723] GET /queries/0f33037f-2c6b-4c7b-9803-9d3fce257a01/answers
I1031 10:17:58.046241 ReusableDicomUserConnection.cpp:94] Closing the global SCU connection after timeout

In any case orthanc came back with an empty list, and that shouldn’t be.

In the “DicomModalities” configuration option of Orthanc, you can add a manufacturer to enable some manufacturer-specific patches (currently, “StoreScp”, “ClearCanvas”, “MedInria”, “Dcm4Chee”, “SyngoVia”, “AgfaImpax”, and “EFilm2” are available). Please could you try each of them, in order to know whether one of this patch also solves your issue?

If none of these options works, the following pending issue in our bug tracker might provide an explanation:
https://bitbucket.org/sjodogne/orthanc/issues/19/query-retrieve-wildcard-problems

I don’t know what that number 0f3303… is - if it should appear on Conquest or not.

It is the ID of the query/retrieve request that Orthanc Explorer made using the REST API of Orthanc. As an end-user of Orthanc, you can ignore this information that is internal to Orthanc.

Sébastien-

Dear Sebastien,
I tried all the possibilities one by one. In each case C-ECHO worked but an empty list was returned.
I looked into the bug report where it said there was success with an empty string in place of *. No such luck with me - still an empty string.
The only one I had real hopes for was StoreScp. I tried all the others just to be sure, but no luck on anything.

I suppose I could try to find out what is wrong with dcm4chee, and try that as well. The real trouble with dcm4chee is I can just see some poor physician in the field trying to install it - good luck, as they say. I did do it once a few years ago under Windows. Even then it wasn't easy.
Orthanc is almost trivial by comparison.

In any case, if there is anything I can do to help, please let me know. Salim will start to test Orthanc in his department in Toulouse. I'm not sure what environment he has there.

Thanks for all the help,
Ilan

Dear Sebastien,
Just to complete the picture I tried to push from Conquest to Orthanc.
That also works like a charm (using the default Generic).

So the only piece missing is to have Orthanc read Conquest.

Best regards,
Ilan

Dear Sébastien,

Just a message to present myself, i'm a nuclear medicin physician working with Ilan for almost 3 years now.

Our project is to build a free and open source pet ct viewer, project that Ilan started long time ago with beth israel hospital in Boston and I joint it because I needed specific quantification in pet/ct to calculate metabolic tumor volume.

We made a lot of developpement in our pet/ct viewer and we add a lot of functions with many display and quantification feature.

These last week we had a long discussion with Ilan because even if the viewer is pretty good we still miss Dicom capabilities to allows our user to connect our software to an existing dicom network.

I found your project on the internet some days ago and we figured the very high potential of using your software for dicom communication especially thanks to all the restapi you provide.

There are a lot of functions you made that i'm interessted in, of course all the dicom query / move etc function but also some unexpected functionalities like anonimization features (because our first goal is to provide a software tool for pet/ct processing in reasearch and we will need to share anonimized data).

However, this message is just to say that your software is a huge opportunity for us. By integrating your services with our software you should also get benefit for your project by bringing new users and new applications to your software.

Of course we will mention your software in our website and give all credit of dicom exchange features to your work that will have to be visible.

It is sad I didn't discover your work before because just few weeks ago i was working in Dijon which was not to far from Liège (now i'm relocating in Toulouse)

However thank you so much for your help, I let you continue your discussion with Ilan for that exciting project.

As soon as I will be in my new departement I will make some dicom testing (as a physician I have the easy part of the job bringing ideas and make testing, Ilan handles 100℅ of code writing).

Best regards,

Salim

Hello,

I have made tests against Conquest, and the transfers work fine, in both directions.

For reference, you will find below the instructions to reproduce my test environment using Docker.

Terminal 1 - Configure and start Conquest

sudo docker run --rm --entrypoint=cat wavedrift/docker-conquest /conquest/acrnema.map > /tmp/acrnema.map

echo “ORTHANC localhost 4242 un” >> /tmp/acrnema.map

sudo docker run --name conquest --rm -t -i -p 4242:4242 -p 8042:8042 -p 5678:5678 -p 8043:80 -v /tmp/acrnema.map:/conquest/acrnema.map:ro wavedrift/docker-conquest

The Conquest Web interface is then accessible at: http://localhost:8043/cgi-bin/dgate

Note that “ORTHANC” is added to the drop-down list of servers next to “Find patient”.

Terminal 2 - Configure and start Orthanc

sudo docker run --rm --entrypoint=cat jodogne/orthanc /etc/orthanc/orthanc.json > /tmp/orthanc.json

Edit “/tmp/orthanc.json” so that the “DicomModalities” section looks like:

“DicomModalities” : {
“conquest” : [ “CONQUESTSRV1”, “localhost”, 5678 ]
},

Then start Orthanc, using the same network stack as Conquest (so that “localhost” is shared by both Orthanc and Conquest):

sudo docker run --rm -v /tmp/orthanc.json:/etc/orthanc/orthanc.json:ro --net container:conquest jodogne/orthanc /etc/orthanc/ --verbose

Summary of the TCP ports that are in use:

Play with the Web interfaces, and you’ll see everything working as expected. In particular, it is possible to query/retrieve the content of Conquest from Orthanc Explorer.

HTH,
Sébastien-

Dear Salim,

Thanks for your feedback: I am delighted to read that Orthanc might prove useful to connect your PET/CT viewer to the DICOM network of any hospital.

This is especially nice to know that your work on nuclear medicine might bring Orthanc to a wider audience, starting from French hospitals such as Toulouse and Dijon.

The Orthanc project is of course happy to know that you will reference it on your Web site. Conversely, do not hesitate to ask inclusion on our list of references published on our own homepage:
http://www.orthanc-server.com/static.php?page=references

I am looking forward to see how your project grows. Please keep us updated :slight_smile:

Sincerely,
Sébastien-

Dear Sebastien,

Sure, we will give you updates,

Ilan is working on implementing your services in our viewer, we are going to enter in a development/testing/bug-fixing time for probably several weeks.

When we will have something stable we will announce it in our website and we will share our links on both websites.

Probably that we will have questions during that development time, so you will have updates anyway,

Very happy to start this collaboration, i'm sure that we can push both software in many places, starting with Dijon and Toulouse but also much further.

Sincerely,

Salim