Orthanc core dump

Hello!
I’m using orthanc in a docker container routing studios from a station to a pacs, using lua with the following code “Delete(SendToModality(instanceId, destination))” because i have to delete the study once sent. The server works fine, studios are received and routed, but sometimes an error occurs, resulting in a core dump and the container stops, so i have to restart it again. it happens several times every day, especially when the studies received begin to accumulate. The logs show this info:

realloc(): invalid next size

the host file /var/lib/messages shows:
kernel: [60660190.605123] traps: Orthanc[4087] general protection fault ip:7f2e243a1611 sp:7f2de4fd0640 error:0 in libc-2.28.so[7f2e243a1000+147000]

What could be the problem?

Thanks!

No idea, but you might want to check your system resources, i.e. RAM, CPU’s, Heap memory, etc. That is a bad error.

Hello,

It is unfortunately impossible to answer without a minimal working example for us to reproduce your issue.

I would suggest to build Orthanc from scratch in debug mode using -DCMAKE_BUILD_TYPE=Debug, then use gdb to generate a backtrace.

Regards,
Sébastien-

PS: I would suspect that you might be using a 32-bit version of Orthanc, and receiving large DICOM files of several hundreds of megabytes, which would result in a out-of-memory crash. Try using a 64-bit version.