Hi all,
I am writing a module to manage MySQL/MariaDB with Galera extensions and
have run into a problem I don't seem to be able to figure out.
Error: Could not apply complete catalog: Found 1 dependency cycle:
(File[/etc/mysql/conf.d/wsrep.cnf] => Service[mysqld] =>
Class[Mysql::Server] => Class[Mysql::Config] => File[/etc/mysql/conf.d] =>
File[/etc/mysql/conf.d/wsrep.cnf])
Cycle graph written to /var/lib/puppet/state/graphs/cycles.dot.
A cut down version of my puppet file is:
class galera::server (
#<snip>
) inherits mysql {
#<snip>
class { 'mysql::server':
config_hash => $config_hash,
package_name => $server_package_name,
service_name => $service_name,
#<snip>
file { '/etc/mysql/conf.d/wsrep.cnf' :
ensure => present,
mode => '0644',
owner => 'root',
group => $root_group,
content => template('galera/wsrep.cnf.erb'),
#require => File['/etc/mysql/conf.d/'],
notify => Service['mysqld']
I am using the current puppetlabs-mysql (v0.9.0) from puppet forge.
https://github.com/puppetlabs/puppetlabs-mysql/tree/master/manifests
I need the file to go in after the /etc/mysql/conf.d/ resource is complete,
but before the service is started.
The /etc/mysql/conf.d/ resource is listed in mysql::config as:
class mysql::config(
# <snip>
$purge_conf_dir = $mysql::purge_conf_dir,
) inherits mysql {
file { '/etc/mysql/conf.d':
ensure => directory,
mode => '0755',
recurse => $purge_conf_dir,
purge => $purge_conf_dir,
class mysql(
#<snip>
$purge_conf_dir = $mysql::params::purge_conf_dir,
#<snip>
) {
#<snip>
class mysql::params {
# <snip>
$purge_conf_dir = false
#<snip>
Does it have something to do with the recurse/purge metaparameters? The
defaults seem to be set as false.
Full puppet file attached and dot file from --graph.
Any light into this would be great.
Adam
I am writing a module to manage MySQL/MariaDB with Galera extensions and
have run into a problem I don't seem to be able to figure out.
Error: Could not apply complete catalog: Found 1 dependency cycle:
(File[/etc/mysql/conf.d/wsrep.cnf] => Service[mysqld] =>
Class[Mysql::Server] => Class[Mysql::Config] => File[/etc/mysql/conf.d] =>
File[/etc/mysql/conf.d/wsrep.cnf])
Cycle graph written to /var/lib/puppet/state/graphs/cycles.dot.
A cut down version of my puppet file is:
class galera::server (
#<snip>
) inherits mysql {
#<snip>
class { 'mysql::server':
config_hash => $config_hash,
package_name => $server_package_name,
service_name => $service_name,
#<snip>
file { '/etc/mysql/conf.d/wsrep.cnf' :
ensure => present,
mode => '0644',
owner => 'root',
group => $root_group,
content => template('galera/wsrep.cnf.erb'),
#require => File['/etc/mysql/conf.d/'],
notify => Service['mysqld']
I am using the current puppetlabs-mysql (v0.9.0) from puppet forge.
https://github.com/puppetlabs/puppetlabs-mysql/tree/master/manifests
I need the file to go in after the /etc/mysql/conf.d/ resource is complete,
but before the service is started.
The /etc/mysql/conf.d/ resource is listed in mysql::config as:
class mysql::config(
# <snip>
$purge_conf_dir = $mysql::purge_conf_dir,
) inherits mysql {
file { '/etc/mysql/conf.d':
ensure => directory,
mode => '0755',
recurse => $purge_conf_dir,
purge => $purge_conf_dir,
class mysql(
#<snip>
$purge_conf_dir = $mysql::params::purge_conf_dir,
#<snip>
) {
#<snip>
class mysql::params {
# <snip>
$purge_conf_dir = false
#<snip>
Does it have something to do with the recurse/purge metaparameters? The
defaults seem to be set as false.
Full puppet file attached and dot file from --graph.
Any light into this would be great.
Adam