Version information
This version is compatible with:
- Puppet Enterprise 2019.8.x, 2019.7.x, 2019.5.x, 2019.4.x, 2019.3.x, 2019.2.x, 2019.1.x, 2019.0.x, 2018.1.x, 2017.3.x, 2017.2.x, 2016.4.x
- Puppet >= 4.10.1 < 7.0.0
- , , , ,
Tasks:
- reload
Start using this module
Add this module to your Puppetfile:
mod 'silug-zram', '1.0.2'
Learn more about managing modules with a PuppetfileDocumentation
zram
Table of Contents
- Overview
- Module Description - What the module does and why it is useful
- Setup - The basics of getting started with zram
- Usage - Configuration options and additional functionality
- Reference - An under-the-hood peek at what the module is doing and how
- Limitations - OS compatibility, etc.
- Development - Guide for contributing to the module
Overview
This module configures zram swap using udev rules (no init scripts or systemd units needed).
Module Description
Want to know more about zram? Read the Linux kernel documentation.
Setup
What zram affects
Creates the following files:
- /lib/udev/zram
- /etc/udev/rules.d/01-zram.rules
- /etc/modprobe.d/zram.conf
Finally, it loads the zram module.
Setup Requirements
This module requires puppetlabs-stdlib and camptocamp-kmod.
Beginning with zram
Make sure you are using a kernel that includes the zram module.
Usage
class { 'zram': }
Reference
This module accepts the following parameters:
-
numdevices
Number of zram devices. Defaults to the number of processors ($::processorcount). -
disksize
Size of zram devices. Defaults to half of memory divided by numdevices.
Limitations
This module has been tested on Ubuntu 16.04 and Debian Jessie (Raspbian).
Development
Send me a pull request on GitHub.
Reference
Table of Contents
Classes
zram
: Configures and loads zram kernel modulezram::config
: Configuration for the zram modulezram::load
: Loads the zram kernel module
Tasks
reload
: Reloads the zram kernel module
Classes
zram
zram
This module configures zram using udev rules (no init scripts or systemd units needed).
Examples
class { 'zram': }
Parameters
The following parameters are available in the zram
class.
numdevices
Data type: Integer
Number of zram devices. Defaults to the number of processors ($::processorcount).
Default value: $facts['processorcount']
disksize
Data type: Integer
Size of zram devices. Defaults to half of memory divided by numdevices.
Default value: (
zram::config
zram::config
Configuration for the zram module. This can only be called from the main zram class.
Examples
include zram::config
zram::load
zram::load
Loads the zram kernel module. Intended to be called from the main zram class.
Examples
include zram::load
Tasks
reload
Reloads the zram kernel module
Supports noop? true
Parameters
verbose
Data type: Optional[Boolean]
Enable verbose output
What are tasks?
Modules can contain tasks that take action outside of a desired state managed by Puppet. It’s perfect for troubleshooting or deploying one-off changes, distributing scripts to run across your infrastructure, or automating changes that need to happen in a particular order as part of an application deployment.
Tasks in this module release
Dependencies
- puppetlabs-stdlib (>= 4.25.0 < 7.0.0)
- camptocamp-kmod (>= 2.1.0 < 3.0.0)
- puppetlabs-augeas_core (>= 1.0.0 < 2.0.0)