]> git.proxmox.com Git - ceph.git/blob - ceph/doc/rados/configuration/journal-ref.rst
add subtree-ish sources for 12.0.3
[ceph.git] / ceph / doc / rados / configuration / journal-ref.rst
1 ==========================
2 Journal Config Reference
3 ==========================
4
5 .. index:: journal; journal configuration
6
7 Ceph OSDs use a journal for two reasons: speed and consistency.
8
9 - **Speed:** The journal enables the Ceph OSD Daemon to commit small writes
10 quickly. Ceph writes small, random i/o to the journal sequentially, which
11 tends to speed up bursty workloads by allowing the backing filesystem more
12 time to coalesce writes. The Ceph OSD Daemon's journal, however, can lead
13 to spiky performance with short spurts of high-speed writes followed by
14 periods without any write progress as the filesystem catches up to the
15 journal.
16
17 - **Consistency:** Ceph OSD Daemons require a filesystem interface that
18 guarantees atomic compound operations. Ceph OSD Daemons write a description
19 of the operation to the journal and apply the operation to the filesystem.
20 This enables atomic updates to an object (for example, placement group
21 metadata). Every few seconds--between ``filestore max sync interval`` and
22 ``filestore min sync interval``--the Ceph OSD Daemon stops writes and
23 synchronizes the journal with the filesystem, allowing Ceph OSD Daemons to
24 trim operations from the journal and reuse the space. On failure, Ceph
25 OSD Daemons replay the journal starting after the last synchronization
26 operation.
27
28 Ceph OSD Daemons support the following journal settings:
29
30
31 ``journal dio``
32
33 :Description: Enables direct i/o to the journal. Requires ``journal block
34 align`` set to ``true``.
35
36 :Type: Boolean
37 :Required: Yes when using ``aio``.
38 :Default: ``true``
39
40
41
42 ``journal aio``
43
44 .. versionchanged:: 0.61 Cuttlefish
45
46 :Description: Enables using ``libaio`` for asynchronous writes to the journal.
47 Requires ``journal dio`` set to ``true``.
48
49 :Type: Boolean
50 :Required: No.
51 :Default: Version 0.61 and later, ``true``. Version 0.60 and earlier, ``false``.
52
53
54 ``journal block align``
55
56 :Description: Block aligns write operations. Required for ``dio`` and ``aio``.
57 :Type: Boolean
58 :Required: Yes when using ``dio`` and ``aio``.
59 :Default: ``true``
60
61
62 ``journal max write bytes``
63
64 :Description: The maximum number of bytes the journal will write at
65 any one time.
66
67 :Type: Integer
68 :Required: No
69 :Default: ``10 << 20``
70
71
72 ``journal max write entries``
73
74 :Description: The maximum number of entries the journal will write at
75 any one time.
76
77 :Type: Integer
78 :Required: No
79 :Default: ``100``
80
81
82 ``journal queue max ops``
83
84 :Description: The maximum number of operations allowed in the queue at
85 any one time.
86
87 :Type: Integer
88 :Required: No
89 :Default: ``500``
90
91
92 ``journal queue max bytes``
93
94 :Description: The maximum number of bytes allowed in the queue at
95 any one time.
96
97 :Type: Integer
98 :Required: No
99 :Default: ``10 << 20``
100
101
102 ``journal align min size``
103
104 :Description: Align data payloads greater than the specified minimum.
105 :Type: Integer
106 :Required: No
107 :Default: ``64 << 10``
108
109
110 ``journal zero on create``
111
112 :Description: Causes the file store to overwrite the entire journal with
113 ``0``'s during ``mkfs``.
114 :Type: Boolean
115 :Required: No
116 :Default: ``false``