Forge Home

zram

Configures and loads zram kernel module

8,832 downloads

621 latest version

5.0 quality score

We run a couple of automated
scans to help you access a
module's quality. Each module is
given a score based on how well
the author has formatted their
code and documentation and
modules are also checked for
malware using VirusTotal.

Please note, the information below
is for guidance only and neither of
these methods should be considered
an endorsement by Puppet.

Version information

  • 1.0.4 (latest)
  • 1.0.3
  • 1.0.2
  • 1.0.1
  • 1.0.0
  • 0.2.0
released Feb 28th 2022
This version is compatible with:
  • Puppet Enterprise 2023.2.x, 2023.1.x, 2023.0.x, 2021.7.x, 2021.6.x, 2021.5.x, 2021.4.x, 2021.3.x, 2021.2.x, 2021.1.x, 2021.0.x, 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 < 8.0.0
  • , , , , , ,
Tasks:
  • reload

Start using this module

  • r10k or Code Manager
  • Bolt
  • Manual installation
  • Direct download

Add this module to your Puppetfile:

mod 'silug-zram', '1.0.4'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add silug-zram
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install silug-zram --version 1.0.4

Direct download is not typically how you would use a Puppet module to manage your infrastructure, but you may want to download the module in order to inspect the code.

Download
Tags: zram

Documentation

silug/zram — version 1.0.4 Feb 28th 2022

zram

Table of Contents

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 puppet-kmod.

Beginning with zram

Make sure you are using a kernel that includes the zram module.

Usage

class { 'zram': }

Reference

The zram class accepts the following parameters:

  • numdevices Number of zram devices. Defaults to the number of processors ($facts['processorcount']).

  • disksize Size of zram devices. Defaults to half of memory divided by numdevices.

See REFERENCE.md for more details.

Limitations

This module has been tested on a number of systems. (See metadata.json for a full list.) It should work on any Linux distribution that includes the zram kernel module.

Development

Send me a pull request on GitHub.