Fix some bugs when testing opensds ansible
[stor4nfv.git] / src / ceph / doc / dev / ceph-volume / lvm.rst
1
2 .. _ceph-volume-lvm-api:
3
4 LVM
5 ===
6 The backend of ``ceph-volume lvm`` is LVM, it relies heavily on the usage of
7 tags, which is a way for LVM to allow extending its volume metadata. These
8 values can later be queried against devices and it is how they get discovered
9 later.
10
11 .. warning:: These APIs are not meant to be public, but are documented so that
12              it is clear what the tool is doing behind the scenes. Do not alter
13              any of these values.
14
15
16 .. _ceph-volume-lvm-tag-api:
17
18 Tag API
19 -------
20 The process of identifying logical volumes as part of Ceph relies on applying
21 tags on all volumes. It follows a naming convention for the namespace that
22 looks like::
23
24     ceph.<tag name>=<tag value>
25
26 All tags are prefixed by the ``ceph`` keyword do claim ownership of that
27 namespace and make it easily identifiable. This is how the OSD ID would be used
28 in the context of lvm tags::
29
30     ceph.osd_id=0
31
32
33 .. _ceph-volume-lvm-tags:
34
35 Metadata
36 --------
37 The following describes all the metadata from Ceph OSDs that is stored on an
38 LVM volume:
39
40
41 ``type``
42 --------
43 Describes if the device is a an OSD or Journal, with the ability to expand to
44 other types when supported (for example a lockbox)
45
46 Example::
47
48     ceph.type=osd
49
50
51 ``cluster_fsid``
52 ----------------
53 Example::
54
55     ceph.cluster_fsid=7146B649-AE00-4157-9F5D-1DBFF1D52C26
56
57 ``data_device``
58 ---------------
59 Example::
60
61     ceph.data_device=/dev/ceph/data-0
62
63 ``journal_device``
64 ------------------
65 Example::
66
67     ceph.journal_device=/dev/ceph/journal-0
68
69 ``encrypted``
70 -------------
71 Example for enabled encryption with ``luks``::
72
73     ceph.encrypted=luks
74
75 For plain dmcrypt::
76
77     ceph.encrypted=dmcrypt
78
79 For disabled encryption::
80
81     ceph.encrypted=0
82
83 ``osd_fsid``
84 ------------
85 Example::
86
87     ceph.osd_fsid=88ab9018-f84b-4d62-90b4-ce7c076728ff
88
89 ``osd_id``
90 ----------
91 Example::
92
93     ceph.osd_id=1
94
95 ``block``
96 ---------
97 Just used on :term:`bluestore` backends.
98
99 Example::
100
101     ceph.block=/dev/mapper/vg-block-0
102
103 ``db``
104 ------
105 Just used on :term:`bluestore` backends.
106
107 Example::
108
109     ceph.db=/dev/mapper/vg-db-0
110
111 ``wal``
112 -------
113 Just used on :term:`bluestore` backends.
114
115 Example::
116
117     ceph.wal=/dev/mapper/vg-wal-0
118
119
120 ``lockbox_device``
121 ------------------
122 Only used when encryption is enabled, to store keys in an unencrypted
123 volume.
124
125 Example::
126
127     ceph.lockbox_device=/dev/mapper/vg-lockbox-0