diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-1.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-1.json index 7b9f4053b854ac5275613d755ee4da2d1d32dacc..17d351a6f7a3c583c718430238a00eafcf8550cf 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-1.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-1.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 28, + "uid": "pdu-c6-1" + }, + { + "port": 35, + "uid": "pdu-c6-1" + }, + { + "port": 42, + "uid": "pdu-c6-1" + }, + { + "port": 28, + "uid": "pdu-c6-2" + }, + { + "port": 35, + "uid": "pdu-c6-2" + }, + { + "port": 42, + "uid": "pdu-c6-2" + }, + { + "kind": "wattmetre-only", + "port": 18, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 19, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 20, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 21, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 22, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 23, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-2.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-2.json index db5b7dfc5e90ad1faa34c5b18bad2decd0874bde..a9c439e7002a9c46df0c67d48f7293e0c2f87707 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-2.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-2.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 28, + "uid": "pdu-c6-1" + }, + { + "port": 35, + "uid": "pdu-c6-1" + }, + { + "port": 42, + "uid": "pdu-c6-1" + }, + { + "port": 28, + "uid": "pdu-c6-2" + }, + { + "port": 35, + "uid": "pdu-c6-2" + }, + { + "port": 42, + "uid": "pdu-c6-2" + }, + { + "kind": "wattmetre-only", + "port": 18, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 19, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 20, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 21, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 22, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 23, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-3.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-3.json index fdcc4d2ea50e85dba12bb422ad1e141b0042767a..20cc9eff876c20f5baaaafa2190fe204ebab7929 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-3.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-3.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 28, + "uid": "pdu-c5-1" + }, + { + "port": 35, + "uid": "pdu-c5-1" + }, + { + "port": 42, + "uid": "pdu-c5-1" + }, + { + "port": 28, + "uid": "pdu-c5-2" + }, + { + "port": 35, + "uid": "pdu-c5-2" + }, + { + "port": 42, + "uid": "pdu-c5-2" + }, + { + "kind": "wattmetre-only", + "port": 12, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 13, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 14, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 15, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 16, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 17, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-4.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-4.json index 2d5cd248a0abb2a980f3a875b6896bd229326903..1f8ed67208c197347098ec4ea0a2edde0553ea24 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-4.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-4.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 28, + "uid": "pdu-c5-1" + }, + { + "port": 35, + "uid": "pdu-c5-1" + }, + { + "port": 42, + "uid": "pdu-c5-1" + }, + { + "port": 28, + "uid": "pdu-c5-2" + }, + { + "port": 35, + "uid": "pdu-c5-2" + }, + { + "port": 42, + "uid": "pdu-c5-2" + }, + { + "kind": "wattmetre-only", + "port": 12, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 13, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 14, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 15, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 16, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 17, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-5.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-5.json index a85d6054601c8ace0929f7696e5339d46d0006ab..d674240afa82a220197a74ebc753d8fe94ee92c5 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-5.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-5.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 28, + "uid": "pdu-c4-1" + }, + { + "port": 30, + "uid": "pdu-c4-1" + }, + { + "port": 42, + "uid": "pdu-c4-1" + }, + { + "port": 28, + "uid": "pdu-c4-2" + }, + { + "port": 30, + "uid": "pdu-c4-2" + }, + { + "port": 42, + "uid": "pdu-c4-2" + }, + { + "kind": "wattmetre-only", + "port": 24, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 25, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 26, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 27, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 28, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 29, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-6.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-6.json index 4ddb161edd821e492645afbce1ef5a2737945e61..2baf3f14ee15aa83bd3922fd56c8ea65e2638f1d 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-6.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-6.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 28, + "uid": "pdu-c4-1" + }, + { + "port": 30, + "uid": "pdu-c4-1" + }, + { + "port": 42, + "uid": "pdu-c4-1" + }, + { + "port": 28, + "uid": "pdu-c4-2" + }, + { + "port": 30, + "uid": "pdu-c4-2" + }, + { + "port": 42, + "uid": "pdu-c4-2" + }, + { + "kind": "wattmetre-only", + "port": 24, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 25, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 26, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 27, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 28, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 29, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-7.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-7.json index 323feb9d2cd25bd3fc80b85ce1daeac2d5589bcc..1d0955021ebf3f175225597ad9b710205c1fad9e 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-7.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-7.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 2, + "uid": "pdu-c4-1" + }, + { + "port": 14, + "uid": "pdu-c4-1" + }, + { + "port": 2, + "uid": "pdu-c4-2" + }, + { + "port": 14, + "uid": "pdu-c4-2" + }, + { + "port": 15, + "uid": "pdu-c4-2" + }, + { + "port": 16, + "uid": "pdu-c4-2" + }, + { + "kind": "wattmetre-only", + "port": 30, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 31, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 32, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 33, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 34, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 35, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-8.json b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-8.json index b28853064ee0d7b43440b2f3942dd6b9e0a60445..d50e5275b03c9a794b6a67cf3836e1c990ab10b4 100644 --- a/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-8.json +++ b/data/grid5000/sites/lille/clusters/chuc/nodes/chuc-8.json @@ -298,6 +298,62 @@ "pstate_governor": "performance", "turboboost_enabled": true }, + "pdu": [ + { + "port": 2, + "uid": "pdu-c4-1" + }, + { + "port": 14, + "uid": "pdu-c4-1" + }, + { + "port": 2, + "uid": "pdu-c4-2" + }, + { + "port": 14, + "uid": "pdu-c4-2" + }, + { + "port": 15, + "uid": "pdu-c4-2" + }, + { + "port": 16, + "uid": "pdu-c4-2" + }, + { + "kind": "wattmetre-only", + "port": 30, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 31, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 32, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 33, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 34, + "uid": "wattmetrev3-1" + }, + { + "kind": "wattmetre-only", + "port": 35, + "uid": "wattmetrev3-1" + } + ], "performance": { "core_flops": 41600000000, "node_flops": 1331200000000 diff --git a/data/grid5000/sites/lille/pdus/pdu-c4-1.json b/data/grid5000/sites/lille/pdus/pdu-c4-1.json index 9c24f1e905ffcf345a1d11ae63f5e7e6a506fb94..819b1fc76cdb2f333307c954b1449a157ee60a34 100644 --- a/data/grid5000/sites/lille/pdus/pdu-c4-1.json +++ b/data/grid5000/sites/lille/pdus/pdu-c4-1.json @@ -1,11 +1,31 @@ { "model": "Unknown", "ports": { + "14": [ + "chuc-7", + "chuc-8" + ], "17": "chirop-3", + "2": [ + "chuc-7", + "chuc-8" + ], "22": "chirop-2", + "28": [ + "chuc-5", + "chuc-6" + ], + "30": [ + "chuc-5", + "chuc-6" + ], "34": "chirop-1", "35": "chirop-4", - "40": "chirop-5" + "40": "chirop-5", + "42": [ + "chuc-5", + "chuc-6" + ] }, "type": "pdu", "uid": "pdu-c4-1", diff --git a/data/grid5000/sites/lille/pdus/pdu-c4-2.json b/data/grid5000/sites/lille/pdus/pdu-c4-2.json index 86f22d774010b1f54e3d5f5d67e966797913a34e..3bd8962d47a4a9ce564fdabf991112827e0197c9 100644 --- a/data/grid5000/sites/lille/pdus/pdu-c4-2.json +++ b/data/grid5000/sites/lille/pdus/pdu-c4-2.json @@ -1,11 +1,39 @@ { "model": "Unknown", "ports": { + "14": [ + "chuc-7", + "chuc-8" + ], + "15": [ + "chuc-7", + "chuc-8" + ], + "16": [ + "chuc-7", + "chuc-8" + ], "17": "chirop-3", + "2": [ + "chuc-7", + "chuc-8" + ], "22": "chirop-2", + "28": [ + "chuc-5", + "chuc-6" + ], + "30": [ + "chuc-5", + "chuc-6" + ], "34": "chirop-1", "35": "chirop-4", - "40": "chirop-5" + "40": "chirop-5", + "42": [ + "chuc-5", + "chuc-6" + ] }, "type": "pdu", "uid": "pdu-c4-2", diff --git a/data/grid5000/sites/lille/pdus/pdu-c5-1.json b/data/grid5000/sites/lille/pdus/pdu-c5-1.json new file mode 100644 index 0000000000000000000000000000000000000000..f806c8ed338430631e4063f87e141ec7cd8fc2ea --- /dev/null +++ b/data/grid5000/sites/lille/pdus/pdu-c5-1.json @@ -0,0 +1,20 @@ +{ + "model": "Unknown", + "ports": { + "28": [ + "chuc-3", + "chuc-4" + ], + "35": [ + "chuc-3", + "chuc-4" + ], + "42": [ + "chuc-3", + "chuc-4" + ] + }, + "type": "pdu", + "uid": "pdu-c5-1", + "vendor": "Unknown" +} \ No newline at end of file diff --git a/data/grid5000/sites/lille/pdus/pdu-c5-2.json b/data/grid5000/sites/lille/pdus/pdu-c5-2.json new file mode 100644 index 0000000000000000000000000000000000000000..5819caeb4e9b788ec5d9b715d34c00505f888dd4 --- /dev/null +++ b/data/grid5000/sites/lille/pdus/pdu-c5-2.json @@ -0,0 +1,20 @@ +{ + "model": "Unknown", + "ports": { + "28": [ + "chuc-3", + "chuc-4" + ], + "35": [ + "chuc-3", + "chuc-4" + ], + "42": [ + "chuc-3", + "chuc-4" + ] + }, + "type": "pdu", + "uid": "pdu-c5-2", + "vendor": "Unknown" +} \ No newline at end of file diff --git a/data/grid5000/sites/lille/pdus/pdu-c6-1.json b/data/grid5000/sites/lille/pdus/pdu-c6-1.json new file mode 100644 index 0000000000000000000000000000000000000000..05d1789dbb45b3bda1151e12c15596bafced7233 --- /dev/null +++ b/data/grid5000/sites/lille/pdus/pdu-c6-1.json @@ -0,0 +1,20 @@ +{ + "model": "Unknown", + "ports": { + "28": [ + "chuc-1", + "chuc-2" + ], + "35": [ + "chuc-1", + "chuc-2" + ], + "42": [ + "chuc-1", + "chuc-2" + ] + }, + "type": "pdu", + "uid": "pdu-c6-1", + "vendor": "Unknown" +} \ No newline at end of file diff --git a/data/grid5000/sites/lille/pdus/pdu-c6-2.json b/data/grid5000/sites/lille/pdus/pdu-c6-2.json new file mode 100644 index 0000000000000000000000000000000000000000..efe7c5d241ffbb1548f1915329955281b7ca6aca --- /dev/null +++ b/data/grid5000/sites/lille/pdus/pdu-c6-2.json @@ -0,0 +1,20 @@ +{ + "model": "Unknown", + "ports": { + "28": [ + "chuc-1", + "chuc-2" + ], + "35": [ + "chuc-1", + "chuc-2" + ], + "42": [ + "chuc-1", + "chuc-2" + ] + }, + "type": "pdu", + "uid": "pdu-c6-2", + "vendor": "Unknown" +} \ No newline at end of file diff --git a/data/grid5000/sites/lille/pdus/wattmetrev3-1.json b/data/grid5000/sites/lille/pdus/wattmetrev3-1.json index 1825db9f00e793844f46e1c222b95b66dcee3e6e..691f79fc88bca2cc6c08a37e3acb293864b65198 100644 --- a/data/grid5000/sites/lille/pdus/wattmetrev3-1.json +++ b/data/grid5000/sites/lille/pdus/wattmetrev3-1.json @@ -18,8 +18,104 @@ "1": "chirop-1", "10": "chirop-3", "11": "chirop-3", + "12": [ + "chuc-3", + "chuc-4" + ], + "13": [ + "chuc-3", + "chuc-4" + ], + "14": [ + "chuc-3", + "chuc-4" + ], + "15": [ + "chuc-3", + "chuc-4" + ], + "16": [ + "chuc-3", + "chuc-4" + ], + "17": [ + "chuc-3", + "chuc-4" + ], + "18": [ + "chuc-1", + "chuc-2" + ], + "19": [ + "chuc-1", + "chuc-2" + ], "2": "chirop-2", + "20": [ + "chuc-1", + "chuc-2" + ], + "21": [ + "chuc-1", + "chuc-2" + ], + "22": [ + "chuc-1", + "chuc-2" + ], + "23": [ + "chuc-1", + "chuc-2" + ], + "24": [ + "chuc-5", + "chuc-6" + ], + "25": [ + "chuc-5", + "chuc-6" + ], + "26": [ + "chuc-5", + "chuc-6" + ], + "27": [ + "chuc-5", + "chuc-6" + ], + "28": [ + "chuc-5", + "chuc-6" + ], + "29": [ + "chuc-5", + "chuc-6" + ], "3": "chirop-2", + "30": [ + "chuc-7", + "chuc-8" + ], + "31": [ + "chuc-7", + "chuc-8" + ], + "32": [ + "chuc-7", + "chuc-8" + ], + "33": [ + "chuc-7", + "chuc-8" + ], + "34": [ + "chuc-7", + "chuc-8" + ], + "35": [ + "chuc-7", + "chuc-8" + ], "6": "chirop-5", "7": "chirop-5", "8": "chirop-4", diff --git a/input/grid5000/sites/lille/pdus.yaml b/input/grid5000/sites/lille/pdus.yaml index f9112a8b820e4857c029ebd24338f37aec474860..d382bbb9e6f686b1555a6dbe2dd616c92e1a2dba 100644 --- a/input/grid5000/sites/lille/pdus.yaml +++ b/input/grid5000/sites/lille/pdus.yaml @@ -61,6 +61,20 @@ pdus: vendor: Unknown model: Unknown ports: + 2: + uid: [chuc-7, chuc-8] + wattmetre: wattmetrev3-1 + module: '04000618' + channel: 4 + phase: 1 + phase_inverted: false + 14: + uid: [chuc-7, chuc-8] + wattmetre: wattmetrev3-1 + module: '04000618' + channel: 1 + phase: 2 + phase_inverted: false 17: uid: chirop-3 wattmetre: wattmetrev3-1 @@ -75,6 +89,20 @@ pdus: channel: 3 phase: 1 phase_inverted: false + 28: + uid: [chuc-5, chuc-6] + wattmetre: wattmetrev3-1 + module: '04000617' + channel: 5 + phase: 1 + phase_inverted: false + 30: + uid: [chuc-5, chuc-6] + wattmetre: wattmetrev3-1 + module: '04000617' + channel: 3 + phase: 2 + phase_inverted: false 34: uid: chirop-1 wattmetre: wattmetrev3-1 @@ -96,11 +124,46 @@ pdus: channel: 1 phase: 3 phase_inverted: false - + 42: + uid: [chuc-5, chuc-6] + wattmetre: wattmetrev3-1 + module: '04000617' + channel: 1 + phase: 3 + phase_inverted: false + pdu-c4-2: vendor: Unknown model: Unknown ports: + 2: + uid: [chuc-7, chuc-8] + wattmetre: wattmetrev3-1 + module: '04000618' + channel: 2 + phase: 1 + phase_inverted: false + 14: + uid: [chuc-7, chuc-8] + wattmetre: wattmetrev3-1 + module: '04000618' + channel: 3 + phase: 2 + phase_inverted: false + 15: + uid: [chuc-7, chuc-8] + wattmetre: wattmetrev3-1 + module: '04000618' + channel: 5 + phase: 3 + phase_inverted: false + 16: + uid: [chuc-7, chuc-8] + wattmetre: wattmetrev3-1 + module: '04000618' + channel: 6 + phase: 3 + phase_inverted: false 17: uid: chirop-3 wattmetre: wattmetrev3-1 @@ -115,6 +178,20 @@ pdus: channel: 4 phase: 1 phase_inverted: false + 28: + uid: [chuc-5, chuc-6] + wattmetre: wattmetrev3-1 + module: '04000617' + channel: 6 + phase: 1 + phase_inverted: false + 30: + uid: [chuc-5, chuc-6] + wattmetre: wattmetrev3-1 + module: '04000617' + channel: 4 + phase: 2 + phase_inverted: false 34: uid: chirop-1 wattmetre: wattmetrev3-1 @@ -136,3 +213,114 @@ pdus: channel: 2 phase: 2 phase_inverted: false + 42: + uid: [chuc-5, chuc-6] + wattmetre: wattmetrev3-1 + module: '04000617' + channel: 2 + phase: 3 + phase_inverted: false + + pdu-c5-1: + vendor: Unknown + model: Unknown + ports: + 28: + uid: [chuc-3, chuc-4] + wattmetre: wattmetrev3-1 + module: '04000615' + channel: 6 + phase: 1 + phase_inverted: false + 35: + uid: [chuc-3, chuc-4] + wattmetre: wattmetrev3-1 + module: '04000615' + channel: 3 + phase: 2 + phase_inverted: false + 42: + uid: [chuc-3, chuc-4] + wattmetre: wattmetrev3-1 + module: '04000615' + channel: 1 + phase: 3 + phase_inverted: false + + pdu-c5-2: + vendor: Unknown + model: Unknown + ports: + 28: + uid: [chuc-3, chuc-4] + wattmetre: wattmetrev3-1 + module: '04000615' + channel: 5 + phase: 1 + phase_inverted: false + 35: + uid: [chuc-3, chuc-4] + wattmetre: wattmetrev3-1 + module: '04000615' + channel: 4 + phase: 2 + phase_inverted: false + 42: + uid: [chuc-3, chuc-4] + wattmetre: wattmetrev3-1 + module: '04000615' + channel: 2 + phase: 3 + phase_inverted: false + + pdu-c6-1: + vendor: Unknown + model: Unknown + ports: + 28: + uid: [chuc-1, chuc-2] + wattmetre: wattmetrev3-1 + module: '04000616' + channel: 5 + phase: 1 + phase_inverted: false + 35: + uid: [chuc-1, chuc-2] + wattmetre: wattmetrev3-1 + module: '04000616' + channel: 3 + phase: 2 + phase_inverted: false + 42: + uid: [chuc-1, chuc-2] + wattmetre: wattmetrev3-1 + module: '04000616' + channel: 1 + phase: 3 + phase_inverted: false + + pdu-c6-2: + vendor: Unknown + model: Unknown + ports: + 28: + uid: [chuc-1, chuc-2] + wattmetre: wattmetrev3-1 + module: '04000616' + channel: 6 + phase: 1 + phase_inverted: false + 35: + uid: [chuc-1, chuc-2] + wattmetre: wattmetrev3-1 + module: '04000616' + channel: 4 + phase: 2 + phase_inverted: false + 42: + uid: [chuc-1, chuc-2] + wattmetre: wattmetrev3-1 + module: '04000616' + channel: 2 + phase: 3 + phase_inverted: false diff --git a/lib/refrepo/gen/puppet/templates/kwollect-wattmetre-mapping.erb b/lib/refrepo/gen/puppet/templates/kwollect-wattmetre-mapping.erb index 0ec8a7132f3cbc1511253570b01f1f3b50b99cb9..eb5f582a8905efabe7dd5c071b90cf3a54d27be7 100644 --- a/lib/refrepo/gen/puppet/templates/kwollect-wattmetre-mapping.erb +++ b/lib/refrepo/gen/puppet/templates/kwollect-wattmetre-mapping.erb @@ -4,6 +4,15 @@ # <%- + wattmetre_port_per_node_flat = {} + wattmetre_port_per_node.each do |nodes, ports| + nodes = [nodes] if nodes.is_a?(String) + nodes.each do |node| + wattmetre_port_per_node_flat[node] = ports + end + end + wattmetre_port_per_node = wattmetre_port_per_node_flat + # Sort by cluster and node number wattmetre_port_per_node.to_a.sort_by { |e| n = e[0].split('-') ; n[1] = n[1].to_i ; n }.each { |e| node, ports = e -%> diff --git a/lib/refrepo/input_loader.rb b/lib/refrepo/input_loader.rb index 0bf0e71cca9172fdc3619b4fcbeee351e39e2d27..2fa42260d10ee8b1ff24b8688fc3e65547786083 100644 --- a/lib/refrepo/input_loader.rb +++ b/lib/refrepo/input_loader.rb @@ -120,15 +120,18 @@ def add_node_pdu_mapping(h) end # Merge pdu information from pdus/ hierachy into node information - pdu.fetch("ports", {}).each do |port_uid, node_uid| - node_uid = node_uid["uid"] if node_uid.is_a?(Hash) - node = site["clusters"].fetch(node_uid.split("-")[0], {}).fetch("nodes", {}).fetch(node_uid, nil) - next if not node - node["pdu"] ||= [] - if node["pdu"].any?{|p| p["uid"] == pdu_uid && p["port"] == port_uid} - raise "ERROR: Node #{node_uid}.#{site_uid} has PDU #{pdu_uid} description defined both in clusters/ and pdus/ hierarchy" - end - node["pdu"].append({"uid" => pdu_uid, "port" => port_uid}) + pdu.fetch("ports", {}).each do |port_uid, nodes_uid| + nodes_uid = nodes_uid["uid"] if nodes_uid.is_a?(Hash) + nodes_uid = [nodes_uid] if nodes_uid.is_a?(String) + nodes_uid.each do |node_uid| + node = site["clusters"].fetch(node_uid.split("-")[0], {}).fetch("nodes", {}).fetch(node_uid, nil) + next if not node + node["pdu"] ||= [] + if node["pdu"].any?{|p| p["uid"] == pdu_uid && p["port"] == port_uid} + raise "ERROR: Node #{node_uid}.#{site_uid} has PDU #{pdu_uid} description defined both in clusters/ and pdus/ hierarchy" + end + node["pdu"].append({"uid" => pdu_uid, "port" => port_uid}) + end end # Merge pdu information from node description in pdus/ hierachy @@ -137,7 +140,13 @@ def add_node_pdu_mapping(h) raise "ERROR: Port #{port_uid} of #{pdu_uid}.#{site_uid} is defined both in PDU description and in node #{node_uid} description" end pdu["ports"] ||= {} - pdu["ports"][port_uid] = node_uid + if not pdu["ports"].key?(port_uid) + pdu["ports"][port_uid] = node_uid + elsif pdu["ports"].key?(port_uid) and pdu["ports"]["port_uid"].is_a?(String) + pdu["ports"][port_uid] = [pdu["ports"][port_uid], node_uid] + else + pdu["ports"][port_uid].append(node_uid) + end end end end @@ -182,12 +191,15 @@ def add_wattmetre_mapping(h) pdu["ports"][port_num] = node_uid # Add mapping to node description under clusters/ hierarchy - node = site["clusters"].fetch(node_uid.split("-")[0], {}).fetch("nodes", {}).fetch(node_uid, nil) - node["pdu"] ||= [] - if node["pdu"].any?{|p| p["uid"] == pdu_uid && p["port"] == port_num} - raise "ERROR: Node #{node_uid}.#{site_uid} has PDU #{pdu_num} description defined both in clusters/ and pdus/ hierarchy" + nodes_uid = node_uid.is_a?(String) ? [node_uid] : node_uid + nodes_uid.each do |nnode_uid| + node = site["clusters"].fetch(nnode_uid.split("-")[0], {}).fetch("nodes", {}).fetch(nnode_uid, nil) + node["pdu"] ||= [] + if node["pdu"].any?{|p| p["uid"] == pdu_uid && p["port"] == port_num} + raise "ERROR: Node #{nnode_uid}.#{site_uid} has PDU #{pdu_num} description defined both in clusters/ and pdus/ hierarchy" + end + node["pdu"].append({"uid" => pdu_uid, "port" => port_num, "kind" => "wattmetre-only"}) end - node["pdu"].append({"uid" => pdu_uid, "port" => port_num, "kind" => "wattmetre-only"}) end end end @@ -665,6 +677,10 @@ def add_pdu_metrics(h) # remove any PDU metrics defined in cluster cluster['metrics'] = cluster.fetch('metrics', []).reject {|m| m['name'] =~ /(wattmetre_power_watt|pdu_outlet_power_watt)/ } + # Do not add metric to cluster if PDU/wattmetre port is connected to several nodes at a time (shared PSU case) + nodes_pdu_ports = cluster['nodes'].select{|_, v| v['status'] != 'retired'}.each_value.map{|node| node["pdu"]}.flatten + next if nodes_pdu_ports.uniq.length != nodes_pdu_ports.length # nodes pdu_ports has duplicate, meaning the a port is shared by several nodes + # get the list of "wattmetre-only" used by the cluster cluster_wm = cluster['nodes'].each_value.map{|node| node.fetch('pdu', [])}.flatten.select{|p| p.fetch('kind', '') == 'wattmetre-only'}.map{|p| p['uid']}.uniq diff --git a/lib/refrepo/valid/homogeneity.rb b/lib/refrepo/valid/homogeneity.rb index aa23189868da9ff6fb4739e9330a76a84cb12257..ac45d61e9ea9c44f81e8d5c1038dfbbb86279a8c 100644 --- a/lib/refrepo/valid/homogeneity.rb +++ b/lib/refrepo/valid/homogeneity.rb @@ -41,6 +41,10 @@ def global_ignore_keys ~pdu[5] ~pdu[6] ~pdu[7] + ~pdu[8] + ~pdu[9] + ~pdu[10] + ~pdu[11] ~nodeset