salt.states.kmod
Loading and unloading of kernel modules
The Kernel modules on a system can be managed cleanly with the kmod state module:
add_kvm: kmod.present: - name: kvm_amd remove_beep: kmod.absent: - name: pcspkr
Multiple modules can be specified for both kmod.present and kmod.absent.
add_sound: kmod.present: - mods: - snd_hda_codec_hdmi - snd_hda_codec - snd_hwdep - snd_hda_core - snd_pcm - snd_timer - snd
-
Verify that the named kernel module is not loaded
- name
-
The name of the kernel module to verify is not loaded
- persist
-
Remove module from
/etc/modules
- comment
-
Comment out module in
/etc/modules
rather than remove it - mods
-
A list of modules to verify are unloaded. If this argument is used, the
name
argument, although still required, is not used, and becomes a placeholderNew in version 2016.3.0.
salt.states.kmod.absent(name, persist=False, comment=True, mods=None)
-
Ensure that the specified kernel module is loaded
- name
-
The name of the kernel module to verify is loaded
- persist
-
Also add module to
/etc/modules
- mods
-
A list of modules to verify are loaded. If this argument is used, the
name
argument, although still required, is not used, and becomes a placeholderNew in version 2016.3.0.
salt.states.kmod.present(name, persist=False, mods=None)
© 2021 SaltStack.
Licensed under the Apache License, Version 2.0.
https://docs.saltproject.io/en/latest/ref/states/all/salt.states.kmod.html