[ClusterLabs] Hawk error when I create new primitive

デージーネット 大野 公善 ohno at designet.co.jp
Sun May 8 09:18:09 EDT 2016


Hi.

I began the operation test of the 'Hawk'.

CentOS 7
ruby 2.3.1p112
puma version 2.16.0
hawk-2.0.0


When I tried to create a new primitive, ERROR has occurred.

Follow:
(1) Click "Add Resource"
(2) Click "Primitive"
(3) Input data

    Resource ID: ipAddr
    Template: (none)
    Class: ocf
    Provider: heartbeat
    Type: IPaddr2

    Parameters
      ip: 172.16.1.222
      cidr_netmask: 24

(4) Click "Create" button

ERROR:
2: syntax in primitive: Unknown arguments: ip=172.16.1.222
cidr_netmask=24 op start timeout=20s op stop timeout=20s op monitor
timeout=20s interval=10s meta target-role=Stopped near parsing
'primitive ipAddr ocf:heartbeat:IPaddr2 ip=172.16.1.222 cidr_netmask=24
op start timeout=20s op stop timeout=20s op monitor timeout=20s
interval=10s meta target-role=Stopped'


I think, the following format is the correct.

[NG]
primitive ipAddr ocf:heartbeat:IPaddr2 ip=172.16.1.222 cidr_netmask=24
op start timeout=20s op stop timeout=20s op monitor timeout=20s
interval=10s meta target-role=Stopped

[OK]
primitive ipAddr ocf:heartbeat:IPaddr2 params ip=172.16.1.222
cidr_netmask=24 op start timeout=20s op stop timeout=20s op monitor
timeout=20s interval=10s meta target-role=Stopped

"params" keyword is missing.


When I changed as follow, I was able to create a new primitive.

[hawk/app/models/primitive.rb]
---- cut here ----
--- primitive.rb.ORG	2016-02-08 23:58:16.000000000 +0900
+++ primitive.rb	2016-05-08 21:55:24.439000000 +0900
@@ -97,6 +97,8 @@
       cmd.push agent_name

       unless params.blank?
+        cmd.push "params"
+
         params.each do |key, value|
           cmd.push [
             key,
---- cut here ----


Is this correct?

-- 
======================================
 DesigNET,INC.
 OSS-LAB
 Kimiyoshi Ohno <ohno at designet.co.jp>
 TEL: 052-709-7121  FAX: 052-709-7122
 URL: http://www.DesigNET.co.jp/
      http://クラスタ.jp/
======================================




More information about the Users mailing list