Skip to content

Latest commit

 

History

History
472 lines (262 loc) · 8.48 KB

File metadata and controls

472 lines (262 loc) · 8.48 KB

Reference

Table of Contents

Classes

Defined types

  • zfs::scrub: Set up a zpool scrub cron entry.
  • zfs::zed::zedlet: Enables either a packaged or custom ZFS Event Daemon "zedlet". Not specifying either $content or $source results in the zedlet being sym

Tasks

  • scrub: Allows you to initiate the scrub of a zpool

Classes

zfs

Installs basic ZFS kernel and userland support.

  • See also
    • puppet_classes::zfs::zed
      • zfs::zed
    • puppet_defined_types::zfs::scrub
      • zfs::scrub

Examples

Declaring the class
include zfs
Tuning the ZFS ARC
class { 'zfs':
  zfs_arc_max => to_bytes('256 M'),
  zfs_arc_min => to_bytes('128 M'),
}

Parameters

The following parameters are available in the zfs class:

conf_dir

Data type: Stdlib::Absolutepath

Top-level configuration directory, usually /etc/zfs.

kmod_type

Data type: Enum['dkms', 'kabi']

Whether to use DKMS kernel packages or ones built to match the running kernel (only applies to RHEL platforms).

manage_repo

Data type: Boolean

Whether to setup and manage external package repositories.

package_name

Data type: Variant[String, Array[String, 1]]

The name of the top-level metapackage that installs ZFS support.

service_manage

Data type: Boolean

Whether to manage the various ZFS services.

zfs_arc_max

Data type: Optional[Integer[0]]

Maximum size of the ARC in bytes.

zfs_arc_min

Data type: Optional[Integer[0]]

Minimum size of the ARC in bytes.

zfs::config

The zfs::config class.

zfs::install

The zfs::install class.

zfs::service

The zfs::service class.

zfs::zed

Installs the ZFS Event Daemon.

  • Since 2.0.0

  • See also

    • puppet_classes::zfs
      • zfs
    • puppet_defined_types::zfs::zed::zedlet
      • zfs::zed::zedlet

Examples

Declaring the class
include zfs
include zfs::zed

Parameters

The following parameters are available in the zfs::zed class:

conf_dir

Data type: Stdlib::Absolutepath

Configuration directory, usually ${zfs::conf_dir}/zed.d.

debug_log

Data type: Optional[Stdlib::Absolutepath]

email_addrs

Data type: Optional[Array[String, 1]]

email_opts

Data type: Optional[String]

email_prog

Data type: Optional[String]

lock_dir

Data type: Optional[Stdlib::Absolutepath]

notify_interval_secs

Data type: Optional[Integer[0]]

notify_verbose

Data type: Optional[Boolean]

package_name

Data type: Optional[String]

The name of the package to install if not installed already by the ZFS class.

pushbullet_access_token

Data type: Optional[String]

pushbullet_channel_tag

Data type: Optional[String]

run_dir

Data type: Optional[Stdlib::Absolutepath]

service_manage

Data type: Boolean

Whether to manage the service.

service_name

Data type: String

Name of the service.

spare_on_checksum_errors

Data type: Optional[Integer[1]]

spare_on_io_errors

Data type: Optional[Integer[1]]

syslog_priority

Data type: Optional[String]

syslog_tag

Data type: Optional[String]

use_enclosure_leds

Data type: Optional[Boolean]

zedlet_dir

Data type: Stdlib::Absolutepath

Path to package-provided zedlets.

zedlets

Data type: Hash[String, Hash]

Hash of zedlet resources to create.

zfs::zed::config

The zfs::zed::config class.

zfs::zed::install

The zfs::zed::install class.

zfs::zed::service

The zfs::zed::service class.

Defined types

zfs::scrub

Set up a zpool scrub cron entry.

  • Since 2.2.0

  • See also

    • puppet_classes::zfs
      • zfs

Examples

Scrub a zpool once a month
include zfs

zfs::scrub { 'test':
  hour     => '1',
  minute   => '0',
  month    => '*',
  monthday => '1',
  weekday  => '*',
}

Parameters

The following parameters are available in the zfs::scrub defined type:

zpool

Data type: String

The name of the zpool.

Default value: $title

hour

Data type: Any

See the cron resource type.

minute

Data type: Any

See the cron resource type.

month

Data type: Any

See the cron resource type.

monthday

Data type: Any

See the cron resource type.

weekday

Data type: Any

See the cron resource type.

user

Data type: String

See the cron resource type.

Default value: 'root'

zfs::zed::zedlet

Enables either a packaged or custom ZFS Event Daemon "zedlet".

Not specifying either $content or $source results in the zedlet being symlinked from the "installed zedlets" directory.

  • Since 2.0.0

  • See also

    • puppet_classes::zfs::zed
      • zfs::zed

Examples

Enabling a packaged zedlet
zfs::zed::zedlet { 'scrub.finish-notify.sh': }
Enabling a custom zedlet
zfs::zed::zedlet { 'scrub.finish-notify.sh':
  source => 'puppet:///example/scrub.finish-notify.sh',
}

Parameters

The following parameters are available in the zfs::zed::zedlet defined type:

content

Data type: Optional[String]

Content of custom zedlet

Default value: undef

source

Data type: Optional[String]

Source of custom zedlet

Default value: undef

zedlet

Data type: String

The filename for the zedlet

Default value: $title

Tasks

scrub

Allows you to initiate the scrub of a zpool

Supports noop? false

Parameters

zpool

Data type: String[1]

Name of the zpool