Segfault / general protection error on query retreive

when doing a query retreive i have a segfault error on the server upon receiving the answer or request

The orthanc server crash instantly

No error on orthanc logs , I had to search in the syslog to find something

Error in log:

segfault at 312e42 ip 00007f8ae5695fe4 sp 00007f8aba7edb78 error 4 in libdcmnet.so.14.3.6.4[7f8ae562e000+b7000]

sometimes general protection fault with the same error

Problem on orthanc v12 and earlier (we tried to update our orthanc version but got the same error)

We had the bug on the deb package version and locally compiled version.

Our server is hosted on a ubuntu 20 machine

Identified cause:

The update of libdcmtk14 libdcmtk-dev … (auto updated via the unattended upgrade service on ubuntu), it seems related to libcurl

fix:

reinstall older version of the lib via apt-get install libdcmtk14=3.6.4-2.1build2 libdcmtk-dev=3.6.4-2.1build2 dcmtk=3.6.4-2.1build2
and disable unattended upgrade

Hello,

If you use a version of a software that is dynamically linked against your system libraries, you cannot upgrade these libraries without having to recompile the software. Otherwise you get random crashes such as yours. This is absolutely not specific to Orthanc.

This is why the Orthanc project provides binaries that are statically linked against the required third-party libraries. Check out the “linux-standard-base” folder on our download server.

Regards,
Sébastien-

Hello,

For further reference, there exists a bug report lined to Ubuntu 20.04 about this specific crash: Bug #2081100 “Segmentation fault after installing ubuntu 20.04 s...” : Bugs : dcmtk package : Ubuntu

As a consequence, I confirm that this issue is by no way not related to Orthanc.

As already indicated by @nicolas, the fix consists in typing:

$ sudo apt install dcmtk=3.6.4-2.1build2 libdcmtk-dev=3.6.4-2.1build2 libdcmtk14=3.6.4-2.1build2

Regards,
Sébastien-