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

[FEATURE REQUEST] State module to manage SysFS entries #60154

Closed
piterpunk opened this issue May 7, 2021 · 0 comments · Fixed by #60155
Closed

[FEATURE REQUEST] State module to manage SysFS entries #60154

piterpunk opened this issue May 7, 2021 · 0 comments · Fixed by #60155
Assignees
Labels
Feature new functionality including changes to functionality and code refactors, etc.
Milestone

Comments

@piterpunk
Copy link

Is your feature request related to a problem? Please describe.
There are some Linux kernel configuration that are managed through SysFS objects, it's not uncommon to need change those configurations, like disable transparent hugepages, or change disks I/O scheduler, or to offline some CPUs.

Saltstack provides the sysfs execution module, but not a state module so I could set and keep the configurations in the desired state.

Describe the solution you'd like
I would like a state module so I can specify something like:

bus/cpu/devices/cpu1/online:
  sysfs.present:
    - value: 0

And Salt will check the cpu1 state, do nothing if it was already disabled and disable it if enabled.

Describe alternatives you've considered
I considered read the SysFS file contents , and use its results to trigger another state that runs sysfs.write or directly echoing the value to the file using cmd.run.

Please Note
If this feature request would be considered a substantial change or addition, this should go through a SEP process here https://github.com/saltstack/salt-enhancement-proposals, instead of a feature request.

@piterpunk piterpunk added Feature new functionality including changes to functionality and code refactors, etc. needs-triage labels May 7, 2021
@sagetherage sagetherage added this to the Approved milestone May 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature new functionality including changes to functionality and code refactors, etc.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants