Mercurial > hg > orthanc-book
annotate Sphinx/source/faq/log.rst @ 23:f99aa6a6f0c9
Generating an Exploitable Log
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Thu, 14 Jul 2016 09:47:19 +0200 |
parents | |
children | 87803e4e9c91 |
rev | line source |
---|---|
23
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
1 .. _log: |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
2 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
3 Generating an Exploitable Log |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
4 ----------------------------- |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
5 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
6 For your log to be exploitable by the Orthanc community, you must |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
7 generate them with the ``--verbose`` or ``--trace``. If you are using |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
8 Orthanc at the command-line, simply add these flags and redirect the |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
9 standard outputs to some log file. |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
10 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
11 However, if you use packaged versions of Orthanc that runs the server |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
12 in background, you will have to manually start Orthanc. The sections |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
13 below explain how to achieve this goal with the officially supported |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
14 packages. |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
15 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
16 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
17 Under Windows |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
18 ^^^^^^^^^^^^^ |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
19 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
20 Under Windows, if you used the official installer: |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
21 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
22 1. Download the `precompiled command-line version |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
23 <http://www.orthanc-server.com/download-windows.php>`__ of Orthanc. |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
24 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
25 2. Stop the Orthanc service. The actual process depends on your |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
26 version of Windows. |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
27 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
28 3. Copy the just-downloaded ``Orthanc-1.1.0-Release.exe`` together |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
29 with your configuration file (that is by default located in |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
30 ``C:\Orthanc\Configuration.json``) into the same folder |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
31 (e.g. ``C:\Temp``). |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
32 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
33 4. Type in a command-line shell, to generate the ``Orthanc.log`` file:: |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
34 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
35 $ cd C:\Temp |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
36 $ Orthanc-1.1.0-Release.exe --verbose Configuration.json > Orthanc.log 2<&1 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
37 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
38 5. Restart the Orthanc service. |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
39 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
40 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
41 Under Debian GNU/Linux |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
42 ^^^^^^^^^^^^^^^^^^^^^^ |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
43 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
44 1. Stop the Orthanc service:: |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
45 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
46 $ sudo /etc/init.d/orthanc stop |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
47 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
48 2. Manually start Orthanc (using the same configuration as the |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
49 service) and generate the log:: |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
50 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
51 $ sudo -u orthanc /usr/sbin/Orthanc --verbose /etc/orthanc/ > Orthanc.log 2>&1 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
52 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
53 3. Restart the Orthanc service:: |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
54 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
55 $ sudo /etc/init.d/orthanc start |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
56 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
57 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
58 Under Docker |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
59 ^^^^^^^^^^^^ |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
60 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
61 The command-line to be used is:: |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
62 |
f99aa6a6f0c9
Generating an Exploitable Log
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff
changeset
|
63 $ sudo docker run -a stderr -p 4242:4242 -p 8042:8042 --rm jodogne/orthanc --verbose /etc/orthanc > Orthanc.log 2>&1 |