aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--api/resources/v2/containers.py4
-rw-r--r--etc/yardstick/nodes/compass_sclab_physical/pod.yaml22
-rw-r--r--gui/app/images/checkno.pngbin5849 -> 0 bytes
-rw-r--r--gui/app/images/checkyes.pngbin6423 -> 0 bytes
-rw-r--r--gui/app/views/modal/environmentDialog.html4
-rw-r--r--gui/app/views/modal/taskCreate.html12
-rw-r--r--gui/app/views/taskmodify.html12
-rw-r--r--gui/app/views/testcasechoose.html4
-rw-r--r--samples/vnf_samples/nsut/acl/ixia_traffic.cfg51
-rw-r--r--samples/vnf_samples/nsut/cgnapt/ixia_traffic.cfg51
-rw-r--r--samples/vnf_samples/nsut/cgnapt/tc_baremetal_rfc2544_ipv4_1flow_64B_ixia.yaml4
-rw-r--r--samples/vnf_samples/nsut/vfw/ixia_traffic.cfg51
-rw-r--r--samples/vnf_samples/nsut/vpe/ixia_traffic.cfg64
-rw-r--r--samples/vnf_samples/traffic_profiles/ixia_ipv4_latency.yaml22
-rw-r--r--samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_vpe.yaml20
-rwxr-xr-xtests/ci/load_images.sh11
-rw-r--r--tests/opnfv/test_cases/opnfv_yardstick_tc054.yaml65
-rw-r--r--tests/unit/network_services/traffic_profile/test_ixia_rfc2544.py10
-rw-r--r--yardstick/benchmark/scenarios/networking/vnf_generic.py6
-rw-r--r--yardstick/network_services/libs/ixia_libs/IxNet/IxNet.py6
-rw-r--r--yardstick/network_services/traffic_profile/ixia_rfc2544.py91
-rw-r--r--yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py36
22 files changed, 153 insertions, 393 deletions
diff --git a/api/resources/v2/containers.py b/api/resources/v2/containers.py
index ee1903901..f71e607e7 100644
--- a/api/resources/v2/containers.py
+++ b/api/resources/v2/containers.py
@@ -259,13 +259,13 @@ class V2Containers(ApiResource):
def _create_dashboard(self, ip):
url = 'http://admin:admin@{}:{}/api/dashboards/db'.format(ip, 3000)
- path = os.path.join(consts.REPOS_DIR, 'dashboard', '*dashboard.json')
+ path = os.path.join(consts.REPOS_DIR, 'dashboard', 'opnfv_yardstick_tc*.json')
for i in sorted(glob.iglob(path)):
with open(i) as f:
data = jsonutils.load(f)
try:
- HttpClient().post(url, data)
+ HttpClient().post(url, {'dashboard': data})
except Exception:
LOG.exception('Create dashboard %s failed', i)
raise
diff --git a/etc/yardstick/nodes/compass_sclab_physical/pod.yaml b/etc/yardstick/nodes/compass_sclab_physical/pod.yaml
index 88501820e..218e00271 100644
--- a/etc/yardstick/nodes/compass_sclab_physical/pod.yaml
+++ b/etc/yardstick/nodes/compass_sclab_physical/pod.yaml
@@ -24,27 +24,49 @@ nodes:
ip: 192.168.10.10
user: root
password: root
+ ipmi_ip: 172.16.130.26
+ ipmi_user: root
+ ipmi_pwd: Opnfv@pod1
-
name: node2
role: Controller
ip: 192.168.10.11
user: root
password: root
+ ipmi_ip: 172.16.130.27
+ ipmi_user: root
+ ipmi_pwd: Opnfv@pod1
-
name: node3
role: Controller
ip: 192.168.10.12
user: root
password: root
+ ipmi_ip: 172.16.130.29
+ ipmi_user: root
+ ipmi_pwd: Opnfv@pod1
-
name: node4
role: Compute
ip: 192.168.10.13
user: root
password: root
+ ipmi_ip: 172.16.130.30
+ ipmi_user: root
+ ipmi_pwd: Opnfv@pod1
-
name: node5
role: Compute
ip: 192.168.10.14
user: root
password: root
+ ipmi_ip: 172.16.130.31
+ ipmi_user: root
+ ipmi_pwd: Opnfv@pod1
+-
+ name: node0
+ ip: 192.168.10.6
+ role: Baremetal
+ user: root
+ password: root
+
diff --git a/gui/app/images/checkno.png b/gui/app/images/checkno.png
deleted file mode 100644
index 7c6841930..000000000
--- a/gui/app/images/checkno.png
+++ /dev/null
Binary files differ
diff --git a/gui/app/images/checkyes.png b/gui/app/images/checkyes.png
deleted file mode 100644
index ef6028310..000000000
--- a/gui/app/images/checkyes.png
+++ /dev/null
Binary files differ
diff --git a/gui/app/views/modal/environmentDialog.html b/gui/app/views/modal/environmentDialog.html
index 4c539fc33..4c4906972 100644
--- a/gui/app/views/modal/environmentDialog.html
+++ b/gui/app/views/modal/environmentDialog.html
@@ -139,8 +139,8 @@
<th>status</th>
</tr>
<tr ng-repeat="(name, value) in yardstickImage">
- <td ng-if="selectImageList.indexOf(name) > -1"><img src="images/checkyes.png" style="height:12px;cursor:pointer" ng-click="unselectImage(name)" /></td>
- <td ng-if="selectImageList.indexOf(name) == -1"><img src="images/checkno.png" style="height:12px;cursor:pointer" ng-click="selectImage(name)" /></td>
+ <td ng-if="selectImageList.indexOf(name) > -1"><span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="unselectImage(name)"></span></td>
+ <td ng-if="selectImageList.indexOf(name) == -1"><span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="selectImage(name)"></span></td>
<td>{{name}}</td>
<td>{{value.description}}</td>
<td>{{value.status}}</td>
diff --git a/gui/app/views/modal/taskCreate.html b/gui/app/views/modal/taskCreate.html
index e7812cf2b..2d7f1dc3b 100644
--- a/gui/app/views/modal/taskCreate.html
+++ b/gui/app/views/modal/taskCreate.html
@@ -18,8 +18,8 @@
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{env.name}}</div>
<!--<button class="btn btn-default btn-sm" ng-click="gotoDetail('false',env.uuid)">detail</button>-->
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
@@ -52,8 +52,8 @@
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{test.Name}}</div>
<div style="font-size:10px;">{{test.Description}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
@@ -68,8 +68,8 @@
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{suite}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase==suite" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase==suite"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
diff --git a/gui/app/views/taskmodify.html b/gui/app/views/taskmodify.html
index a4593f745..d12df4ba2 100644
--- a/gui/app/views/taskmodify.html
+++ b/gui/app/views/taskmodify.html
@@ -22,8 +22,8 @@
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{env.name}}</div>
<!--<button class="btn btn-default btn-sm" ng-click="gotoDetail('false',env.uuid)">detail</button>-->
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv==env.uuid"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestSuit(env.uuid,env.name)" ng-show="selectEnv!=env.uuid"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
@@ -72,8 +72,8 @@
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{test.Name}}</div>
<div style="font-size:10px;">{{test.Description}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase==test.Name"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(test.Name)" ng-show="selectCase!=test.Name"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
@@ -88,8 +88,8 @@
<div style="display:flex;flex-direction:row;justify-content:space-between;padding:8px;border-top: 1px solid #e9ecec;" ng-class="{deepColor: $index%2==0}">
<div> {{suite}}</div>
- <img src="images/checkyes.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase==suite" />
- <img src="images/checkno.png" style="height:18px;cursor:pointer" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase==suite"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestCase(suite)" ng-show="selectCase!=suite"></span>
</div>
<!--<hr style="margin-top:5px;margin-bottom:5px;" />-->
diff --git a/gui/app/views/testcasechoose.html b/gui/app/views/testcasechoose.html
index 12bdb834f..12fb28c90 100644
--- a/gui/app/views/testcasechoose.html
+++ b/gui/app/views/testcasechoose.html
@@ -17,8 +17,8 @@
</div>-->
<div dir-paginate="test in testcaselist.testcases | itemsPerPage: 10">
<div style="display:flex;flex-direction:row;">
- <img src="images/checkyes.png" style="height:12px;cursor:pointer" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)>-1" />
- <img src="images/checkno.png" style="height:12px;cursor:pointer" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)==-1" />
+ <span class="glyphicon glyphicon-check" aria-hidden="true" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)>-1"></span>
+ <span class="glyphicon glyphicon-unchecked" aria-hidden="true" ng-click="constructTestSuit(test.Name)" ng-show="testsuiteList.indexOf(test.Name)==-1"></span>
<div style="margin-left:50px;"> {{test.Name}}</div>
<div style="font-size:10px;margin-left:100px">{{test.Description}}</div>
diff --git a/samples/vnf_samples/nsut/acl/ixia_traffic.cfg b/samples/vnf_samples/nsut/acl/ixia_traffic.cfg
deleted file mode 100644
index 3f7e33471..000000000
--- a/samples/vnf_samples/nsut/acl/ixia_traffic.cfg
+++ /dev/null
@@ -1,51 +0,0 @@
-{
- "uplink_0": {
- "id": 1,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:03",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "dscp": 0,
- "dstip4": "152.16.40.20",
- "proto": "udp",
- "srcip4": "152.16.100.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "2001",
- "srcport": "1234"
- },
- "traffic_type": "continuous"
- },
- "downlink_0": {
- "id": 2,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:04",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "count": 1024,
- "dscp": 0,
- "dstip4": "152.16.100.20",
- "proto": "udp",
- "srcip4": "152.16.40.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "1234",
- "srcport": "2001"
- },
- "traffic_type": "continuous"
- }
-}
diff --git a/samples/vnf_samples/nsut/cgnapt/ixia_traffic.cfg b/samples/vnf_samples/nsut/cgnapt/ixia_traffic.cfg
deleted file mode 100644
index 3f7e33471..000000000
--- a/samples/vnf_samples/nsut/cgnapt/ixia_traffic.cfg
+++ /dev/null
@@ -1,51 +0,0 @@
-{
- "uplink_0": {
- "id": 1,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:03",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "dscp": 0,
- "dstip4": "152.16.40.20",
- "proto": "udp",
- "srcip4": "152.16.100.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "2001",
- "srcport": "1234"
- },
- "traffic_type": "continuous"
- },
- "downlink_0": {
- "id": 2,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:04",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "count": 1024,
- "dscp": 0,
- "dstip4": "152.16.100.20",
- "proto": "udp",
- "srcip4": "152.16.40.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "1234",
- "srcport": "2001"
- },
- "traffic_type": "continuous"
- }
-}
diff --git a/samples/vnf_samples/nsut/cgnapt/tc_baremetal_rfc2544_ipv4_1flow_64B_ixia.yaml b/samples/vnf_samples/nsut/cgnapt/tc_baremetal_rfc2544_ipv4_1flow_64B_ixia.yaml
index 7d6203c0c..0f1ddd606 100644
--- a/samples/vnf_samples/nsut/cgnapt/tc_baremetal_rfc2544_ipv4_1flow_64B_ixia.yaml
+++ b/samples/vnf_samples/nsut/cgnapt/tc_baremetal_rfc2544_ipv4_1flow_64B_ixia.yaml
@@ -28,7 +28,7 @@ scenarios:
flow:
src_ip: [{'tg__0': 'xe0'}]
dst_ip: [{'tg__0': 'xe1'}]
- publicip: ["152.16.40.10"]
+ public_ip: ["152.16.40.10"]
count: 1
traffic_type: 4
rfc2544:
@@ -44,4 +44,4 @@ context:
type: Node
name: yardstick
nfvi_type: baremetal
- file: /etc/yardstick/nodes/pod.yaml
+ file: /etc/yardstick/nodes/pod_ixia.yaml
diff --git a/samples/vnf_samples/nsut/vfw/ixia_traffic.cfg b/samples/vnf_samples/nsut/vfw/ixia_traffic.cfg
deleted file mode 100644
index 3f7e33471..000000000
--- a/samples/vnf_samples/nsut/vfw/ixia_traffic.cfg
+++ /dev/null
@@ -1,51 +0,0 @@
-{
- "uplink_0": {
- "id": 1,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:03",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "dscp": 0,
- "dstip4": "152.16.40.20",
- "proto": "udp",
- "srcip4": "152.16.100.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "2001",
- "srcport": "1234"
- },
- "traffic_type": "continuous"
- },
- "downlink_0": {
- "id": 2,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:04",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "count": 1024,
- "dscp": 0,
- "dstip4": "152.16.100.20",
- "proto": "udp",
- "srcip4": "152.16.40.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "1234",
- "srcport": "2001"
- },
- "traffic_type": "continuous"
- }
-}
diff --git a/samples/vnf_samples/nsut/vpe/ixia_traffic.cfg b/samples/vnf_samples/nsut/vpe/ixia_traffic.cfg
deleted file mode 100644
index a0cf372cf..000000000
--- a/samples/vnf_samples/nsut/vpe/ixia_traffic.cfg
+++ /dev/null
@@ -1,64 +0,0 @@
-# Copyright (c) 2016-2017 Intel Corporation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-{
- "uplink_0": {
- "id": 1,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:03",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "dscp": 0,
- "dstip4": "152.16.40.20",
- "proto": "udp",
- "srcip4": "152.16.100.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "2001",
- "srcport": "1234"
- },
- "traffic_type": "continuous"
- },
- "downlink_0": {
- "id": 2,
- "bidir": "False",
- "duration": 60,
- "iload": "100",
- "outer_l2": {
- "dstmac": "00:00:00:00:00:04",
- "framesPerSecond": true,
- "framesize": 64,
- "srcmac": "00:00:00:00:00:01"
- },
- "outer_l3": {
- "count": 1024,
- "dscp": 0,
- "dstip4": "152.16.100.20",
- "proto": "udp",
- "srcip4": "152.16.40.20",
- "ttl": 32
- },
- "outer_l4": {
- "dstport": "1234",
- "srcport": "2001"
- },
- "traffic_type": "continuous"
- }
-}
diff --git a/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency.yaml b/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency.yaml
index a475173f2..6ba1553ad 100644
--- a/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency.yaml
+++ b/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency.yaml
@@ -33,6 +33,7 @@ traffic_profile:
uplink_0:
ipv4:
+ id: 1
outer_l2:
framesize:
64B: "{{get(imix, 'imix.uplink.64B', '0') }}"
@@ -58,6 +59,7 @@ uplink_0:
count: "{{get(flow, 'flow.count', '1') }}"
downlink_0:
ipv4:
+ id: 2
outer_l2:
framesize:
64B: "{{get(imix, 'imix.downlink.64B', '0') }}"
@@ -74,6 +76,9 @@ downlink_0:
proto: "udp"
srcip4: "{{get(flow, 'flow.dst_ip_0', '1.1.1.1-1.15.255.255') }}"
dstip4: "{{get(flow, 'flow.src_ip_0', '90.90.1.1-90.105.255.255') }}"
+ {% if flow.flow.public_ip_0 is defined %}
+ dstip4: "{{get(flow, 'flow.public_ip_0', '90.90.1.1-90.105.255.255') }}"
+ {% endif %}
count: "{{get(flow, 'flow.count', '1') }}"
ttl: 32
dscp: 0
@@ -83,6 +88,7 @@ downlink_0:
count: "{{get(flow, 'flow.count', '1') }}"
uplink_1:
ipv4:
+ id: 3
outer_l2:
framesize:
64B: "{{get(imix, 'imix.uplink.64B', '0') }}"
@@ -97,17 +103,18 @@ uplink_1:
outer_l3v4:
proto: "udp"
- srcip4: "{{get(flow, 'flow.src_ip1', '1.1.1.1-1.15.255.255') }}"
- dstip4: "{{get(flow, 'flow.dst_ip1', '90.90.1.1-90.105.255.255') }}"
+ srcip4: "{{get(flow, 'flow.src_ip_1', '1.1.1.1-1.15.255.255') }}"
+ dstip4: "{{get(flow, 'flow.dst_ip_1', '90.90.1.1-90.105.255.255') }}"
count: "{{get(flow, 'flow.count', '1') }}"
ttl: 32
dscp: 0
outer_l4:
- srcport: "{{get(flow, 'flow.src_port1', '1234') }}"
- dstport: "{{get(flow, 'flow.dst_port1', '2001') }}"
+ srcport: "{{get(flow, 'flow.src_port_1', '1234') }}"
+ dstport: "{{get(flow, 'flow.dst_port_1', '2001') }}"
count: "{{get(flow, 'flow.count', '1') }}"
downlink_1:
ipv4:
+ id: 4
outer_l2:
framesize:
64B: "{{get(imix, 'imix.downlink.64B', '0') }}"
@@ -124,10 +131,13 @@ downlink_1:
proto: "udp"
srcip4: "{{get(flow, 'flow.dst_ip_1', '1.1.1.1-1.15.255.255') }}"
dstip4: "{{get(flow, 'flow.src_ip_1', '90.90.1.1-90.105.255.255') }}"
+ {% if flow.public_ip_1 is defined %}
+ dstip4: "{{get(flow, 'flow.public_ip_1', '90.90.1.1-90.105.255.255') }}"
+ {% endif %}
count: "{{get(flow, 'flow.count', '1') }}"
ttl: 32
dscp: 0
outer_l4:
- srcport: "{{get(flow, 'flow.dst_port1', '1234') }}"
- dstport: "{{get(flow, 'flow.src_port1', '2001') }}"
+ srcport: "{{get(flow, 'flow.dst_port_1', '1234') }}"
+ dstport: "{{get(flow, 'flow.src_port_1', '2001') }}"
count: "{{get(flow, 'flow.count', '1') }}"
diff --git a/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_vpe.yaml b/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_vpe.yaml
index 5cce5941e..4d73b8ffe 100644
--- a/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_vpe.yaml
+++ b/samples/vnf_samples/traffic_profiles/ixia_ipv4_latency_vpe.yaml
@@ -46,6 +46,7 @@ traffic_profile:
uplink_0:
ipv4:
+ id: 1
outer_l2:
framesize:
64B: "{{ get(imix, 'imix.uplink.imix_small', '0') }}"
@@ -79,6 +80,7 @@ uplink_0:
dstport: "{{get(flow, 'flow.dst_port_0', '0') }}"
count: "{{get(flow, 'flow.count', '1') }}"
downlink_0:
+ id: 2
ipv4:
outer_l2:
framesize:
@@ -103,6 +105,7 @@ downlink_0:
dstport: "{{get(flow, 'flow.src_port_0', '0') }}"
count: "{{get(flow, 'flow.count', '1') }}"
uplink_1:
+ id: 3
ipv4:
outer_l2:
framesize:
@@ -126,16 +129,17 @@ uplink_1:
outer_l3v4:
proto: "tcp"
- srcip4: "{{get(flow, 'flow.srcip1', '192.168.0.0-192.168.255.255') }}"
- dstip4: "{{get(flow, 'flow.dstip1', '192.16.0.0-192.16.0.31') }}"
+ srcip4: "{{get(flow, 'flow.srcip_1', '192.168.0.0-192.168.255.255') }}"
+ dstip4: "{{get(flow, 'flow.dstip_1', '192.16.0.0-192.16.0.31') }}"
ttl: 32
dscp: 32
outer_l4:
- srcport: "{{get(flow, 'flow.src_port1', '0') }}"
- dstport: "{{get(flow, 'flow.dst_port1', '0') }}"
+ srcport: "{{get(flow, 'flow.src_port_1', '0') }}"
+ dstport: "{{get(flow, 'flow.dst_port_1', '0') }}"
count: "{{get(flow, 'flow.count', '1') }}"
downlink_1:
+ id: 4
ipv4:
outer_l2:
framesize:
@@ -149,13 +153,13 @@ downlink_1:
outer_l3v4:
proto: "tcp"
- srcip4: "{{get(flow, 'flow.dst_ip1', '192.16.0.0-192.16.0.31') }}"
- dstip4: "{{get(flow, 'flow.src_ip1', '192.168.0.0-192.168.255.255') }}"
+ srcip4: "{{get(flow, 'flow.dst_ip_1', '192.16.0.0-192.16.0.31') }}"
+ dstip4: "{{get(flow, 'flow.src_ip_1', '192.168.0.0-192.168.255.255') }}"
count: "{{get(flow, 'flow.count', '1') }}"
ttl: 32
dscp: 32
outer_l4:
- srcport: "{{get(flow, 'flow.dst_port1', '0') }}"
- dstport: "{{get(flow, 'flow.src_port1', '0') }}"
+ srcport: "{{get(flow, 'flow.dst_port_1', '0') }}"
+ dstport: "{{get(flow, 'flow.src_port_1', '0') }}"
count: "{{get(flow, 'flow.count', '1') }}"
diff --git a/tests/ci/load_images.sh b/tests/ci/load_images.sh
index c2ae4fe7b..89ebb2dde 100755
--- a/tests/ci/load_images.sh
+++ b/tests/ci/load_images.sh
@@ -13,17 +13,20 @@
set -e
YARD_IMG_ARCH=amd64
-export YARD_IMG_ARCH
if ! grep -q "Defaults env_keep += \"YARD_IMG_ARCH\"" "/etc/sudoers"; then
echo "Defaults env_keep += \"YARD_IMG_ARCH YARDSTICK_REPO_DIR\"" | sudo tee -a /etc/sudoers
fi
# Look for a compute node, that is online, and check if it is aarch64
-ARCH_SCRIPT="ssh \$(fuel2 node list | awk -F'|' '\$6 ~ /compute/ && \$11 ~ /rue/ {print \$7; exit;}') uname -m 2>/dev/null | grep -q aarch64"
-if [ "$INSTALLER_TYPE" == "fuel" ]; then
- sshpass -p r00tme ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -l root "${INSTALLER_IP}" "${ARCH_SCRIPT}" && YARD_IMG_ARCH=arm64
+if [ "${INSTALLER_TYPE}" == 'fuel' ]; then
+ COMPUTE_ARCH=$(ssh -l ubuntu ${INSTALLER_IP} -i ${SSH_KEY} ${ssh_options} \
+ "sudo salt 'cmp*' grains.get cpuarch --out yaml | awk '{print \$2; exit}'")
+ if [ "${COMPUTE_ARCH}" == 'aarch64' ]; then
+ YARD_IMG_ARCH=arm64
+ fi
fi
+export YARD_IMG_ARCH
HW_FW_TYPE=""
if [ "${YARD_IMG_ARCH}" == "arm64" ]; then
diff --git a/tests/opnfv/test_cases/opnfv_yardstick_tc054.yaml b/tests/opnfv/test_cases/opnfv_yardstick_tc054.yaml
index 417327cb6..5eb34e56a 100644
--- a/tests/opnfv/test_cases/opnfv_yardstick_tc054.yaml
+++ b/tests/opnfv/test_cases/opnfv_yardstick_tc054.yaml
@@ -13,15 +13,12 @@ description: >
Test case for TC054 :OpenStack VIP Master Node abnormally shutdown High Availability;
This test case is written by new scenario-based HA testing framework.
-{% set attack_host = attack_host or 'node1' %}
-{% set check_host = check_host or 'node2' %}
{% set jump_host = jump_host or 'node0' %}
+{% set attack_host = attack_host or 'node1' %}
+{% set check_host = check_host or 'node4' %}
{% set file = file or '/etc/yardstick/pod.yaml' %}
-{% set vip_management = vip_management or '192.168.0.2' %}
-{% set vip_public = vip_public or '172.16.0.3' %}
-{% set vip_router_management = vip_router_management or '192.168.0.1' %}
-{% set vip_router_public = vip_router_public or '172.16.0.2' %}
-{% set monitor_time = monitor_time or 180 %}
+{% set vip_public = vip_public or '10.1.0.222' %}
+{% set monitor_time = monitor_time or 30 %}
scenarios:
-
@@ -47,42 +44,6 @@ scenarios:
-
monitor_type: "general-monitor"
monitor_key: "ip-status"
- key: "vip-mgmt-status"
- host: {{check_host}}
- monitor_time: {{monitor_time}}
- monitor_number: 3
- sla:
- max_outage_time: 5
- parameter:
- ip_address: {{vip_management}}
-
- -
- monitor_type: "general-monitor"
- monitor_key: "ip-status"
- key: "vip-routerp-status"
- host: {{check_host}}
- monitor_time: {{monitor_time}}
- monitor_number: 3
- sla:
- max_outage_time: 5
- parameter:
- ip_address: {{vip_router_public}}
-
- -
- monitor_type: "general-monitor"
- monitor_key: "ip-status"
- key: "vip-router-status"
- host: {{check_host}}
- monitor_time: {{monitor_time}}
- monitor_number: 3
- sla:
- max_outage_time: 5
- parameter:
- ip_address: {{vip_router_management}}
-
- -
- monitor_type: "general-monitor"
- monitor_key: "ip-status"
key: "vip-pub"
host: {{check_host}}
monitor_time: {{monitor_time}}
@@ -102,26 +63,10 @@ scenarios:
actionKey: "list-images"
actionType: "monitor"
index: 2
-
- -
- actionKey: "vip-mgmt-status"
- actionType: "monitor"
- index: 3
-
- -
- actionKey: "vip-routerp-status"
- actionType: "monitor"
- index: 4
-
- -
- actionKey: "vip-router-status"
- actionType: "monitor"
- index: 5
-
-
actionKey: "vip-pub"
actionType: "monitor"
- index: 6
+ index: 3
nodes:
{{jump_host}}: {{jump_host}}.LF
diff --git a/tests/unit/network_services/traffic_profile/test_ixia_rfc2544.py b/tests/unit/network_services/traffic_profile/test_ixia_rfc2544.py
index 6fffb9ede..616921e33 100644
--- a/tests/unit/network_services/traffic_profile/test_ixia_rfc2544.py
+++ b/tests/unit/network_services/traffic_profile/test_ixia_rfc2544.py
@@ -179,12 +179,12 @@ class TestIXIARFC2544Profile(unittest.TestCase):
"dst_mac_0": "00:00:00:00:00:03",
"dst_mac_1": "00:00:00:00:00:04",
"dst_mac_2": "00:00:00:00:00:04"}
- self.assertRaises(IOError, r_f_c2544_profile._get_ixia_traffic_profile,
- self.PROFILE, mac, xfile="tmp",
- static_traffic=STATIC_TRAFFIC)
+ result = r_f_c2544_profile._get_ixia_traffic_profile(
+ self.PROFILE, mac, xfile="tmp",
+ static_traffic=STATIC_TRAFFIC)
+ self.assertIsNotNone(result)
- @mock.patch("yardstick.network_services.traffic_profile.ixia_rfc2544.open")
- def test_get_ixia_traffic_profile(self, mock_open):
+ def test_get_ixia_traffic_profile(self):
traffic_generator = mock.Mock(autospec=TrexProfile)
traffic_generator.my_ports = [0, 1]
traffic_generator.uplink_ports = [-1]
diff --git a/yardstick/benchmark/scenarios/networking/vnf_generic.py b/yardstick/benchmark/scenarios/networking/vnf_generic.py
index 355b69862..3f61116bc 100644
--- a/yardstick/benchmark/scenarios/networking/vnf_generic.py
+++ b/yardstick/benchmark/scenarios/networking/vnf_generic.py
@@ -546,7 +546,11 @@ printf "%s/driver:" $1 ; basename $(readlink -s $1/device/driver); } \
# we assume OrderedDict for consistenct in instantiation
for node_name, node in context_cfg["nodes"].items():
LOG.debug(node)
- file_name = node["VNF model"]
+ try:
+ file_name = node["VNF model"]
+ except KeyError:
+ LOG.debug("no model for %s, skipping", node_name)
+ continue
file_path = scenario_cfg['task_path']
with open_relative_file(file_name, file_path) as stream:
vnf_model = stream.read()
diff --git a/yardstick/network_services/libs/ixia_libs/IxNet/IxNet.py b/yardstick/network_services/libs/ixia_libs/IxNet/IxNet.py
index 358e6e761..70ce4ff03 100644
--- a/yardstick/network_services/libs/ixia_libs/IxNet/IxNet.py
+++ b/yardstick/network_services/libs/ixia_libs/IxNet/IxNet.py
@@ -254,8 +254,10 @@ class IxNextgen(object):
helper = TrafficStreamHelper(traffic_item, stream, param_id)
self.ixnet.setMultiAttribute(helper.transmissionControl,
- '-type', '{0}'.format(param['traffic_type']),
- '-duration', '{0}'.format(param['duration']))
+ '-type', '{0}'.format(param.get('traffic_type',
+ 'continuous')),
+ '-duration', '{0}'.format(param.get('duration',
+ "30")))
stream_frame_rate_path = helper.frameRate
self.ixnet.setMultiAttribute(stream_frame_rate_path, '-rate', param['iload'])
diff --git a/yardstick/network_services/traffic_profile/ixia_rfc2544.py b/yardstick/network_services/traffic_profile/ixia_rfc2544.py
index 28480b8e9..53a99bf0b 100644
--- a/yardstick/network_services/traffic_profile/ixia_rfc2544.py
+++ b/yardstick/network_services/traffic_profile/ixia_rfc2544.py
@@ -14,7 +14,6 @@
from __future__ import absolute_import
import logging
-import json
from yardstick.network_services.traffic_profile.traffic_profile import \
TrexProfile
@@ -24,60 +23,60 @@ LOG = logging.getLogger(__name__)
class IXIARFC2544Profile(TrexProfile):
+ UPLINK = 'uplink'
+ DOWNLINK = 'downlink'
+
def _get_ixia_traffic_profile(self, profile_data, mac=None, xfile=None, static_traffic=None):
if mac is None:
mac = {}
- if static_traffic is None:
- static_traffic = {}
-
result = {}
- if xfile:
- with open(xfile) as stream:
- try:
- static_traffic = json.load(stream)
- except Exception as exc:
- LOG.debug(exc)
-
- for traffickey, trafficvalue in static_traffic.items():
- traffic = static_traffic[traffickey]
- # outer_l2
- index = 0
+ for traffickey, values in profile_data.items():
+ if not traffickey.startswith((self.UPLINK, self.DOWNLINK)):
+ continue
+
try:
- for key, value in profile_data[traffickey].items():
- framesize = value['outer_l2']['framesize']
- traffic['outer_l2']['framesize'] = framesize
- traffic['framesPerSecond'] = True
- traffic['bidir'] = False
- traffic['outer_l2']['srcmac'] = \
- mac["src_mac_{}".format(traffic['id'])]
- traffic['outer_l2']['dstmac'] = \
- mac["dst_mac_{}".format(traffic['id'])]
-
- # outer_l3
- if "outer_l3v6" in list(value.keys()):
- traffic['outer_l3'] = value['outer_l3v6']
- srcip4 = value['outer_l3v6']['srcip6']
- traffic['outer_l3']['srcip4'] = srcip4.split("-")[0]
- dstip4 = value['outer_l3v6']['dstip6']
- traffic['outer_l3']['dstip4'] = dstip4.split("-")[0]
- else:
- traffic['outer_l3'] = value['outer_l3v4']
- srcip4 = value['outer_l3v4']['srcip4']
- traffic['outer_l3']['srcip4'] = srcip4.split("-")[0]
- dstip4 = value['outer_l3v4']['dstip4']
- traffic['outer_l3']['dstip4'] = dstip4.split("-")[0]
-
- traffic['outer_l3']['type'] = key
- traffic['outer_l3']['count'] = value['outer_l3v4']['count']
- # outer_l4
- traffic['outer_l4'] = value['outer_l4']
- index = index + 1
+ # values should be single-item dict, so just grab the first item
+ try:
+ key, value = next(iter(values.items()))
+ except StopIteration:
+ result[traffickey] = {}
+ continue
+
+ port_id = value.get('id', 1)
+ port_index = port_id - 1
+ try:
+ ip = value['outer_l3v6']
+ except KeyError:
+ ip = value['outer_l3v4']
+ src_key, dst_key = 'srcip4', 'dstip4'
+ else:
+ src_key, dst_key = 'srcip6', 'dstip6'
+
+ result[traffickey] = {
+ 'bidir': False,
+ 'iload': '100',
+ 'id': port_id,
+ 'outer_l2': {
+ 'framesize': value['outer_l2']['framesize'],
+ 'framesPerSecond': True,
+ 'srcmac': mac['src_mac_{}'.format(port_index)],
+ 'dstmac': mac['dst_mac_{}'.format(port_index)],
+ },
+ 'outer_l3': {
+ 'count': ip['count'],
+ 'dscp': ip['dscp'],
+ 'ttl': ip['ttl'],
+ src_key: ip[src_key],
+ dst_key: ip[dst_key],
+ 'type': key,
+ 'proto': ip['proto'],
+ },
+ 'outer_l4': value['outer_l4'],
+ }
except Exception:
continue
- result.update({traffickey: traffic})
-
return result
def _ixia_traffic_generate(self, traffic_generator, traffic, ixia_obj):
diff --git a/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py b/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py
index 22aaf6dfb..47c5a35d9 100644
--- a/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py
+++ b/yardstick/network_services/vnf_generic/vnf/tg_rfc2544_ixia.py
@@ -14,7 +14,6 @@
from __future__ import absolute_import
-import json
import time
import os
import logging
@@ -130,39 +129,28 @@ class IxiaResourceHelper(ClientResourceHelper):
self.client.ix_assign_ports()
- ixia_file = find_relative_file("ixia_traffic.cfg",
- self.scenario_helper.scenario_cfg["task_path"])
-
- static_traffic = {}
- with open(ixia_file) as stream:
- try:
- static_traffic = json.load(stream)
- except Exception:
- LOG.exception("")
mac = {}
- for vld_id, traffic in static_traffic.items():
- intfs = self.vnfd_helper.port_pairs.networks.get(vld_id, [])
- interface = next(iter(intfs), None)
- if interface:
- virt_intf = self.vnfd_helper.find_interface(name=interface)["virtual-interface"]
- # we only know static traffic id by reading the json
- # this is used by _get_ixia_traffic_profile
- mac["src_mac_{}".format(traffic["id"])] = virt_intf.get("local_mac", default)
- mac["dst_mac_{}".format(traffic["id"])] = virt_intf.get("dst_mac", default)
+ for port_name in self.vnfd_helper.port_pairs.all_ports:
+ intf = self.vnfd_helper.find_interface(name=port_name)
+ virt_intf = intf["virtual-interface"]
+ # we only know static traffic id by reading the json
+ # this is used by _get_ixia_trafficrofile
+ port_num = self.vnfd_helper.port_num(intf)
+ mac["src_mac_{}".format(port_num)] = virt_intf.get("local_mac", default)
+ mac["dst_mac_{}".format(port_num)] = virt_intf.get("dst_mac", default)
samples = {}
# Generate ixia traffic config...
try:
while not self._terminated.value:
- traffic_profile.execute_traffic(self, self.client, mac, ixia_file)
+ traffic_profile.execute_traffic(self, self.client, mac)
self.client_started.value = 1
time.sleep(WAIT_FOR_TRAFFIC)
self.client.ix_stop_traffic()
samples = self.generate_samples(traffic_profile.ports)
self._queue.put(samples)
status, samples = traffic_profile.get_drop_percentage(self, samples, min_tol,
- max_tol, self.client, mac,
- ixia_file)
+ max_tol, self.client, mac)
current = samples['CurrentDropPercentage']
if min_tol <= current <= max_tol or status == 'Completed':
@@ -175,13 +163,13 @@ class IxiaResourceHelper(ClientResourceHelper):
self._terminated.value = 1
return
- traffic_profile.execute_traffic(self, self.client, mac, ixia_file)
+ traffic_profile.execute_traffic(self, self.client, mac)
for _ in range(5):
time.sleep(self.LATENCY_TIME_SLEEP)
self.client.ix_stop_traffic()
samples = self.generate_samples(traffic_profile.ports, 'latency', {})
self._queue.put(samples)
- traffic_profile.start_ixia_latency(self, self.client, mac, ixia_file)
+ traffic_profile.start_ixia_latency(self, self.client, mac)
if self._terminated.value:
break