Skip to content
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

updating dir mode on every run. #314

Closed
wants to merge 1 commit into from
Closed

updating dir mode on every run. #314

wants to merge 1 commit into from

Conversation

sbotman
Copy link
Contributor

@sbotman sbotman commented Nov 6, 2014

This update makes it more idempotent.

server_source line 146)
[2014-11-06T21:38:43+00:00] INFO: directory[/var/log/nagios] mode changed to 755
- change mode from '0751' to '0755'
- restore selinux security context
* directory[/var/log/nagios] action create
.......
default line 205)
[2014-11-06T21:38:43+00:00] INFO: directory[/var/log/nagios] mode changed to 751
- change mode from '0755' to '0751'
- restore selinux security context
* directory[/var/log/nagios/rw] action create

This update makes it more idempotent.

server_source line 146)
       [2014-11-06T21:38:43+00:00] INFO: directory[/var/log/nagios] mode changed to 755
           - change mode from '0751' to '0755'
           - restore selinux security context
         * directory[/var/log/nagios] action create
.......
default line 205)
       [2014-11-06T21:38:43+00:00] INFO: directory[/var/log/nagios] mode changed to 751
           - change mode from '0755' to '0751'
           - restore selinux security context
         * directory[/var/log/nagios/rw] action create
@sbotman
Copy link
Contributor Author

sbotman commented Nov 6, 2014

See now that this is because the state and log dir point to the same location by default but have different mode settings and are only used on redhat / centos
default['nagios']['log_dir'] = '/var/log/nagios'
default['nagios']['cache_dir'] = '/var/log/nagios'
default['nagios']['state_dir'] = '/var/log/nagios'
Hence the problem does not exist on ubuntu.
Will do some extra testing on this and see if it's better to point one of the directories to another location by default.

@tas50
Copy link
Contributor

tas50 commented Nov 6, 2014

Using the same directories for multiple things seems like a bad idea. It's probably best to find different directories for those things. How is this handled on other OS releases?

@sbotman
Copy link
Contributor Author

sbotman commented Jan 11, 2015

Still need to verify this one on other os releases, but I think it's only related to centos. Will come back to this one soon...

@sbotman sbotman closed this Aug 21, 2015
@lock
Copy link

lock bot commented Jul 24, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Jul 24, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants