2015-02-15 09:21:27 +08:00
|
|
|
#jinja2: trim_blocks: "true", lstrip_blocks: "true"
|
2014-10-10 21:41:31 +08:00
|
|
|
# {{ ansible_managed }}
|
2014-03-04 02:08:51 +08:00
|
|
|
|
|
|
|
[global]
|
|
|
|
{% if cephx %}
|
2015-12-16 23:11:14 +08:00
|
|
|
auth cluster required = cephx
|
|
|
|
auth service required = cephx
|
|
|
|
auth client required = cephx
|
|
|
|
cephx require signatures = {{ cephx_require_signatures }} # Kernel RBD does NOT support signatures!
|
|
|
|
cephx cluster require signatures = {{ cephx_cluster_require_signatures }}
|
|
|
|
cephx service require signatures = {{ cephx_service_require_signatures }}
|
2014-03-04 02:08:51 +08:00
|
|
|
{% else %}
|
2015-12-16 23:11:14 +08:00
|
|
|
auth cluster required = none
|
|
|
|
auth service required = none
|
|
|
|
auth client required = none
|
|
|
|
auth supported = none
|
|
|
|
{% endif %}
|
2016-03-29 06:34:08 +08:00
|
|
|
{% if not mon_containerized_deployment_with_kv %}
|
|
|
|
fsid = {{ fsid }}
|
|
|
|
{% endif %}
|
2015-12-16 23:11:14 +08:00
|
|
|
max open files = {{ max_open_files }}
|
|
|
|
osd pool default pg num = {{ pool_default_pg_num }}
|
|
|
|
osd pool default pgp num = {{ pool_default_pgp_num }}
|
|
|
|
osd pool default size = {{ pool_default_size }}
|
|
|
|
osd pool default min size = {{ pool_default_min_size }}
|
|
|
|
osd pool default crush rule = {{ pool_default_crush_rule }}
|
2014-05-01 07:24:20 +08:00
|
|
|
{% if common_single_host_mode is defined %}
|
2015-12-16 23:11:14 +08:00
|
|
|
osd crush chooseleaf type = 0
|
2014-05-01 07:24:20 +08:00
|
|
|
{% endif %}
|
2014-08-30 08:26:40 +08:00
|
|
|
{% if disable_in_memory_logs %}
|
2015-12-16 23:11:14 +08:00
|
|
|
# Disable in-memory logs
|
|
|
|
debug_lockdep = 0/0
|
|
|
|
debug_context = 0/0
|
|
|
|
debug_crush = 0/0
|
|
|
|
debug_buffer = 0/0
|
|
|
|
debug_timer = 0/0
|
|
|
|
debug_filer = 0/0
|
|
|
|
debug_objecter = 0/0
|
|
|
|
debug_rados = 0/0
|
|
|
|
debug_rbd = 0/0
|
|
|
|
debug_journaler = 0/0
|
|
|
|
debug_objectcatcher = 0/0
|
|
|
|
debug_client = 0/0
|
|
|
|
debug_osd = 0/0
|
|
|
|
debug_optracker = 0/0
|
|
|
|
debug_objclass = 0/0
|
|
|
|
debug_filestore = 0/0
|
|
|
|
debug_journal = 0/0
|
|
|
|
debug_ms = 0/0
|
|
|
|
debug_monc = 0/0
|
|
|
|
debug_tp = 0/0
|
|
|
|
debug_auth = 0/0
|
|
|
|
debug_finisher = 0/0
|
|
|
|
debug_heartbeatmap = 0/0
|
|
|
|
debug_perfcounter = 0/0
|
|
|
|
debug_asok = 0/0
|
|
|
|
debug_throttle = 0/0
|
|
|
|
debug_mon = 0/0
|
|
|
|
debug_paxos = 0/0
|
|
|
|
debug_rgw = 0/0
|
2014-08-30 08:26:40 +08:00
|
|
|
{% endif %}
|
2015-01-16 21:26:30 +08:00
|
|
|
{% if enable_debug_global %}
|
2015-12-16 23:11:14 +08:00
|
|
|
debug ms = {{ debug_global_level }}
|
2015-01-16 21:26:30 +08:00
|
|
|
{% endif %}
|
2014-08-30 08:58:27 +08:00
|
|
|
|
2014-11-10 21:50:19 +08:00
|
|
|
[client]
|
2015-12-16 23:11:14 +08:00
|
|
|
rbd cache = {{ rbd_cache }}
|
|
|
|
rbd cache writethrough until flush = true
|
|
|
|
rbd concurrent management ops = {{ rbd_concurrent_management_ops }}
|
|
|
|
admin socket = {{ rbd_client_admin_socket_path }}/$cluster-$type.$id.$pid.$cctid.asok # must be writable by QEMU and allowed by SELinux or AppArmor
|
|
|
|
log file = {{ rbd_client_log_file }} # must be writable by QEMU and allowed by SELinux or AppArmor
|
|
|
|
rbd default map options = {{ rbd_default_map_options }}
|
|
|
|
rbd default features = {{ rbd_default_features }} # sum features digits
|
|
|
|
rbd default format = {{ rbd_default_format }}
|
2014-11-10 21:50:19 +08:00
|
|
|
|
2014-03-04 02:08:51 +08:00
|
|
|
[mon]
|
2015-12-16 23:11:14 +08:00
|
|
|
mon osd down out interval = {{ mon_osd_down_out_interval }}
|
|
|
|
mon osd min down reporters = {{ mon_osd_min_down_reporters }}
|
|
|
|
mon clock drift allowed = {{ mon_clock_drift_allowed }}
|
|
|
|
mon clock drift warn backoff = {{ mon_clock_drift_warn_backoff }}
|
|
|
|
mon osd full ratio = {{ mon_osd_full_ratio }}
|
|
|
|
mon osd nearfull ratio = {{ mon_osd_nearfull_ratio }}
|
|
|
|
mon osd report timeout = {{ mon_osd_report_timeout }}
|
|
|
|
mon pg warn max per osd = {{ mon_pg_warn_max_per_osd }}
|
|
|
|
mon osd allow primary affinity = {{ mon_osd_allow_primary_affinity }}
|
|
|
|
mon pg warn max object skew = {{ mon_pg_warn_max_object_skew }}
|
2015-07-07 23:55:05 +08:00
|
|
|
|
2015-01-16 21:26:30 +08:00
|
|
|
{% if enable_debug_mon %}
|
2015-12-16 23:11:14 +08:00
|
|
|
debug mon = {{ debug_mon_level }}
|
|
|
|
debug paxos = {{ debug_mon_level }}
|
|
|
|
debug auth = {{ debug_mon_level }}
|
2015-01-16 21:26:30 +08:00
|
|
|
{% endif %}
|
2016-03-16 00:32:17 +08:00
|
|
|
{% if not mon_containerized_deployment_with_kv %}
|
2015-06-11 08:42:41 +08:00
|
|
|
{% for host in groups[mon_group_name] %}
|
2016-03-01 18:38:59 +08:00
|
|
|
{% if hostvars[host]['ansible_fqdn'] is defined and mon_use_fqdn %}
|
|
|
|
[mon.{{ hostvars[host]['ansible_fqdn'] }}]
|
|
|
|
host = {{ hostvars[host]['ansible_fqdn'] }}
|
2016-03-03 18:03:03 +08:00
|
|
|
{% elif hostvars[host]['ansible_hostname'] is defined %}
|
2015-12-16 23:11:14 +08:00
|
|
|
[mon.{{ hostvars[host]['ansible_hostname'] }}]
|
|
|
|
host = {{ hostvars[host]['ansible_hostname'] }}
|
2016-03-22 22:11:12 +08:00
|
|
|
{% endif %}
|
|
|
|
{% if monitor_interface != "interface" %}
|
|
|
|
{% include 'mon_addr_interface.j2' %}
|
|
|
|
{% else %}
|
|
|
|
{% include 'mon_addr_address.j2' %}
|
2015-12-16 23:11:14 +08:00
|
|
|
{% endif %}
|
2014-03-04 02:08:51 +08:00
|
|
|
{% endfor %}
|
2016-03-16 00:32:17 +08:00
|
|
|
{% endif %}
|
2014-03-04 02:08:51 +08:00
|
|
|
|
|
|
|
[osd]
|
2015-12-16 23:11:14 +08:00
|
|
|
osd mkfs type = {{ osd_mkfs_type }}
|
|
|
|
osd mkfs options xfs = {{ osd_mkfs_options_xfs }}
|
|
|
|
osd mount options xfs = {{ osd_mount_options_xfs }}
|
|
|
|
osd journal size = {{ journal_size }}
|
2014-03-04 02:08:51 +08:00
|
|
|
{% if cluster_network is defined %}
|
2015-12-16 23:11:14 +08:00
|
|
|
cluster_network = {{ cluster_network }}
|
2014-03-04 02:08:51 +08:00
|
|
|
{% endif %}
|
|
|
|
{% if public_network is defined %}
|
2015-12-16 23:11:14 +08:00
|
|
|
public_network = {{ public_network }}
|
|
|
|
{% endif %}
|
|
|
|
osd mon heartbeat interval = {{ osd_mon_heartbeat_interval }}
|
|
|
|
# Performance tuning
|
|
|
|
filestore merge threshold = {{ filestore_merge_threshold }}
|
|
|
|
filestore split multiple = {{ filestore_split_multiple }}
|
|
|
|
osd op threads = {{ osd_op_threads }}
|
|
|
|
filestore op threads = {{ filestore_op_threads }}
|
|
|
|
filestore max sync interval = {{ filestore_max_sync_interval }}
|
2016-02-20 05:06:12 +08:00
|
|
|
{% if filestore_xattr_use_omap != None %}
|
|
|
|
filestore xattr use omap = {{ filestore_xattr_use_omap }}
|
|
|
|
{% elif osd_mkfs_type == "ext4" %}
|
|
|
|
filestore xattr use omap = true
|
|
|
|
{# else, default is false #}
|
|
|
|
{% endif %}
|
2015-12-16 23:11:14 +08:00
|
|
|
osd max scrubs = {{ osd_max_scrubs }}
|
2015-12-08 03:18:23 +08:00
|
|
|
{% if ceph_stable_release not in ['argonaut','bobtail','cuttlefish','dumpling','emperor','firefly','giant'] %}
|
2015-12-16 23:11:14 +08:00
|
|
|
osd scrub begin hour = {{ osd_scrub_begin_hour }}
|
|
|
|
osd scrub end hour = {{ osd_scrub_end_hour }}
|
|
|
|
{% endif %}
|
|
|
|
# Recovery tuning
|
|
|
|
osd recovery max active = {{ osd_recovery_max_active }}
|
|
|
|
osd max backfills = {{ osd_max_backfills }}
|
|
|
|
osd recovery op priority = {{ osd_recovery_op_priority }}
|
|
|
|
osd recovery max chunk = {{ osd_recovery_max_chunk }}
|
|
|
|
osd recovery threads = {{ osd_recovery_threads }}
|
|
|
|
osd objectstore = {{ osd_objectstore }}
|
|
|
|
osd crush update on start = {{ osd_crush_update_on_start }}
|
2015-01-16 21:26:30 +08:00
|
|
|
{% if enable_debug_osd %}
|
2015-12-16 23:11:14 +08:00
|
|
|
debug osd = {{ debug_osd_level }}
|
|
|
|
debug filestore = {{ debug_osd_level }}
|
|
|
|
debug journal = {{ debug_osd_level }}
|
|
|
|
debug monc = {{ debug_osd_level }}
|
|
|
|
{% endif %}
|
|
|
|
# Deep scrub impact
|
|
|
|
osd scrub sleep = {{ osd_scrub_sleep }}
|
|
|
|
osd disk thread ioprio class = {{ osd_disk_thread_ioprio_class }}
|
|
|
|
osd disk thread ioprio priority = {{ osd_disk_thread_ioprio_priority }}
|
|
|
|
osd scrub chunk max = {{ osd_scrub_chunk_max }}
|
|
|
|
osd deep scrub stride = {{ osd_deep_scrub_stride }}
|
2014-08-30 08:58:27 +08:00
|
|
|
|
2015-07-02 17:08:59 +08:00
|
|
|
{% if groups[mds_group_name] is defined %}
|
2015-06-11 08:42:41 +08:00
|
|
|
{% for host in groups[mds_group_name] %}
|
2016-03-01 18:38:59 +08:00
|
|
|
{% if hostvars[host]['ansible_fqdn'] is defined and mds_use_fqdn %}
|
|
|
|
[mds.{{ hostvars[host]['ansible_fqdn'] }}]
|
|
|
|
host = {{ hostvars[host]['ansible_fqdn'] }}
|
2016-03-03 18:03:03 +08:00
|
|
|
{% elif hostvars[host]['ansible_hostname'] is defined %}
|
2015-12-16 23:11:14 +08:00
|
|
|
[mds.{{ hostvars[host]['ansible_hostname'] }}]
|
|
|
|
host = {{ hostvars[host]['ansible_hostname'] }}
|
|
|
|
{% endif %}
|
2014-03-04 02:08:51 +08:00
|
|
|
{% endfor %}
|
2016-03-03 18:03:03 +08:00
|
|
|
{% endif %}
|
2015-12-16 23:11:14 +08:00
|
|
|
{% if enable_debug_mds %}
|
|
|
|
debug mds = {{ debug_mds_level }}
|
|
|
|
debug mds balancer = {{ debug_mds_level }}
|
|
|
|
debug mds log = {{ debug_mds_level }}
|
|
|
|
debug mds migrator = {{ debug_mds_level }}
|
|
|
|
{% endif %}
|
2014-03-06 20:54:37 +08:00
|
|
|
|
2015-07-06 23:36:45 +08:00
|
|
|
{% if groups[rgw_group_name] is defined %}
|
2015-06-11 08:42:41 +08:00
|
|
|
{% for host in groups[rgw_group_name] %}
|
2014-03-20 19:14:43 +08:00
|
|
|
{% if hostvars[host]['ansible_hostname'] is defined %}
|
2015-06-12 17:47:08 +08:00
|
|
|
[client.rgw.{{ hostvars[host]['ansible_hostname'] }}]
|
2015-12-16 23:11:14 +08:00
|
|
|
{% if radosgw_dns_name is defined %}
|
|
|
|
rgw dns name = {{ radosgw_dns_name }}
|
|
|
|
{% endif %}
|
|
|
|
host = {{ hostvars[host]['ansible_hostname'] }}
|
2016-03-29 21:37:31 +08:00
|
|
|
keyring = /var/lib/ceph/radosgw/{{ cluster }}-rgw.{{ hostvars[host]['ansible_hostname'] }}/keyring
|
2015-12-16 23:11:14 +08:00
|
|
|
rgw socket path = /tmp/radosgw-{{ hostvars[host]['ansible_hostname'] }}.sock
|
2016-03-29 21:37:31 +08:00
|
|
|
log file = /var/log/ceph/{{ cluster }}-rgw-{{ hostvars[host]['ansible_hostname'] }}.log
|
|
|
|
rgw data = /var/lib/ceph/radosgw/{{ cluster }}-rgw.{{ hostvars[host]['ansible_hostname'] }}
|
2015-12-16 23:11:14 +08:00
|
|
|
{% if radosgw_frontend == 'civetweb' %}
|
|
|
|
rgw frontends = civetweb port={{ radosgw_civetweb_port }}
|
|
|
|
{% endif %}
|
|
|
|
{% if radosgw_keystone %}
|
|
|
|
rgw keystone url = {{ radosgw_keystone_url }}
|
|
|
|
rgw keystone admin token = {{ radosgw_keystone_admin_token }}
|
|
|
|
rgw keystone accepted roles = {{ radosgw_keystone_accepted_roles }}
|
|
|
|
rgw keystone token cache size = {{ radosgw_keystone_token_cache_size }}
|
|
|
|
rgw keystone revocation interval = {{ radosgw_keystone_revocation_internal }}
|
|
|
|
rgw s3 auth use keystone = {{ radosgw_s3_auth_use_keystone }}
|
|
|
|
nss db path = {{ radosgw_nss_db_path }}
|
|
|
|
{% endif %}
|
2014-03-20 19:14:43 +08:00
|
|
|
{% endif %}
|
2014-03-19 19:40:02 +08:00
|
|
|
{% endfor %}
|
2014-03-06 20:54:37 +08:00
|
|
|
{% endif %}
|
2015-03-23 22:08:58 +08:00
|
|
|
|
2015-07-02 17:08:59 +08:00
|
|
|
{% if groups[restapi_group_name] is defined %}
|
2015-03-23 22:08:58 +08:00
|
|
|
[client.restapi]
|
2016-03-22 22:11:12 +08:00
|
|
|
{% if restapi_interface != "interface" %}
|
|
|
|
{% include 'client_restapi_interface.j2' %}
|
|
|
|
{% else %}
|
|
|
|
{% include 'client_restapi_address.j2' %}
|
|
|
|
{% endif %}
|
2015-12-16 23:11:14 +08:00
|
|
|
restapi base url = {{ restapi_base_url }}
|
|
|
|
restapi log level = {{ restapi_log_level }}
|
|
|
|
keyring = /var/lib/ceph/restapi/ceph-restapi/keyring
|
|
|
|
log file = /var/log/ceph/ceph-restapi.log
|
2015-03-23 22:08:58 +08:00
|
|
|
{% endif %}
|