Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-07 Thread Vladislav Bogdanov
06.12.2013 19:13, James Oakley wrote:
 On Thursday, December 5, 2013 9:55:47 PM Vladislav Bogdanov 
 bub...@hoster-ok.com wrote:
 
 Does 'db0' resolve to a correct IP address? If not, then you probably
 want either fix that or use remote-addr option as well. I saw that you
 can ping/ssh that container, but it is not clear did you use 'db0' name
 for that or IP address.
 
 Yes, I access by name. I defined all of my private node addresses in 
 /etc/hosts, which is
 shared throughout the cluster via csync2.

No idea then, sorry.

 
 I grepped for 'remote' in the logs and found nothing. I have no idea if it's 
 even trying.
 Is there something specific I can look for?


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-06 Thread Lars Marowsky-Bree
On 2013-12-06T08:55:47, Vladislav Bogdanov bub...@hoster-ok.com wrote:

 BTW, pacemaker cib accepts any meta attributes (and that is very
 convenient way for me to store some 'meta' information), while crmsh
 limits them to a pre-defined list. While that is probably fine for
 novices, that limits some advanced usage scenarios, that's why I
 disabled that check by a patch for my builds.

That's intentional. You're polluting a namespace that doesn't belong to
you. Any update that introduces a new feature could potentially collide
with your key/value pairs. Also, the CIB really isn't performant enough
to store meta data like this.

If by advanced you mean abusing cluster features, yes, then I agree,
that are scenarios we want to limit ;-)


Regards,
Lars

-- 
Architect Storage/HA
SUSE LINUX Products GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB 
21284 (AG Nürnberg)
Experience is the name everyone gives to their mistakes. -- Oscar Wilde


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-06 Thread Vladislav Bogdanov
06.12.2013 11:41, Lars Marowsky-Bree wrote:
 On 2013-12-06T08:55:47, Vladislav Bogdanov bub...@hoster-ok.com wrote:
 
 BTW, pacemaker cib accepts any meta attributes (and that is very
 convenient way for me to store some 'meta' information), while crmsh
 limits them to a pre-defined list. While that is probably fine for
 novices, that limits some advanced usage scenarios, that's why I
 disabled that check by a patch for my builds.
 
 That's intentional. You're polluting a namespace that doesn't belong to
 you. Any update that introduces a new feature could potentially collide
 with your key/value pairs. 

Agree.

 Also, the CIB really isn't performant enough
 to store meta data like this.

Generally I agree. In my use-case I store bits of information needed to
recreate higher-layer configuration in the case of catastrophe (and to
verify that CIB configuration is correct after cluster restart). I
read them in the same function with other attributes, after the whole
CIB is received. So performance impact is nearly zero for me.

 
 If by advanced you mean abusing cluster features, yes, then I agree,
 that are scenarios we want to limit ;-)

Yep, abuse is a correct word :)
Fortunately I know how to use text editor, hg diff, patch and rpmbuild ;)


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread emmanuel segura
did you try in this following way?

primitive lxc_db0 ocf:heartbeat:lxc \
params container=db0 config=/var/lib/lxc/db0/config \
meta remote-node=db0


2013/12/5 James Oakley jf...@funktronics.ca

 I have Pacemaker 1.1.10 cluster running on openSUSE 13.1 and I am trying
 to get pacemaker-remote working so I can manage resources in LXC
 containers. I have pacemaker_remoted running in the containers.

 However, I can't seem to get crm configured to talk to the daemons. The
 only documentation I found is the pcs-centric doc here:


 http://clusterlabs.org/doc/en-US/Pacemaker/1.1/html-single/Pacemaker_Remote/#idm272823453136

 I'm using crm, and not pcs, but it plainly states that all I need to do is
 set the remote-node meta to the hostname on the LXC resource.

 Unfortunately, crm does not let me add it. I tried forcing it using
 crm_resource, but it's not working. It shows up now:

 primitive lxc_db0 @lxc \
 params container=db0 config=/var/lib/lxc/db0/config \
 meta remote-node=db0


 But verify doesn't like it:

 crm(live)configure# verify
error: setup_container:  Resource lxc_db0: Unknown resource
 container (db0)
error: setup_container:  Resource lxc_db1: Unknown resource
 container (db1)
 Errors found during check: config not valid
 ERROR: lxc_db0: attribute remote-node does not exist
 ERROR: lxc_db1: attribute remote-node does not exist

 What am I missing? Is this somehow disabled on non-pcs clusters, and if
 so, why is the pacemaker-remote package even in the openSUSE repositories
 and pcs not?

 --
 James Oakley
 jf...@funktronics.ca

 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: http://bugs.clusterlabs.org




