-
-
Notifications
You must be signed in to change notification settings - Fork 451
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set dbpath_fix to false by default #347
Conversation
Debian Jessie mongodb/journal/lsn file with mongodb:nogroup permissions always calls dbpath_fix -> mongodb service restart. |
I can confirm this is a thing also in Ubuntu trusty. |
FYI |
boolean false should fix it based on https://github.com/puppetlabs/puppetlabs-mongodb/blob/2cef851409852134f00153eb9bb171179f4359d7/manifests/server/config.pp#L222 But if you pass "false" as a string it won't work |
It's false by default, I do not pass additional parameters for dbpath_fix
…On Tue, Feb 21, 2017 at 6:11 PM, Alex Schultz ***@***.***> wrote:
boolean false should fix it based on https://github.com/puppetlabs/
puppetlabs-mongodb/blob/2cef851409852134f00153eb9bb171
179f4359d7/manifests/server/config.pp#L222 But if you pass "false" as a
string it won't work
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#347 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AHr1gsh9nE_QYthfLOLH4zXBI6BavObhks5rewy5gaJpZM4K4wvb>
.
|
I am afraid it is tru be default https://github.com/puppetlabs/puppetlabs-mongodb/blob/2cef851409852134f00153eb9bb171179f4359d7/manifests/params.pp#L15 making it false fixed it for me |
Related issue: https://tickets.puppetlabs.com/browse/MODULES-4365 |
I suggest adding a test to spec/classes/server_config_spec.rb to ensure the |
I think this makes sense. Would you mind rebasing this to fix the merge conflict? A test would also be nice. |
e36da9a
to
f99c25c
Compare
rebased and added a test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would you mind expanding the 'with defaults' testcase to add is_expected.not_to contain_exec
? Other than that I think it's good to go
spec/classes/server_config_spec.rb
Outdated
:command => 'chown -R foo:bar /var/lib/mongo', | ||
:path => ['/usr/bin', '/bin'], | ||
:onlyif => "find /var/lib/mongo -not -user foo -o -not -group bar -print -quit | grep -q '.*'", | ||
:subscribe => "File[/var/lib/mongo]") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's better to test this with that_subscribes_to('File[/var/lib/mongo]')
since that goes through the catalog compilation.
84e8c89
to
80538cf
Compare
Comments addressed, please take a minute to review. Thanks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@mwhahaha sorry, we were waiting for some final changes during the transition to Vox. Would you mind rebasing one more time, and resolving the conflict? |
Under Xenial, the current default value of dbpath_fix set to true leads to idempotency issues because the data files may be created with the nogroup group. This can lead to puppet repeatedly fixing permissions which is not ideal. The files that are getting changed are set to 0600 so the group ownership does not help. By default, we should be setting this to false because we should not need to manage the user/group permissions with the default install provided by distrobutions.
80538cf
to
65197d9
Compare
@wyardley rebased |
Sorry, I should have rebased again. this now has some rubocop errors, but I put in a separate fix for that in #407 |
Under Xenial, the current default value of dbpath_fix set to true leads
to idempotency issues because the data files may be created with the
nogroup group. This can lead to puppet repeatedly fixing permissions
which is not ideal. The files that are getting changed are set to 0600
so the group ownership does not help. By default, we should be setting
this to false because we should not need to manage the user/group
permissions with the default install provided by distrobutions.