annotate Sphinx/source/faq/scalability.rst @ 186:a846a8f6d9a6

scalability
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 31 Jan 2019 18:41:44 +0100
parents
children 0fa1cf88c635
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
186
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 .. _scalability:
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3 Scalability of Orthanc
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 ======================
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 One of the most common question about Orthanc is: *"How many DICOM
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 instances can be stored by Orthanc?"*
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9 The source code of Orthanc imposes no such hard limit by itself. The
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10 stress is actually put on the underlying database engine, and on the
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 storage area (check out :ref:`orthanc-storage`). As explained in the
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 :ref:`troubleshooting section <troubleshooting>`, the built-in SQLite
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13 database engine should be replaced by an enterprise-ready database
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 engine as soon as the number of DICOM instances grow above about
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 50,000 (check out the :ref:`postgresql` and :ref:`mysql`). It is also
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16 true that the performance of Orthanc in the presence of large
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 databases has continuously improved over time, especially when it comes
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
18 to the speed of :ref:`DICOM C-FIND <dicom-find>`.
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
20 Here is a generic setup that should provide best performance in the
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
21 presence of large databases:
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
22
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23 * Make sure that :ref:`run-time debug assertions <troubleshooting>`
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
24 are turned off. A warning will show in the logs if this is not the
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
25 case.
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
26
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
27 * Make sure to use the latest release of Orthanc (1.5.3 at the time of
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
28 writing).
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
29
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30 * We suggest to use the latest release of the :ref:`PostgreSQL plugin
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31 <postgresql>` to store the database index (3.0 at the time of
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32 writing). Make sure that ``EnableIndex`` is set to ``true``.
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 * We suggest to use the default filesystem storage area. Of course,
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35 make sure that the filesystem is properly backup, and that
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36 technologies such as RAID are enabled. Make sure that the option
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
37 ``EnableStorage`` of the PostgreSQL plugins is set to ``false``.
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
38
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
39 * Obviously, the PostgreSQL database should be stored on a high-speed
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
40 drive (SSD). This is less important for the storage area.
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
41
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
42 * The :ref:`Orthanc configuration file <configuration>` should have
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
43 the following values for performance-related options (but make sure
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
44 to understand their implication):
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
45
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
46 * ``StorageCompression = false``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
47 * ``LimitFindResults = 100``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
48 * ``LimitFindInstances = 100``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
49 * ``KeepAlive = true``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
50 * ``TcpNoDelay = true``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
51 * ``SaveJobs = false``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
52 * ``StorageAccessOnFind = Never``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
53
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
54 * Make sure to carefully :ref:`read the logs <log>` in ``--verbose``
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
55 mode, especially at the startup of Orthanc. The logs may contain
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
56 very important information regarding performance.
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
57
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58 * Make sure to read guides about the :ref:`tuning of PostgreSQL
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59 <https://wiki.postgresql.org/wiki/Performance_Optimization>`__.
a846a8f6d9a6 scalability
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60