-- 
esta es mi vida e me la vivo hasta que dios quiera
___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread Lars Marowsky-Bree
On 2013-12-05T08:57:48, James Oakley jf...@funktronics.ca wrote:

 Unfortunately, crm does not let me add it. I tried forcing it using 
 crm_resource, but it's not working. It shows up now:
 
 primitive lxc_db0 @lxc \
 params container=db0 config=/var/lib/lxc/db0/config \
 meta remote-node=db0

I think this is because crm doesn't know about the remote-node
attribute. It can render it, but it doesn't pass verify. Kristoffer?

 What am I missing? Is this somehow disabled on non-pcs clusters, and if so, 
 why is the pacemaker-remote package even in the openSUSE repositories and pcs 
 not?

We do provide pcs, but not as part of 13.1. Note that the preferred
shell on openSUSE/SLE HA is and will remain crmsh, not pcs.

openSUSE Build Service's network:ha-clustering:Factory has pcs, and I
think we also provide a build for 13.1 there.

pacemaker-remote isn't fully tested on openSUSE yet. We welcome feedback
and patches. ;-)



Regards,
Lars

-- 
Architect Storage/HA
SUSE LINUX Products GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB 
21284 (AG Nürnberg)
Experience is the name everyone gives to their mistakes. -- Oscar Wilde


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread James Oakley
On Thursday, December 5, 2013 9:08:46 AM emmanuel segura emi2f...@gmail.com 
wrote:
 did you try in this following way?
 
 primitive lxc_db0 ocf:heartbeat:lxc \
 params container=db0 config=/var/lib/lxc/db0/config \
 meta remote-node=db0

I get the same behavior this way, unfortunately.

-- 
James Oakley
jf...@funktronics.ca

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread emmanuel segura
Follow the Lars comment I think this is because crm doesn't know about the
remote-node
attribute


2013/12/5 James Oakley jf...@funktronics.ca

 On Thursday, December 5, 2013 9:08:46 AM emmanuel segura 
 emi2f...@gmail.com wrote:
  did you try in this following way?
 
  primitive lxc_db0 ocf:heartbeat:lxc \
  params container=db0 config=/var/lib/lxc/db0/config \
  meta remote-node=db0

 I get the same behavior this way, unfortunately.

 --
 James Oakley
 jf...@funktronics.ca

 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: http://bugs.clusterlabs.org




-- 
esta es mi vida e me la vivo hasta que dios quiera
___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread James Oakley
On Thursday, December 5, 2013 9:21:18 AM Lars Marowsky-Bree l...@suse.com 
wrote:
  primitive lxc_db0 @lxc \
  params container=db0 config=/var/lib/lxc/db0/config \
  meta remote-node=db0
 
 I think this is because crm doesn't know about the remote-node
 attribute. It can render it, but it doesn't pass verify. Kristoffer?

That's why I used crm_resource to add it. If I dump the config with cibadmin, 
it looks consistent with the example here:

http://clusterlabs.org/doc/en-US/Pacemaker/1.1/html-single/Pacemaker_Remote/#_mile_high_view_of_configuration_steps

primitive id=lxc_db0 template=lxc
  instance_attributes id=lxc_db0-instance_attributes
nvpair name=container value=db0 
id=lxc_db0-instance_attributes-container/
nvpair name=config value=/var/lib/lxc/db0/config 
id=lxc_db0-instance_attributes-config/
  /instance_attributes
  meta_attributes id=lxc_db0-meta_attributes
nvpair id=lxc_db0-meta_attributes-remote-node name=remote-node 
value=db0/
nvpair id=lxc_db0-meta_attributes-target-role name=target-role 
value=Started/
  /meta_attributes
/primitive

However, the nodes do not show up in crm status output as in the examples in 
the documentation. I also tried creating a resource to run on a remote node, 
but it said the node didn't exist.


  What am I missing? Is this somehow disabled on non-pcs clusters, and if so,
  why is the pacemaker-remote package even in the openSUSE repositories and
  pcs not?
 
 We do provide pcs, but not as part of 13.1. Note that the preferred
 shell on openSUSE/SLE HA is and will remain crmsh, not pcs.

Oh yes, I plan to use whatever is provided/recommend by SuSE, as I always have. 
I am just confused why pacemaker-remote is provided if it only works with pcs, 
which is not. However, it looks like it's not even a crm vs pcs thing, but a 
problem with Pacemaker itself as provided.


 pacemaker-remote isn't fully tested on openSUSE yet. We welcome feedback
 and patches. ;-)

I would be happy to provide feedback or a patch, but I don't even know where to 
start on this. All I can say is that pacemaker-remoted itself is running fine 
and listening on it's port. It's the Pacemaker side I'm having trouble with.

-- 
James Oakley
jf...@funktronics.ca

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread emmanuel segura
what happen if you try ping db0 from your physical host?


