I realized today that my version of Orthanc, via the repos, is only 1.0. I think it would be a lovely addition to have the version that you’re running somewhere within the GUI as the only place I could see what version I did have was in the logging. Anyway, I digress…
So, I spent the time today compiling 1.5.6. After everything was done, I ran “./Orthanc” in my build folder and everything started up just fine.
I then stopped the application as I wanted to generate the config file, which I did, but then attempting to start Orthanc again failed with
W0514 19:33:25.295360 main.cpp:1436] Orthanc version: 1.5.6 W0514 19:33:25.304287 OrthancConfiguration.cpp:161] Using the default Orthanc configuration W0514 19:33:25.343905 OrthancInitialization.cpp:301] SQLite index directory: "~/BuildOrthanc/OrthancStorage" W0514 19:33:25.352478 OrthancInitialization.cpp:376] Storage directory: "~/BuildOrthanc/OrthancStorage" E0514 19:33:25.360079 StatementReference.cpp:85] SQLite: disk I/O error (5386) E0514 19:33:25.363351 main.cpp:1462] Uncaught exception, stopping now: [SQLite: Cannot prepare a cached statement] (code 1012) W0514 19:33:25.364958 main.cpp:1495] Orthanc has stopped
Now I can’t start Orthanc again, unless I delete the OrthancStorage folder.
I’ve tried creating the config first and then starting - every time it runs the first time, but as soon as I stop, I can’t start again without removing the storage folder.
(5386) SQLITE_IOERR_SHMMAP
The SQLITE_IOERR_SHMMAP error code is an extended error code for SQLITE_IOERR indicating an I/O error within the xShmMap method on the sqlite3_io_methods object while trying to map a shared memory segment into the process address space.
The filesystem containing your “~/BuildOrthanc/OrthancStorage” folder visibly does not support mmap().
Understood Sebastien. I was hoping I wouldn’t need to go into setting the mmap up as that’s a little above my paygrade, but…
On a slightly different tack, I see that there are binaries on Orthanc’s lsb site: are these precompiled binaries that are for general use and if so, how do we go about using them? Am I going to run into the same mmap issues (when I installed v1.0 using the repos everything just worked, there’s no difference in the filesystems that I’m using - in fact, it’s the same VM just snapshot between various builds)? I see that there’s a mainline as well as a 1.5.6 set of files, with differing filesizes. In the hope that these could be used, could you explain the difference between mainline and the current version, as it appears that the mainline isn’t merely linked to the current version.
2- “Are these precompiled [LSB] binaries that are for general use and if so, how do we go about using them.” Yes, they are for general use (those binaries are notably used as-such in the Docker images). Just download them (note you’ll have to make “chmod +x ./Orthanc” if downloading the Orthanc core).
3- If using the Ubuntu 16.04 package, Orthanc is dynamically linked with the version 3.11.0 of SQLite that is shipped by Ubuntu. If using the precompiled LSB binaries, Orthanc is statically linked with SQLite 3.27.1. This explains the difference of behavior of SQLite.
I’m a big fan of being able to assist where I can so I will certainly look into maintaining a PPA for you guys.
For the time being, if it’s helpful to others, I have attached a bash script that utilizes (currently) the 1.5.6 binaries available and installs Orthanc using the default SQLite3 database or, if preferred, the MySQL plugin.