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

chumask: fix issue where it only works with standalone worker #4836

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

daipom
Copy link
Contributor

@daipom daipom commented Feb 21, 2025

Which issue(s) this PR fixes:

What this PR does / why we need it:
Fix #3671 (88a7260)

After #3671, the value of chumask passed to ServerEngine was always nil.
The chumask value was being used only when standalone. It appears to be unintentional.

This fixes it.

  • By default, 0 as chumask is passed to ServerEngine.
  • If specifying --umask option, that value is passed.
  • This chumask value is applied when using daemonize.
    • When not using daemonize, the value is not used.
    • This is the specification of ServerEngine.

Specification change:
(Just undo the specification that #3671 unintentionally changed.)

  • This changes the default umask when using daemonize.
    • fluent-package (RPM/DEB), for example.
    • Before: system default (nil for ServerEngine)
    • After: 0

Docs Changes:
Not needed.
(There is not enough information on https://docs.fluentd.org/deployment/command-line-option. It would be good to add more information.)

Release Note:

  • Fixed a bug where the default umask was not set to 0 when using --daemon (td-agent, fluent-package) since v1.14.6.
  • --umask command line option: Fixed so that it is applied when Fluentd runs with --daemon (fluent-package) as well as when Fluentd runs with --no-supervisor.

Fix fluent#3671 (88a7260)

After fluent#3671, the value of `chumask` passed to ServerEngine was
always `nil`.
The `chumask` value was being used only when standalone.
It appears to be unintentional.

This fixes it.

* By default, `0` as `chumask` is passed to ServerEngine.
* If specifying `--umask` option, that value is passed.
* This `chumask` value is applied when using `daemonize`.
  * When not using `daemonize`, the value is not used.
  * This is the specification of ServerEngine.

Specification change:
(Just undo the specification that fluent#3671 unintentionally changed.)

* This changes the default `umask` when using `daemonize`.
  * fluent-package (RPM/DEB), for example.
  * Before: system default (`nil` for ServerEngine)
  * After: `0`

Signed-off-by: Daijiro Fukuda <fukuda@clear-code.com>
@daipom
Copy link
Contributor Author

daipom commented Feb 21, 2025

It would be necessary for us to solve this issue before making the following enhancement:

Copy link
Contributor

@Watson1978 Watson1978 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants