[Pacemaker] How to display interface link status in corosync

Andrew Beekhof andrew at beekhof.net
Tue Apr 30 03:36:04 UTC 2013


On 18/04/2013, at 2:42 PM, Yuichi SEINO <seino.cluster2 at gmail.com> wrote:

> Hi,
> 
> 2013/4/15 Andrew Beekhof <andrew at beekhof.net>:
>> 
>> On 15/04/2013, at 3:38 PM, Yuichi SEINO <seino.cluster2 at gmail.com> wrote:
>> 
>>> Hi,
>>> 
>>> 2013/4/8 Andrew Beekhof <andrew at beekhof.net>:
>>>> I'm not 100% sure what the best approach is here.
>>>> 
>>>> Traditionally this is done with resource agents (ie. ClusterMon or ping) which update attrd.
>>>> We could potentially build it into attrd directly, but then we'd need to think about how to turn it on/off.
>>>> 
>>>> I think I'd lean towards a new agent+daemon or a new daemon launched by ClusterMon.
>>> I check to see if I implement this function by a new agent+daemon.
>>> I have a question. I am not sure how to launch daemon by ClusterMon.
>>> Do you mean to use "crm_mon -E"?
>> 
>> No. I mean the same way the Apache agent starts httpd.
> apache RA has the parameter which a binary path can specify. So, This
> RA may be able to launch the other daemon.
> However, it seems that ClusterMon doesn't have the parameter which a
> binary path can specify.
> Can you launch the other daemon without using the parameter?


step 1 - write a daemon that talks to attrd
step 2 - patch the start function of the ClusterMon RA to start your new daemon
step 3 - patch the stop function of the ClusterMon RA to stop your new daemon


> 
> Sincerely,
> Yuichi
> 
>> 
>>> 
>>> Sincerely,
>>> Yuichi
>>> 
>>>> 
>>>> On 04/04/2013, at 8:59 PM, Yuichi SEINO <seino.cluster2 at gmail.com> wrote:
>>>> 
>>>>> Hi All,
>>>>> 
>>>>> I want to display interface link status in corosync. So, I think that
>>>>> I will add this function to the part of "pacemakerd".
>>>>> I am going to display this status to "Node Attributes"  in crm_mon.
>>>>> When the state of link change, corosync can run the callback function.
>>>>> When it happens, we update attributes. And, this function need to
>>>>> start after "attrd" started. "pacemakerd" of mainloop start after
>>>>> sub-process started. So, I think that this is the best timing.
>>>>> 
>>>>> I show the expected crm_mon.
>>>>> 
>>>>> # crm_mon -fArc1
>>>>> Last updated: Thu Apr  4 08:08:08 2013
>>>>> Last change: Wed Apr  3 04:15:48 2013 via crmd on coro-n2
>>>>> Stack: corosync
>>>>> Current DC: coro-n1 (168427526) - partition with quorum
>>>>> Version: 1.1.9-c791037
>>>>> 2 Nodes configured, unknown expected votes
>>>>> 2 Resources configured.
>>>>> 
>>>>> 
>>>>> Online: [ coro-n1 coro-n2 ]
>>>>> 
>>>>> Full list of resources:
>>>>> 
>>>>> Clone Set: OFclone [openstack-fencing]
>>>>>   Started: [ coro-n1 coro-n2 ]
>>>>> 
>>>>> Node Attributes:
>>>>> * Node coro-n1:
>>>>>  + ringnumber(0)                       : 10.10.0.6 is FAULTY
>>>>>  + ringnumber(1)                       : 10.20.0.6 is UP
>>>>> * Node coro-n2:
>>>>>  + ringnumber(0)                       : 10.10.0.7 is FAULTY
>>>>>  + ringnumber(1)                       : 10.20.0.7 is UP
>>>>> 
>>>>> Migration summary:
>>>>> * Node coro-n2:
>>>>> * Node coro-n1:
>>>>> 
>>>>> Tickets:
>>>>> 
>>>>> 
>>>>> Sincerely,
>>>>> Yuichi
>>>>> 
>>> 
>>> _______________________________________________
>>> Pacemaker mailing list: Pacemaker at 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
>> 
>> 
>> _______________________________________________
>> Pacemaker mailing list: Pacemaker at 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
> 
> 
> 
> --
> Yuichi SEINO
> METROSYSTEMS CORPORATION
> E-mail:seino.cluster2 at gmail.com
> 
> _______________________________________________
> Pacemaker mailing list: Pacemaker at 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





More information about the Pacemaker mailing list