2013/12/5 James Oakley jf...@funktronics.ca

 On Thursday, December 5, 2013 9:21:18 AM Lars Marowsky-Bree 
 l...@suse.com wrote:
   primitive lxc_db0 @lxc \
   params container=db0 config=/var/lib/lxc/db0/config \
   meta remote-node=db0
 
  I think this is because crm doesn't know about the remote-node
  attribute. It can render it, but it doesn't pass verify. Kristoffer?

 That's why I used crm_resource to add it. If I dump the config with
 cibadmin, it looks consistent with the example here:


 http://clusterlabs.org/doc/en-US/Pacemaker/1.1/html-single/Pacemaker_Remote/#_mile_high_view_of_configuration_steps

 primitive id=lxc_db0 template=lxc
   instance_attributes id=lxc_db0-instance_attributes
 nvpair name=container value=db0
 id=lxc_db0-instance_attributes-container/
 nvpair name=config value=/var/lib/lxc/db0/config
 id=lxc_db0-instance_attributes-config/
   /instance_attributes
   meta_attributes id=lxc_db0-meta_attributes
 nvpair id=lxc_db0-meta_attributes-remote-node name=remote-node
 value=db0/
 nvpair id=lxc_db0-meta_attributes-target-role name=target-role
 value=Started/
   /meta_attributes
 /primitive

 However, the nodes do not show up in crm status output as in the examples
 in the documentation. I also tried creating a resource to run on a remote
 node, but it said the node didn't exist.


   What am I missing? Is this somehow disabled on non-pcs clusters, and
 if so,
   why is the pacemaker-remote package even in the openSUSE repositories
 and
   pcs not?
 
  We do provide pcs, but not as part of 13.1. Note that the preferred
  shell on openSUSE/SLE HA is and will remain crmsh, not pcs.

 Oh yes, I plan to use whatever is provided/recommend by SuSE, as I always
 have. I am just confused why pacemaker-remote is provided if it only works
 with pcs, which is not. However, it looks like it's not even a crm vs pcs
 thing, but a problem with Pacemaker itself as provided.


  pacemaker-remote isn't fully tested on openSUSE yet. We welcome feedback
  and patches. ;-)

 I would be happy to provide feedback or a patch, but I don't even know
 where to start on this. All I can say is that pacemaker-remoted itself is
 running fine and listening on it's port. It's the Pacemaker side I'm having
 trouble with.

 --
 James Oakley
 jf...@funktronics.ca

 ___
 Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
 http://oss.clusterlabs.org/mailman/listinfo/pacemaker

 Project Home: http://www.clusterlabs.org
 Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
 Bugs: http://bugs.clusterlabs.org




-- 
esta es mi vida e me la vivo hasta que dios quiera
___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread James Oakley
On Thursday, December 5, 2013 10:21:01 AM emmanuel segura 
emi2f...@gmail.com wrote:
 what happen if you try ping db0 from your physical host?

Yes, networking is fine. I can ping ssh, etc. and there is no firewall running.

-- 
James Oakley
jf...@funktronics.ca

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread Lars Marowsky-Bree
On 2013-12-05T10:10:08, James Oakley jf...@funktronics.ca wrote:

 That's why I used crm_resource to add it. If I dump the config with cibadmin, 
 it looks consistent with the example here:
 
 http://clusterlabs.org/doc/en-US/Pacemaker/1.1/html-single/Pacemaker_Remote/#_mile_high_view_of_configuration_steps

Right, the pacemaker version on 13.1 already supports pacemaker-remote.

 However, the nodes do not show up in crm status output as in the examples in 
 the documentation. I also tried creating a resource to run on a remote node, 
 but it said the node didn't exist.

Right. Do they show up in crm_mon?

 Oh yes, I plan to use whatever is provided/recommend by SuSE, as I
 always have. I am just confused why pacemaker-remote is provided if it
 only works with pcs, which is not. However, it looks like it's not
 even a crm vs pcs thing, but a problem with Pacemaker itself as
 provided.

With pcs and crmsh, users now have the choice of two shells - and not
both of them always support all features of pacemaker in exactly the
same way, or at all. (There's some constraint parts that crmsh still
handles better, and the history explorer, for example.)

We already provide pacemaker-remote as part of the main distribution
because it can be used independently from crmsh.

Since RHT is heavily focused on pcs and pacemaker-remote, it makes sense
that that combo is the first to support both. We were waiting for it to
be fully stable a little bit longer ;-) But it's also on the roadmap for
crmsh. Kristoffer was busy with other features recently though.

You can try upgrading to the packages from
networking:ha-clustering:Factory from the openSUSE Build Service, which
are more uptodate than 13.1 already.

We also have a very quiet opensuse-ha mailing list for issues specific
to packaging on openSUSE: http://lists.opensuse.org/opensuse-ha/ feel
free to raise this over there too.


Regards,
Lars

