Allow customization of OSDs journal size via class param
Customization of the journal file/dev size is recommended by the Ceph documentation as it depends on drives speed and sync interval. Change-Id: Iaa32aca538b0bcad544641dcd7b67448fb4cada5
This commit is contained in:
parent
f6206a15cc
commit
6cb9a00898
|
@ -7,6 +7,7 @@ ceph::profile::params::fsid: '4b5c8c0a-ff60-454b-a1b4-9747aa737d19'
|
|||
ceph::profile::params::authentication_type: 'cephx'
|
||||
ceph::profile::params::mon_initial_members: 'first, second'
|
||||
ceph::profile::params::mon_host: '10.11.12.2:6789, 10.11.12.3:6789'
|
||||
ceph::profile::params::osd_journal_size: '4096'
|
||||
ceph::profile::params::osd_pool_default_pg_num: '200'
|
||||
ceph::profile::params::osd_pool_default_pgp_num: '200'
|
||||
ceph::profile::params::osd_pool_default_size: '2'
|
||||
|
|
|
@ -35,6 +35,9 @@
|
|||
# [*keyring*] The location of the keyring retrieved by default
|
||||
# Optional. Defaults to /etc/ceph/keyring.
|
||||
#
|
||||
# [*osd_journal_size*] The size of the journal file/device.
|
||||
# Optional. Integer. Default provided by Ceph.
|
||||
#
|
||||
# [*osd_pool_default_pg_num*] The default number of PGs per pool.
|
||||
# Optional. Integer. Default provided by Ceph.
|
||||
#
|
||||
|
@ -94,6 +97,7 @@ class ceph (
|
|||
$ensure = present,
|
||||
$authentication_type = 'cephx',
|
||||
$keyring = undef,
|
||||
$osd_journal_size = undef,
|
||||
$osd_pool_default_pg_num = undef,
|
||||
$osd_pool_default_pgp_num = undef,
|
||||
$osd_pool_default_size = undef,
|
||||
|
@ -139,6 +143,7 @@ class ceph (
|
|||
'global/sign_messages': value => $sign_messages;
|
||||
'global/cluster_network': value => $cluster_network;
|
||||
'global/public_network': value => $public_network;
|
||||
'osd/osd_journal_size': value => $osd_journal_size;
|
||||
}
|
||||
|
||||
if $authentication_type == 'cephx' {
|
||||
|
|
|
@ -33,6 +33,7 @@ class ceph::profile::base {
|
|||
class { '::ceph':
|
||||
fsid => $ceph::profile::params::fsid,
|
||||
authentication_type => $ceph::profile::params::authentication_type,
|
||||
osd_journal_size => $ceph::profile::params::osd_journal_size,
|
||||
osd_pool_default_pg_num => $ceph::profile::params::osd_pool_default_pg_num,
|
||||
osd_pool_default_pgp_num => $ceph::profile::params::osd_pool_default_pgp_num,
|
||||
osd_pool_default_size => $ceph::profile::params::osd_pool_default_size,
|
||||
|
|
|
@ -38,6 +38,9 @@
|
|||
# individually through ceph::mon.
|
||||
# Optional. String like e.g. 'a, b, c'.
|
||||
#
|
||||
# [*osd_journal_size*] The size of the journal file/device.
|
||||
# Optional. Integer. Default provided by Ceph.
|
||||
#
|
||||
# [*osd_pool_default_pg_num*] The default number of PGs per pool.
|
||||
# Optional. Integer. Default provided by Ceph.
|
||||
#
|
||||
|
@ -95,6 +98,7 @@ class ceph::profile::params (
|
|||
$authentication_type = undef,
|
||||
$mon_initial_members = undef,
|
||||
$mon_host = undef,
|
||||
$osd_journal_size = undef,
|
||||
$osd_pool_default_pg_num = undef,
|
||||
$osd_pool_default_pgp_num = undef,
|
||||
$osd_pool_default_size = undef,
|
||||
|
|
|
@ -47,6 +47,7 @@ describe 'ceph' do
|
|||
it { is_expected.to_not contain_ceph_config('global/sign_messages').with_value('true') }
|
||||
it { is_expected.to_not contain_ceph_config('global/cluster_network').with_value('10.0.0.0/24') }
|
||||
it { is_expected.to_not contain_ceph_config('global/public_network').with_value('192.168.0.0/24') }
|
||||
it { is_expected.to_not contain_ceph_config('osd/osd_journal_size').with_value('4096') }
|
||||
it { is_expected.to contain_ceph_config('global/auth_cluster_required').with_value('cephx') }
|
||||
it { is_expected.to contain_ceph_config('global/auth_service_required').with_value('cephx') }
|
||||
it { is_expected.to contain_ceph_config('global/auth_client_required').with_value('cephx') }
|
||||
|
@ -63,6 +64,7 @@ describe 'ceph' do
|
|||
:fsid => 'd5252e7d-75bc-4083-85ed-fe51fa83f62b',
|
||||
:authentication_type => 'none',
|
||||
:keyring => '/usr/local/ceph/etc/keyring',
|
||||
:osd_journal_size => '1024',
|
||||
:osd_pool_default_pg_num => '256',
|
||||
:osd_pool_default_pgp_num => '256',
|
||||
:osd_pool_default_size => '2',
|
||||
|
@ -102,6 +104,7 @@ describe 'ceph' do
|
|||
it { is_expected.to contain_ceph_config('global/sign_messages').with_value('false') }
|
||||
it { is_expected.to contain_ceph_config('global/cluster_network').with_value('10.0.0.0/24') }
|
||||
it { is_expected.to contain_ceph_config('global/public_network').with_value('192.168.0.0/24') }
|
||||
it { is_expected.to contain_ceph_config('osd/osd_journal_size').with_value('1024') }
|
||||
it { is_expected.to_not contain_ceph_config('global/auth_cluster_required').with_value('cephx') }
|
||||
it { is_expected.to_not contain_ceph_config('global/auth_service_required').with_value('cephx') }
|
||||
it { is_expected.to_not contain_ceph_config('global/auth_client_required').with_value('cephx') }
|
||||
|
|
|
@ -7,6 +7,7 @@ ceph::profile::params::fsid: '4b5c8c0a-ff60-454b-a1b4-9747aa737d19'
|
|||
ceph::profile::params::authentication_type: 'cephx'
|
||||
ceph::profile::params::mon_initial_members: 'first, second'
|
||||
ceph::profile::params::mon_host: '10.11.12.2:6789, 10.11.12.3:6789'
|
||||
ceph::profile::params::osd_journal_size: '4096'
|
||||
ceph::profile::params::osd_pool_default_pg_num: '200'
|
||||
ceph::profile::params::osd_pool_default_pgp_num: '200'
|
||||
ceph::profile::params::osd_pool_default_size: '2'
|
||||
|
|
Loading…
Reference in New Issue