Push zealand version of opensds ansible as base-code of Stor4NFV
[stor4nfv.git] / ci / ansible / group_vars / ceph / osds.yml
1 ---\r
2 # Variables here are applicable to all host groups NOT roles\r
3 \r
4 # This sample file generated by generate_group_vars_sample.sh\r
5 \r
6 # Dummy variable to avoid error because ansible does not recognize the\r
7 # file as a good configuration file when no variable in it.\r
8 dummy:\r
9 \r
10 # You can override default vars defined in defaults/main.yml here,\r
11 # but I would advice to use host or group vars instead\r
12 \r
13 #raw_journal_devices: "{{ dedicated_devices }}" # backward compatibility with stable-2.2, will disappear in stable 3.1\r
14 #journal_collocation: False # backward compatibility with stable-2.2, will disappear in stable 3.1\r
15 #raw_multi_journal: False # backward compatibility with stable-2.2, will disappear in stable 3.1\r
16 #dmcrytpt_journal_collocation: False # backward compatibility with stable-2.2, will disappear in stable 3.1\r
17 #dmcrypt_dedicated_journal: False # backward compatibility with stable-2.2, will disappear in stable 3.1\r
18 \r
19 \r
20 ###########\r
21 # GENERAL #\r
22 ###########\r
23 \r
24 # Even though OSD nodes should not have the admin key\r
25 # at their disposal, some people might want to have it\r
26 # distributed on OSD nodes. Setting 'copy_admin_key' to 'true'\r
27 # will copy the admin key to the /etc/ceph/ directory\r
28 #copy_admin_key: false\r
29 \r
30 \r
31 ####################\r
32 # OSD CRUSH LOCATION\r
33 ####################\r
34 \r
35 # /!\\r
36 #\r
37 # BE EXTREMELY CAREFUL WITH THIS OPTION\r
38 # DO NOT USE IT UNLESS YOU KNOW WHAT YOU ARE DOING\r
39 #\r
40 # /!\\r
41 #\r
42 # It is probably best to keep this option to 'false' as the default\r
43 # suggests it. This option should only be used while doing some complex\r
44 # CRUSH map. It allows you to force a specific location for a set of OSDs.\r
45 #\r
46 # The following options will build a ceph.conf with OSD sections\r
47 # Example:\r
48 # [osd.X]\r
49 # osd crush location = "root=location"\r
50 #\r
51 # This works with your inventory file\r
52 # To match the following 'osd_crush_location' option the inventory must look like:\r
53 #\r
54 # [osds]\r
55 # osd0 ceph_crush_root=foo ceph_crush_rack=bar\r
56 \r
57 #crush_location: false\r
58 #osd_crush_location: "\"root={{ ceph_crush_root }} rack={{ ceph_crush_rack }} host={{ ansible_hostname }}\""\r
59 \r
60 \r
61 ##############\r
62 # CEPH OPTIONS\r
63 ##############\r
64 \r
65 # Devices to be used as OSDs\r
66 # You can pre-provision disks that are not present yet.\r
67 # Ansible will just skip them. Newly added disk will be\r
68 # automatically configured during the next run.\r
69 #\r
70 \r
71 \r
72 # Declare devices to be used as OSDs\r
73 # All scenario(except 3rd) inherit from the following device declaration\r
74 \r
75 devices:\r
76 #  - /dev/sda\r
77 #  - /dev/sdc\r
78 #  - /dev/sdd\r
79 #  - /dev/sde\r
80 \r
81 #devices: []\r
82 \r
83 \r
84 #'osd_auto_discovery'  mode prevents you from filling out the 'devices' variable above.\r
85 #  You can use this option with First and Forth and Fifth OSDS scenario.\r
86 # Device discovery is based on the Ansible fact 'ansible_devices'\r
87 # which reports all the devices on a system. If chosen all the disks\r
88 # found will be passed to ceph-disk. You should not be worried on using\r
89 # this option since ceph-disk has a built-in check which looks for empty devices.\r
90 # Thus devices with existing partition tables will not be used.\r
91 #\r
92 #osd_auto_discovery: false\r
93 \r
94 # Encrypt your OSD device using dmcrypt\r
95 # If set to True, no matter which osd_objecstore and osd_scenario you use the data will be encrypted\r
96 #dmcrypt: "{{ True if dmcrytpt_journal_collocation or dmcrypt_dedicated_journal else False }}" # backward compatibility with stable-2.2, will disappear in stable 3.1\r
97 \r
98 \r
99 # I. First scenario: collocated\r
100 #\r
101 # To enable this scenario do: osd_scenario: collocated\r
102 #\r
103 #\r
104 # If osd_objectstore: filestore is enabled both 'ceph data' and 'ceph journal' partitions\r
105 # will be stored on the same device.\r
106 #\r
107 # If osd_objectstore: bluestore is enabled 'ceph data', 'ceph block', 'ceph block.db', 'ceph block.wal' will be stored\r
108 # on the same device. The device will get 2 partitions:\r
109 # - One for 'data', called 'ceph data'\r
110 # - One for 'ceph block', 'ceph block.db', 'ceph block.wal' called 'ceph block'\r
111 #\r
112 # Example of what you will get:\r
113 # [root@ceph-osd0 ~]# blkid /dev/sda*\r
114 # /dev/sda: PTTYPE="gpt"\r
115 # /dev/sda1: UUID="9c43e346-dd6e-431f-92d8-cbed4ccb25f6" TYPE="xfs" PARTLABEL="ceph data" PARTUUID="749c71c9-ed8f-4930-82a7-a48a3bcdb1c7"\r
116 # /dev/sda2: PARTLABEL="ceph block" PARTUUID="e6ca3e1d-4702-4569-abfa-e285de328e9d"\r
117 #\r
118 \r
119 #osd_scenario: "{{ 'collocated' if journal_collocation or dmcrytpt_journal_collocation else 'non-collocated' if raw_multi_journal or dmcrypt_dedicated_journal else 'dummy' }}" # backward compatibility with stable-2.2, will disappear in stable 3.1\r
120 #valid_osd_scenarios:\r
121 #  - collocated\r
122 #  - non-collocated\r
123 #  - lvm\r
124 osd_scenario: collocated\r
125 \r
126 # II.  Second scenario: non-collocated\r
127 #\r
128 # To enable this scenario do: osd_scenario: non-collocated\r
129 #\r
130 # If osd_objectstore: filestore is enabled 'ceph data' and 'ceph journal' partitions\r
131 # will be stored on different devices:\r
132 # - 'ceph data' will be stored on the device listed in 'devices'\r
133 # - 'ceph journal' will be stored on the device listed in 'dedicated_devices'\r
134 #\r
135 # Let's take an example, imagine 'devices' was declared like this:\r
136 #\r
137 # devices:\r
138 #   - /dev/sda\r
139 #   - /dev/sdb\r
140 #   - /dev/sdc\r
141 #   - /dev/sdd\r
142 #\r
143 # And 'dedicated_devices' was declared like this:\r
144 #\r
145 # dedicated_devices:\r
146 #   - /dev/sdf\r
147 #   - /dev/sdf\r
148 #   - /dev/sdg\r
149 #   - /dev/sdg\r
150 #\r
151 # This will result in the following mapping:\r
152 # - /dev/sda will have /dev/sdf1 as journal\r
153 # - /dev/sdb will have /dev/sdf2 as a journal\r
154 # - /dev/sdc will have /dev/sdg1 as a journal\r
155 # - /dev/sdd will have /dev/sdg2 as a journal\r
156 #\r
157 #\r
158 # If osd_objectstore: bluestore is enabled, both 'ceph block.db' and 'ceph block.wal' partitions will be stored\r
159 # on a dedicated device.\r
160 #\r
161 # So the following will happen:\r
162 # - The devices listed in 'devices' will get 2 partitions, one for 'block' and one for 'data'.\r
163 # 'data' is only 100MB big and do not store any of your data, it's just a bunch of Ceph metadata.\r
164 # 'block' will store all your actual data.\r
165 # - The devices in 'dedicated_devices' will get 1 partition for RocksDB DB, called 'block.db'\r
166 #  and one for RocksDB WAL, called 'block.wal'\r
167 #\r
168 # By default dedicated_devices will represent block.db\r
169 #\r
170 # Example of what you will get:\r
171 # [root@ceph-osd0 ~]# blkid /dev/sd*\r
172 # /dev/sda: PTTYPE="gpt"\r
173 # /dev/sda1: UUID="c6821801-2f21-4980-add0-b7fc8bd424d5" TYPE="xfs" PARTLABEL="ceph data" PARTUUID="f2cc6fa8-5b41-4428-8d3f-6187453464d0"\r
174 # /dev/sda2: PARTLABEL="ceph block" PARTUUID="ea454807-983a-4cf2-899e-b2680643bc1c"\r
175 # /dev/sdb: PTTYPE="gpt"\r
176 # /dev/sdb1: PARTLABEL="ceph block.db" PARTUUID="af5b2d74-4c08-42cf-be57-7248c739e217"\r
177 # /dev/sdb2: PARTLABEL="ceph block.wal" PARTUUID="af3f8327-9aa9-4c2b-a497-cf0fe96d126a"\r
178 #dedicated_devices: []\r
179 \r
180 \r
181 # More device granularity for Bluestore\r
182 #\r
183 # ONLY if osd_objectstore: bluestore is enabled.\r
184 #\r
185 # By default, if 'bluestore_wal_devices' is empty, it will get the content of 'dedicated_devices'.\r
186 # If set, then you will have a dedicated partition on a specific device for block.wal.\r
187 #\r
188 # Example of what you will get:\r
189 # [root@ceph-osd0 ~]# blkid /dev/sd*\r
190 # /dev/sda: PTTYPE="gpt"\r
191 # /dev/sda1: UUID="39241ae9-d119-4335-96b3-0898da8f45ce" TYPE="xfs" PARTLABEL="ceph data" PARTUUID="961e7313-bdb7-49e7-9ae7-077d65c4c669"\r
192 # /dev/sda2: PARTLABEL="ceph block" PARTUUID="bff8e54e-b780-4ece-aa16-3b2f2b8eb699"\r
193 # /dev/sdb: PTTYPE="gpt"\r
194 # /dev/sdb1: PARTLABEL="ceph block.db" PARTUUID="0734f6b6-cc94-49e9-93de-ba7e1d5b79e3"\r
195 # /dev/sdc: PTTYPE="gpt"\r
196 # /dev/sdc1: PARTLABEL="ceph block.wal" PARTUUID="824b84ba-6777-4272-bbbd-bfe2a25cecf3"\r
197 #bluestore_wal_devices: "{{ dedicated_devices }}"\r
198 \r
199 # III. Use ceph-volume to create OSDs from logical volumes.\r
200 # Use 'osd_scenario: lvm' to enable this scenario. Currently we only support dedicated journals\r
201 # when using lvm, not collocated journals.\r
202 # lvm_volumes is a list of dictionaries. Each dictionary must contain a data, journal and vg_name\r
203 # key. Any logical volume or logical group used must be a name and not a path.\r
204 # data must be a logical volume\r
205 # journal can be either a lv, device or partition. You can not use the same journal for many data lvs.\r
206 # data_vg must be the volume group name of the data lv\r
207 # journal_vg is optional and must be the volume group name of the journal lv, if applicable\r
208 # For example:\r
209 # lvm_volumes:\r
210 #   - data: data-lv1\r
211 #     data_vg: vg1\r
212 #     journal: journal-lv1\r
213 #     journal_vg: vg2\r
214 #   - data: data-lv2\r
215 #     journal: /dev/sda\r
216 #     data_vg: vg1\r
217 #   - data: data-lv3\r
218 #     journal: /dev/sdb1\r
219 #     data_vg: vg2\r
220 #lvm_volumes: []\r
221 \r
222 \r
223 ##########\r
224 # DOCKER #\r
225 ##########\r
226 \r
227 #ceph_config_keys: [] # DON'T TOUCH ME\r
228 \r
229 # Resource limitation\r
230 # For the whole list of limits you can apply see: docs.docker.com/engine/admin/resource_constraints\r
231 # Default values are based from: https://access.redhat.com/documentation/en-us/red_hat_ceph_storage/2/html/red_hat_ceph_storage_hardware_guide/minimum_recommendations\r
232 # These options can be passed using the 'ceph_osd_docker_extra_env' variable.\r
233 #ceph_osd_docker_memory_limit: 1g\r
234 #ceph_osd_docker_cpu_limit: 1\r
235 \r
236 # PREPARE DEVICE\r
237 #\r
238 # WARNING /!\ DMCRYPT scenario ONLY works with Docker version 1.12.5 and above\r
239 #\r
240 #ceph_osd_docker_devices: "{{ devices }}"\r
241 #ceph_osd_docker_prepare_env: -e OSD_JOURNAL_SIZE={{ journal_size }}\r
242 \r
243 # ACTIVATE DEVICE\r
244 #\r
245 #ceph_osd_docker_extra_env:\r
246 #ceph_osd_docker_run_script_path: "/usr/share" # script called by systemd to run the docker command\r
247 \r
248 \r
249 ###########\r
250 # SYSTEMD #\r
251 ###########\r
252 \r
253 # ceph_osd_systemd_overrides will override the systemd settings\r
254 # for the ceph-osd services.\r
255 # For example,to set "PrivateDevices=false" you can specify:\r
256 #ceph_osd_systemd_overrides:\r
257 #  Service:\r
258 #    PrivateDevices: False\r
259 \r