Closed michakrause closed 10 years ago
I'm not sure about that particular error message, but you can enforce ordering in your calling manifest with: Class['pacemaker::corosync'] -> Class['pacemaker::stonith'] For example, see https://github.com/redhat-openstack/astapor/blob/master/puppet/modules/quickstack/manifests/pacemaker/common.pp .
Thats the problem, I have no manifest I use foreman to attach these classes to a node.
I'm not sure I understand how you're doing this without a manifest. can't you just put the code cwolferh has suggested right below your classes?
edit: Oh I see a parameters tab in foreman when you choose the class, This is how you're doing it?
Any suggestions on how to fix this without a manifest? I can't think of one off the top of my head
Yes, thats how I do it. I have no idea how to fix it. Just to test, I tried the suggestion, from cwolferh even tho I can't use it with foreman:
class {"pacemaker::resource::ip": ip_address => "10.153.1.10", } class {"pacemaker::stonith": disable => true, } class { 'pacemaker::corosync': cluster_name => "proxy", cluster_members => "10.153.1.11 10.153.1.12" } Class['pacemaker::corosync'] -> Class['pacemaker::stonith']
The result is exactly the same:
Error: Must pass cluster_name to Class[Pacemaker::Corosync]
I guess it has something to do with the "inherits pacemaker::corosync" thing in pacemaker::stonith.
I solved that "foreman" problem with pacemaker-module with an wrapper class for pacermaker like this:
class myown_pacemaker () {
include pacemaker
Class['pacemaker::corosync'] -> Class['pacemaker::stonith']
class { pacemaker::corosync:
cluster_name => "fs_cluster",
cluster_members => "172.20.120.76 172.20.120.77",
}
class { pacemaker::stonith:
disable => true,
}
class { pacemaker::resource::ip:
ip_address => "172.20.120.78",
cidr_netmask => "24",
nic => 'bond0:0',
group => "my_group",
}
}
This is the way we're doing it in other places. Thanks for letting me know you got it working.
If I load pacemaker::stonith before pacemaker::corosync:
class {"pacemaker::stonith": disable => true, } class { 'pacemaker::corosync': cluster_name => "proxy", cluster_members => "10.153.1.11 10.153.1.12" }
I get:
Error: Must pass cluster_name to Class[Pacemaker::Corosync]
Using Foreman there is no way to load classes in a specific order, so this should be fixed somehow.