Skip to content

Latest commit

 

History

History
1244 lines (724 loc) · 31.3 KB

REFERENCE.md

File metadata and controls

1244 lines (724 loc) · 31.3 KB

Reference

Table of Contents

Classes

Public Classes

  • cvmfs: Installs and Configures CVMFS

Private Classes

  • cvmfs::apt: Configure cvmfs apt repositories
  • cvmfs::config: Central configuration of CVMFS
  • cvmfs::fsck: enable check_fsck as a cron or systemd timer
  • cvmfs::install: Install cvmfs from a yum repository.
  • cvmfs::service: Manages the cvmfs services. Opionally this also manages the autofs services
  • cvmfs::yum: Configure cvmfs yum repositories

Defined types

  • cvmfs::domain: Configure a a domain of cvmfs repositories
  • cvmfs::id_map: Create a map file uid or gid mappings
  • cvmfs::mount: Mount one cvmfs repository. Most parameters map as lower case versions of the raw cvmfs parameters.

Classes

cvmfs

Deprecated paramters below

Examples

Simple Example For one Mount
class{'cvmfs':
  cvmfs_http_proxy => 'http://ca-proxy.example.org:3128',
  cvmfs_quota_limit => 100
}
cvmfs::mount{'files.example.org:
  cvmfs_server_url => 'http://web.example.org/cvmfs/files.example.org',
}
Mount a Domain
class{'cvmfs':
  cvmfs_http_proxy  => 'http://ca-proxy.example.org:3128',
  cvmfs_quota_limit => 100,
}
cvmfs::domain{'example.net'
  cvmfs_server_url => 'http://web.example.org/cvmfs/@fqrn@'
}
Use fuse3 version of cvmfs
class{'cvmfs':
  fuse3 => true,
}
Use Mount rather than AutoFS
class{'cvmfs':
  mount_method => 'mount',
}
Specify mounts as a hash
class{'cvmfs':
  cvmfs_hash => {
    'foo.example.org' => { 'cvmfs_server_url => 'http://web.example.org/cmfs/foo.example.org' },
    'bar.example.org' => { 'cvmfs_server_url => 'http://web.example.org/cvmfs/bar.example.org' },
  }
}
New parameters with CVMFS 2.11.0
class{'cvmfs':
  cvmfs_cache_symlinks => 'yes',
  cvmfs_streaming_cache => 'no',
  cvmfs_statfs_cache_timeout => 10,
  cvmfs_world_readable => 'yes',
  cvmfs_cpu_affinity => [0,1,2],
  cvmfs_xattr_privileged_gids => [100,101,102],
  cvmfs_xattr_protected_xattrs => ['user.foo','user.bar'],
  cvmfs_cache_refcount => 'yes',
}

Parameters

The following parameters are available in the cvmfs class:

mount_method

Data type: Enum['autofs','mount','none']

The autofs option will configure cvmfs to be mounted with autofs. The mount option will use puppet's mount type, currently adding a line to /etc/fstab. The none option skips all mounting. Note that migrating between for instance autofs and then mount is not supported.

Default value: 'autofs'

config_repo

Data type: Optional[Stdlib::Fqdn]

When using the mount_method as mount it may be nescessary to specify a CVMFS located configuration_repository. This is a repository containing extra cvmfs configuration required to be mounted before any other repositories. There is at most one config_repo client. In addition the config_repo must actually be mounted explicitly with a cvmfs::mount{$config_repo:}, this is not automatic.

Default value: undef

manage_autofs_service

Data type: Boolean

should the autofs service be maintained.

Default value: true

cvmfs_quota_limit

Data type: Variant[Enum['auto'],Integer]

The cvmfs quota size in megabytes.

Default value: 1000

cvmfs_quota_ratio

Data type: Float

If set , e.g '0.8', then 0.8 of the partition size the cvmfs cache is on will be used. Setting this assumes you have pre-allocated a partition to the cvmfs cache or else it makes little sense.

Default value: 0.85

cvmfs_http_proxy

Data type: Variant[Undef,String]

List of squid servers, e.g http://squid1.example.org;http;//squid2.example.org

cvmfs_cache_base

Data type: Stdlib::Absolutepath

Location of the CVMFS cache base

Default value: '/var/lib/cvmfs'

cvmfs_cache_owner

Data type: String[1]

expected owner of cvmfs cache

Default value: 'cvmfs'

cvmfs_cache_group

Data type: String[1]

expected group of cvmfs cache

Default value: 'cvmfs'

cvmfs_cache_mode

Data type: Stdlib::Filemode

expected mode of cvmfs cache

Default value: '0700'

cvmfs_ipfamily_prefer

Data type: Optional[Variant[Integer[4,4],Integer[6,6]]]

Preferred IP protocol for dual-stack proxies. If not set, cvmfs default will be used.

Default value: undef

cvmfs_dns_min_ttl

Data type: Optional[Integer]

Minimum ttl of DNS lookups in seconds.

Default value: undef

cvmfs_dns_max_ttl

Data type: Optional[Integer]

Maximum ttl of DNS lookups in seconds.

Default value: undef

cvmfs_claim_ownership

Data type: Optional[Enum['yes','no']]

Whether the client claims ownership of files or not.

Default value: undef

cvmfs_uid_map

Data type: Optional[Hash[Variant[Integer,String], Integer, 1]]

Hash of UID pairs to map UIDs from catalogue to on the client.

Default value: undef

cvmfs_gid_map

Data type: Optional[Hash[Variant[Integer,String], Integer, 1]]

Hash of GID pairs to map GIDs from catalogue to on the client.

Default value: undef

cvmfs_memcache_size

Data type: Optional[Integer]

Size of the CernVM-FS meta-data memory cache in Megabyte.

Default value: undef

cvmfs_mount_rw

Data type: Optional[Enum['yes','no']]

Mount option to mount as read-only or read/write.

Default value: undef

cvmfs_follow_redirects

Data type: Optional[Enum['yes','no']]

Sets CVMFS_FOLLOW_REDIRECTS to its value

Default value: undef

cvmfs_timeout

Data type: Optional[Integer]

cvmfs timeout setting.

Default value: undef

cvmfs_timeout_direct

Data type: Optional[Integer]

cvmfs timeout to direct connections.

Default value: undef

cvmfs_nfiles

Data type: Optional[Integer]

Number of open files, system setting.

Default value: undef

cvmfs_syslog_level

Data type: Optional[Integer[1,2]]

Level to syslog at.

Default value: undef

cvmfs_tracefile

Data type: Optional[Stdlib::Absolutepath]

Create a tracefile at this location.

Default value: undef

cvmfs_debuglog

Data type: Optional[Stdlib::Absolutepath]

Create a debug log file at this location.

Default value: undef

cvmfs_max_ttl

Data type: Optional[Integer]

Max ttl.

Default value: undef

cvmfs_version

Data type: String[1]

Version of cvmfs to install.

Default value: 'present'

repo_base

Data type: Stdlib::Httpurl

URL containting stable, testing and config apt or yum repositories. Default in hiera data.

repo_includepkgs

Data type: Optional[Variant[Enum['absent'], Array[String[1]]]]

Specify an includepkgs to the yum repos to ignore other packages.

repo_priority

Data type: Integer

Yum priority of repositories

Default value: 80

repo_proxy

Data type: Optional[Stdlib::Httpurl]

http proxy for cvmfs yum package repository

Default value: undef

repo_config_enabled

Data type: Boolean

Should the config yum repository be enabled

Default value: false

repo_testing_enabled

Data type: Boolean

Should the testing repository be enabled.

Default value: false

repo_gpgcheck

Data type: Boolean

set to false to disable GPG checking

Default value: true

repo_gpgkey

Data type: Stdlib::Httpurl

Set a custom GPG key for yum repos. Default in hiera data.

repo_manage

Data type: Boolean

Set to false to disable yum or apt repositories management.

Default value: true

cvmfs_use_geoapi

Data type: Optional[Enum['yes','no']]

Enable geoapi to find suitable proxies.

Default value: undef

cvmfs_repositories

Data type: Optional[String[1]]

If undef CVMFS_REPOSITORIES in default.local will be populated automatically from what is explicitly mounted with cvmfs::mount. If this is specified thenCVMFS_REPOSITORIES list in default.local will be exactly managed with this variable. e.g cvmfs-config.cern.ch,atlas.cern.ch

Default value: undef

cvmfs_hash

Data type: Hash

Rather than using cvmfs::mount defined type a hash of mounts can be sepecfied.

Default value: {}

cvmfs_env_variables

Data type: Hash

$cvmfs_env_variables = {'CMS_LOCAL_SITE' => '<path to siteconf>' will produce export CMS_LOCAL_SITE=<path to siteconf>in the default.local file.

Default value: {}

default_cvmfs_partsize

Data type: Integer

Default value: 10000

cvmfs_domain_hash

Data type: Hash

Specify of a hash cvmfs::domain types.

Default value: {}

cvmfs_instrument_fuse

Data type: Boolean

Instrument Fuse

Default value: false

cvmfs_repo_list

Data type: Boolean

Specify exactly the REPO_LIST in defaults.local overriding auto population.

Default value: true

cvmfs_alien_cache

Data type: Optional[String]

Use an alien cache

Default value: undef

cvmfs_shared_cache

Data type: Optional[Enum['yes','no']]

Enable a shared cache

Default value: undef

cvmfs_fsck

Data type: Boolean

Ensure the cvmfs::fsck class is included.

Default value: false

cvmfs_fsck_options

Data type: Optional[String]

Any extra options for cvmfs fsck

Default value: undef

cvmfs_fsck_onreboot

Data type: Boolean

Should fsck be run after every reboot

Default value: false

fuse3

Data type: Optional[Boolean]

Install or disable fuse3 variant of cvmfs, if left undef no change will be made. Note that changing this value when CVMFS mounts are active may well destroy those mounts. Not availabe on Ubuntu 18.04.

Default value: undef

cvmfs_cache_symlinks

Data type: Optional[Enum['yes','no']]

If set to yes, enables symlink caching in the kernel.

Default value: undef

cvmfs_streaming_cache

Data type: Optional[Enum['yes','no']]

If set to yes, use a download manager to download regular files on read.

Default value: undef

cvmfs_statfs_cache_timeout

Data type: Optional[Integer[1]]

Caching time of statfs() in seconds (no caching by default).

Default value: undef

cvmfs_world_readable

Data type: Optional[Enum['yes','no']]

Override posix read permissions to make files in repository globally readable

Default value: undef

cvmfs_cpu_affinity

Data type: Optional[Array[Integer[0],1]]

Set CPU affinity for all cvmfs components.

Default value: undef

cvmfs_xattr_privileged_gids

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

group IDs that are allowed to access the extended attributes by $cvmfs_xattr_protected_xattrs.

Default value: undef

cvmfs_xattr_protected_xattrs

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

List of extended attributes (full name, e.g. user.fqrn) that are only accessible by root and the group IDs listed by $cvmfs_xattr_privileged_gids.

Default value: undef

cvmfs_cache_refcount

Data type: Optional[Enum['yes','no']]

If set to yes, deduplicate open file descriptors by refcounting.

Default value: undef

cvmfs_yum

Data type: Optional[Stdlib::Httpurl]

Deprecated, use repo_base

Default value: undef

cvmfs_yum_priority

Data type: Optional[Integer]

Deprecated, use repo_priority

Default value: undef

cvmfs_yum_proxy

Data type: Optional[Stdlib::Httpurl]

Deprecated, user repo_proxy

Default value: undef

cvmfs_yum_config

Data type: Optional[Stdlib::Httpurl]

Deprecated, use repo_base

Default value: undef

cvmfs_yum_config_enabled

Data type: Optional[Integer[0,1]]

Deprecated, user repo_config_enabled

Default value: undef

cvmfs_yum_testing

Data type: Optional[Stdlib::Httpurl]

Deprecated, use repo_base

Default value: undef

cvmfs_yum_testing_enabled

Data type: Optional[Integer[0,1]]

Deprecated, use repo_testing_enabled

Default value: undef

cvmfs_yum_gpgcheck

Data type: Optional[Integer[0,1]]

Deprecated, use repo_gpgcheck

Default value: undef

cvmfs_yum_gpgkey

Data type: Optional[Variant[Stdlib::Filesource,Stdlib::Httpurl]]

Deprecated, use repo_gpgkey

Default value: undef

cvmfs_yum_manage_repo

Data type: Optional[Boolean]

Deprecated, use repo_manage

Default value: undef

cvmfs_yum_includepkgs

Data type: Optional[Variant[Enum['absent'], Array[String]]]

Deprecated, use repo_includepkgs

Default value: undef

Defined types

cvmfs::domain

Configure a a domain of cvmfs repositories

Examples

Add the example.org domain
cvmfs::domain{'example.org':
  cvmfs_server_url = 'http://example.org/cvmfs/@fqrn@',
}

Parameters

The following parameters are available in the cvmfs::domain defined type:

domain

Data type: Stdlib::Fqdn

The domain of CVMFS repositories to mount

Default value: $name

cvmfs_quota_limit

Data type: Optional[Integer]

Per mount quota limit, not relavent to shared cache. Sets cvmfs_quota_limit

Default value: undef

cvmfs_server_url

Data type: Optional[String[1]]

Stratum 1 list, typically ; delimited. Sets CVMFS_SERVER_URL parameter.

Default value: undef

cvmfs_http_proxy

Data type: Optional[String[1]]

List of http proxies to use. Sets CVMFS_PROXY_LIST parameter.

Default value: undef

cvmfs_timeout

Data type: Optional[Integer]

Sets CVMFS_HTTP_TIMEOUT parameter

Default value: undef

cvmfs_timeout_direct

Data type: Optional[Integer]

Sets CVMFS_HTTP_TIMEOUT_DIRECT

Default value: undef

cvmfs_nfiles

Data type: Optional[Integer]

Number of open files permitted on the OS. Sets CVMFS_NFILES

Default value: undef

cvmfs_max_ttl

Data type: Optional[Integer]

Maximum effective TTL in seconds for DNS queries of proxy server names. Sets CVMFS_MAX_TTL

Default value: undef

cvmfs_env_variables

Data type: Optional[Hash]

Sets per repo environments variables for magic links.

Default value: undef

cvmfs_use_geoapi

Data type: Optional[Stdlib::Yes_no]

Set CVMFS_MAX_GEOAPI

Default value: undef

cvmfs_follow_redirects

Data type: Optional[Stdlib::Yes_no]

Sets CVMFS_FOLLOW_REDIRECTS.

Default value: undef

cvmfs_external_fallback_proxy

Data type: Optional[String]

Sets CVMFS_EXTERNAL_FALLBACK_PROXY

Default value: undef

cvmfs_external_http_proxy

Data type: Optional[String]

Sets CVMFS_EXTERNAL_HTTP_PROXY

Default value: undef

cvmfs_external_timeout

Data type: Optional[Integer]

Sets CVMFS_EXTERNAL_TIMEOUT

Default value: undef

cvmfs_external_timeout_direct

Data type: Optional[Integer]

Sets CVMFS_EXTERNAL_TIMEOUT_DIRECT

Default value: undef

cvmfs_external_url

Data type: Optional[String]

Sets CVMFS_EXTERNAL_URL

Default value: undef

cvmfs_public_key

Data type: Optional[String[1]]

Specify repository signing key

Default value: undef

cvmfs_keys_dir

Data type: Optional[Stdlib::Absolutepath]

Specify repository directory with signing keys

Default value: undef

cvmfs::id_map

Create a map file uid or gid mappings

Parameters

The following parameters are available in the cvmfs::id_map defined type:

map

Data type: Hash[Variant[Integer,String], Integer, 1]

Hash of {from => to} pairs

location

Data type: Stdlib::Absolutepath

Path to write map to.

Default value: $title

cvmfs::mount

Mount one cvmfs repository. Most parameters map as lower case versions of the raw cvmfs parameters.

Examples

Trivial Mount
cvmfs::mount{'files.example.org:
  cvmfs_server_url => 'http://web.exampple.org/cvmfs/files.example.org',
}
Mount with Environment Variables.
cvmfs::mount{'foobar.example.org':
  cvmfs_env_variables => {
    'FOOT' => 'ball',
    'GOLF' => 'club',
  }
}
Mount a repository with mount (not automount)
class{ 'cvmfs':
  mount_method => 'mount',
}
cvmfs::mount{'quark.example.org':}
Mount a repository with mount and a config_repo as well.
class{ 'cvmfs':
  mount_method => 'mount',
  config_mount => 'cvmfs-config.example.org',
}
cvmfs::mount{'cvmfs-config.example.org':}
cvmfs::mount{'down.example.org':}

Parameters

The following parameters are available in the cvmfs::mount defined type:

repo

Data type: Stdlib::Fqdn

The fully qualified repository name to mount

Default value: $name

cvmfs_quota_limit

Data type: Optional[Integer]

Per mount quota limit, not relavent to shared cache. Sets cvmfs_quota_limit

Default value: undef

cvmfs_server_url

Data type: Optional[String[1]]

Stratum 1 list, typically ; delimited. Sets CVMFS_SERVER_URL parameter.

Default value: undef

cvmfs_http_proxy

Data type: Optional[String[1]]

List of http proxies to use. Sets CVMFS_PROXY_LIST parameter.

Default value: undef

cvmfs_timeout

Data type: Optional[Integer]

Sets CVMFS_HTTP_TIMEOUT parameter

Default value: undef

cvmfs_timeout_direct

Data type: Optional[Integer]

Sets CVMFS_HTTP_TIMEOUT_DIRECT

Default value: undef

cvmfs_nfiles

Data type: Optional[Integer]

Number of open files permitted on the OS. Sets CVMFS_NFILES

Default value: undef

cvmfs_public_key

Data type: Optional[String[1]]

Public key of repository, sets CVMFS_PUBLIC_KEYS

Default value: undef

cvmfs_keys_dir

Data type: Optional[Stdlib::Absolutepath]

Directory with public keys for repository, sets CVMFS_KEYS_DIR

Default value: undef

cvmfs_max_ttl

Data type: Optional[Integer]

Maximum effective TTL in seconds for DNS queries of proxy server names. Sets CVMFS_MAX_TTL

Default value: undef

cvmfs_env_variables

Data type: Optional[Hash]

Sets per repo environments variables for magic links.

Default value: undef

cvmfs_use_geoapi

Data type: Optional[Stdlib::Yes_no]

Set CVMFS_MAX_GEOAPI

Default value: undef

mount_method

Data type: Optional[String[1]]

Deprecated, do not set this, set mount_method for the whole client only on the main class.

Default value: undef

cvmfs_repo_list

Data type: Boolean

If true the repository will added to the list of repositories maintained in /etc/cvmfs/default.local

Default value: true

cvmfs_mount_rw

Data type: Optional[Stdlib::Yes_no]

sets CVMFS_MOUNT_RW

Default value: undef

cvmfs_memcache_size

Data type: Optional[Integer]

Sets CVMFS_MEMCACHE_SIZE in Megabytes.

Default value: undef

cvmfs_claim_ownership

Data type: Optional[Stdlib::Yes_no]

Sets CVMFS_CLAIM_OWNERSHIP.

Default value: undef

cvmfs_uid_map

Data type: Optional[Hash[Variant[Integer,String],Integer, 1]]

Specify a UID map file path for this repository . Sets CVMFS_UID_MAP

Default value: undef

cvmfs_gid_map

Data type: Optional[Hash[Variant[Integer,String],Integer, 1]]

Specify a GID map file path for this repository . Sets CVMFS_GID_MAP

Default value: undef

cvmfs_follow_redirects

Data type: Optional[Stdlib::Yes_no]

Sets CVMFS_FOLLOW_REDIRECTS.

Default value: undef

cvmfs_external_fallback_proxy

Data type: Optional[String]

Sets CVMFS_EXTERNAL_FALLBACK_PROXY

Default value: undef

cvmfs_external_http_proxy

Data type: Optional[String]

Sets CVMFS_EXTERNAL_HTTP_PROXY

Default value: undef

cvmfs_external_timeout

Data type: Optional[Integer]

Sets CVMFS_EXTERNAL_TIMEOUT

Default value: undef

cvmfs_external_timeout_direct

Data type: Optional[Integer]

Sets CVMFS_EXTERNAL_TIMEOUT_DIRECT

Default value: undef

cvmfs_external_url

Data type: Optional[String]

Sets CVMFS_EXTERNAL_URL

Default value: undef

cvmfs_repository_tag

Data type: Optional[String[1]]

Sets CVMFS_REPOSITORY_TAG

Default value: undef

mount_options

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

Mount options to use for fstab style mounting. mount_method==mount only

Default value: ['defaults','_netdev','nodev']