mount_core

Manages mounted filesystems and mount tables.

895,911 downloads

37,273 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.3.0 (latest)
  • 1.2.0
  • 1.1.0
  • 1.0.4
  • 1.0.3
  • 1.0.2
  • 1.0.1
  • 1.0.0
released Mar 6th 2024
This version is compatible with:
  • Puppet Enterprise 2025.3.x, 2025.2.x, 2025.1.x, 2023.8.x, 2023.7.x, 2023.6.x, 2023.5.x, 2023.4.x, 2023.3.x, 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
  • Puppet >= 6.0.0 < 9.0.0
  • CentOS, OracleLinux, RedHat, Scientific, Debian, Ubuntu, Fedora, macOS, SLES, Solaris, Rocky, AlmaLinux, Amazon

Start using this module

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

Add this module to your Puppetfile:

mod 'puppetlabs-mount_core', '1.3.0'
Learn more about managing modules with a Puppetfile

Add this module to your Bolt project:

bolt module add puppetlabs-mount_core
Learn more about using this module with an existing project

Manually install this module globally with Puppet module tool:

puppet module install puppetlabs-mount_core --version 1.3.0

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

Documentation

puppetlabs/mount_core — version 1.3.0 Mar 6th 2024

Reference

Table of Contents

Resource types

  • mount: Manages mounted filesystems, including putting mount information into the mount table.

Resource types

mount

The actual behavior depends on the value of the 'ensure' parameter.

Refresh: mount resources can respond to refresh events (via notify, subscribe, or the ~> arrow). If a mount receives an event from another resource and its ensure attribute is set to mounted, Puppet will try to unmount then remount that filesystem.

Autorequires: If Puppet is managing any parents of a mount resource --- that is, other mount points higher up in the filesystem --- the child mount will autorequire them.

Autobefores: If Puppet is managing any child file paths of a mount point, the mount resource will autobefore them.

Properties

The following properties are available in the mount type.

atboot

Whether to mount the mount at boot. Not all platforms support this.

blockdevice

The device to fsck. This is property is only valid on Solaris, and in most cases will default to the correct value.

device

The device providing the mount. This can be whatever device is supporting by the mount, including network devices or devices specified by UUID rather than device path, depending on the operating system. On Linux systems it can contain whitespace.

dump

Whether to dump the mount. Not all platform support this. Valid values are 1 or 0 (or 2 on FreeBSD). Default is 0.

ensure

Valid values: defined, present, unmounted, absent, mounted

Aliases: "present"=>"defined"

Control what to do with this mount. Set this attribute to unmounted to make sure the filesystem is in the filesystem table but not mounted (if the filesystem is currently mounted, it will be unmounted). Set it to absent to unmount (if necessary) and remove the filesystem from the fstab. Set to mounted to add it to the fstab and mount it. Set to present to add to fstab but not change mount/unmount status.

fstype

The mount type. Valid values depend on the operating system. This is a required option.

options

A single string containing options for the mount, as they would appear in fstab on Linux. For many platforms this is a comma-delimited string. Consult the fstab(5) man page for system-specific details. AIX options other than dev, nodename, or vfs can be defined here. If specified, AIX options of account, boot, check, free, mount, size, type, vol, log, and quota must be ordered alphabetically at the end of the list.

pass

The pass in which the mount is checked.

target

The file in which to store the mount table. Only used by those providers that write to disk.

Parameters

The following parameters are available in the mount type.

name

namevar

The mount path for the mount. On Linux systems it can contain whitespace.

provider

The specific backend to use for this mount resource. You will seldom need to specify this --- Puppet will usually discover the appropriate provider for your platform.

remounts

Valid values: true, false

Whether the mount can be remounted mount -o remount. If this is false, then the filesystem will be unmounted and remounted manually, which is prone to failure.