From 82aec38a714ccdc925f41fc6e71cc8641938eede Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Han?= Date: Mon, 16 May 2016 17:38:02 +0200 Subject: [PATCH] ceph-rgw: implement num_threads for civetweb MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Sébastien Han --- group_vars/all.sample | 2 ++ group_vars/clients.sample | 4 +++- roles/ceph-common/defaults/main.yml | 1 + roles/ceph-common/templates/ceph.conf.j2 | 2 +- 4 files changed, 7 insertions(+), 2 deletions(-) diff --git a/group_vars/all.sample b/group_vars/all.sample index aa2a9a7d9..057f88488 100644 --- a/group_vars/all.sample +++ b/group_vars/all.sample @@ -26,6 +26,7 @@ dummy: #mds_group_name: mdss #restapi_group_name: restapis #rbdmirror_group_name: rbdmirrors +#client_group_name: clients # If check_firewall is true, then ansible will try to determine if the # Ceph ports are blocked by a firewall. If the machine running ansible @@ -267,6 +268,7 @@ dummy: #radosgw_frontend: civetweb # supported options are 'apache' or 'civetweb', also edit roles/ceph-rgw/defaults/main.yml #radosgw_civetweb_port: 8080 # on Infernalis we get: "set_ports_option: cannot bind to 80: 13 (Permission denied)" #radosgw_civetweb_bind_ip: "{{ ansible_default_ipv4.address }}" +#radosgw_civetweb_num_threads: 50 #radosgw_keystone: false # activate OpenStack Keystone options full detail here: http://ceph.com/docs/master/radosgw/keystone/ #radosgw_keystone_url: # url:admin_port ie: http://192.168.0.1:35357 #radosgw_keystone_admin_token: password diff --git a/group_vars/clients.sample b/group_vars/clients.sample index b3bca0822..1bd4f6003 100644 --- a/group_vars/clients.sample +++ b/group_vars/clients.sample @@ -16,7 +16,9 @@ dummy: #user_config: false #pools: # - { name: test, pgs: "{{ pool_default_pg_num }}" } +# - { name: test2, pgs: "{{ pool_default_pg_num }}" } #keys: -# - { name: client.test, value: "mon 'allow r' osd 'allow class-read object_prefix rbd_children, allow rwx pool={{ pools.name }}'" } +# - { name: client.test, value: "mon 'allow r' osd 'allow class-read object_prefix rbd_children, allow rwx pool=test'" } +# - { name: client.test2, value: "mon 'allow r' osd 'allow class-read object_prefix rbd_children, allow rwx pool=test2'" } diff --git a/roles/ceph-common/defaults/main.yml b/roles/ceph-common/defaults/main.yml index 4122a4c70..32dbaa8df 100644 --- a/roles/ceph-common/defaults/main.yml +++ b/roles/ceph-common/defaults/main.yml @@ -260,6 +260,7 @@ mds_use_fqdn: false # if set to true, the MDS name used will be the fqdn in the radosgw_frontend: civetweb # supported options are 'apache' or 'civetweb', also edit roles/ceph-rgw/defaults/main.yml radosgw_civetweb_port: 8080 # on Infernalis we get: "set_ports_option: cannot bind to 80: 13 (Permission denied)" radosgw_civetweb_bind_ip: "{{ ansible_default_ipv4.address }}" +radosgw_civetweb_num_threads: 50 radosgw_keystone: false # activate OpenStack Keystone options full detail here: http://ceph.com/docs/master/radosgw/keystone/ #radosgw_keystone_url: # url:admin_port ie: http://192.168.0.1:35357 radosgw_keystone_admin_token: password diff --git a/roles/ceph-common/templates/ceph.conf.j2 b/roles/ceph-common/templates/ceph.conf.j2 index e81c21a62..fa5a8db06 100644 --- a/roles/ceph-common/templates/ceph.conf.j2 +++ b/roles/ceph-common/templates/ceph.conf.j2 @@ -81,7 +81,7 @@ rgw socket path = /tmp/radosgw-{{ hostvars[host]['ansible_hostname'] }}.sock log file = /var/log/ceph/{{ cluster }}-rgw-{{ hostvars[host]['ansible_hostname'] }}.log rgw data = /var/lib/ceph/radosgw/{{ cluster }}-rgw.{{ hostvars[host]['ansible_hostname'] }} {% if radosgw_frontend == 'civetweb' %} -rgw frontends = civetweb port={{ radosgw_civetweb_bind_ip }}:{{ radosgw_civetweb_port }} +rgw frontends = civetweb port={{ radosgw_civetweb_bind_ip }}:{{ radosgw_civetweb_port }} num_threads={{ radosgw_civetweb_num_threads }} {% endif %} {% if radosgw_keystone %} rgw keystone url = {{ radosgw_keystone_url }}