-- 
Architect Storage/HA
SUSE LINUX Products GmbH, GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer, HRB 
21284 (AG Nürnberg)
Experience is the name everyone gives to their mistakes. -- Oscar Wilde


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread James Oakley
On Thursday, December 5, 2013 11:51:01 AM Lars Marowsky-Bree l...@suse.com 
wrote:
  However, the nodes do not show up in crm status output as in the examples
  in the documentation. I also tried creating a resource to run on a remote
  node, but it said the node didn't exist.
 
 Right. Do they show up in crm_mon?

No:

Last updated: Thu Dec  5 17:44:20 2013
Last change: Thu Dec  5 17:42:58 2013 by hacluster via crmd on hn0
Stack: corosync
Current DC: hn0 (1077857413) - partition with quorum
Version: 1.1.10+git20131204.93a37bf-93.1-1.1.10+git20131204.93a37bf
2 Nodes configured
7 Resources configured


Online: [ hn0 hn1 ]

 Resource Group: grp_db0
 fs_db0 (ocf::heartbeat:Filesystem):Started hn0
 lxc_db0(ocf::heartbeat:lxc):   Started hn0
 Resource Group: grp_db1
 fs_db1 (ocf::heartbeat:Filesystem):Started hn1
 lxc_db1(ocf::heartbeat:lxc):   Started hn1
 Resource Group: grp_squid
 ip_squid   (ocf::heartbeat:IPaddr2):   Started hn0
 squid  (ocf::heartbeat:Squid): Started hn0
dummy   (ocf::pacemaker:Dummy): Started hn1

The dummy resource is something I attempted to get running on the db0 node, 
but I get this in crm:

WARNING: loc_dummy: referenced node db0 does not exist


 You can try upgrading to the packages from
 networking:ha-clustering:Factory from the openSUSE Build Service, which
 are more uptodate than 13.1 already.

I just tried that. No difference for remote-node, but crm has more pretty 
colours, and the templates are now shown as raw xml in crm configure show.


 We also have a very quiet opensuse-ha mailing list for issues specific
 to packaging on openSUSE: http://lists.opensuse.org/opensuse-ha/ feel
 free to raise this over there too.

Quiet is why I tried here and not there. :-) I will have to subscribe to that.

-- 
James Oakley
jf...@funktronics.ca

___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org


Re: [Pacemaker] Pacemaker 1.1.10 and pacemaker-remote

2013-12-05 Thread Vladislav Bogdanov
05.12.2013 19:57, James Oakley wrote:
 I have Pacemaker 1.1.10 cluster running on openSUSE 13.1 and I am
 trying to get pacemaker-remote working so I can manage resources in LXC
 containers. I have pacemaker_remoted running in the containers.
 
 However, I can't seem to get crm configured to talk to the daemons.
 The only documentation I found is the pcs-centric doc here:
 
 
 http://clusterlabs.org/doc/en-US/Pacemaker/1.1/html-single/Pacemaker_Remote/#idm272823453136
 
 I'm using crm, and not pcs, but it plainly states that all I need to
 do is set the remote-node meta to the hostname on the LXC resource.
 
 Unfortunately, crm does not let me add it. I tried forcing it using
 crm_resource, but it's not working. It shows up now:
 
 primitive lxc_db0 @lxc \ params container=db0
 config=/var/lib/lxc/db0/config \ meta remote-node=db0

Does 'db0' resolve to a correct IP address? If not, then you probably
want either fix that or use remote-addr option as well. I saw that you
can ping/ssh that container, but it is not clear did you use 'db0' name
for that or IP address.

 
 
 But verify doesn't like it:
 
 crm(live)configure# verify 
error: setup_container:  Resource lxc_db0: Unknown resource container 
 (db0)
error: setup_container:  Resource lxc_db1: Unknown resource container 
 (db1)
 Errors found during check: config not valid
 ERROR: lxc_db0: attribute remote-node does not exist
 ERROR: lxc_db1: attribute remote-node does not exist

You can use check_mode=relaxed crmsh userpref to downgrade that error to
a warning until it is fixed.

BTW, pacemaker cib accepts any meta attributes (and that is very
convenient way for me to store some 'meta' information), while crmsh
limits them to a pre-defined list. While that is probably fine for
novices, that limits some advanced usage scenarios, that's why I
disabled that check by a patch for my builds.

It would better look for meta attributes 'similar' to a known ones, f.e.
target_role vs target-role, and warn about them only.

 
 What am I missing? Is this somehow disabled on non-pcs clusters, and if so, 
 why is the 
 pacemaker-remote package even in the openSUSE repositories and pcs not?
 


___
Pacemaker mailing list: Pacemaker@oss.clusterlabs.org
http://oss.clusterlabs.org/mailman/listinfo/pacemaker

Project Home: http://www.clusterlabs.org
Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf
Bugs: http://bugs.clusterlabs.org