COMAC-176 Add sample configs for kubespray and OMEC for 3-nodes single cluster
Also move OMEC specific scripts from general scripts to comac directory.
Change-Id: I9fe71a288de39beef5175929ee8ae3bda3a298f7
diff --git a/comac/sample/kubespray-inventory/extra-vars.yaml b/comac/sample/kubespray-inventory/extra-vars.yaml
new file mode 100644
index 0000000..c4549ab
--- /dev/null
+++ b/comac/sample/kubespray-inventory/extra-vars.yaml
@@ -0,0 +1,55 @@
+# Copyright 2019-present Open Networking Foundation
+#
+# 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.
+
+# Sample kubespray override variables for COMAC deploy.
+# Pass this file as an extra variables when running kubespray. For example,
+# ansible-playbook -b -i inventory/comac/hosts.ini -e @inventory/comac/extra-vars.yaml cluster.yml
+# Tested with Kubespray release-2.11
+
+# OS
+disable_swap: true
+populate_inventory_to_hosts_file: true
+
+# etcd
+etcd_deployment_type: docker
+etcd_memory_limit: 8192M
+
+# Docker
+docker_iptables_enabled: true
+
+# K8S
+kubeadm_enabled: true
+kubelet_deployment_type: host
+kubectl_localhost: true
+kubeconfig_localhost: true
+
+kube_feature_gates: [SCTPSupport=True]
+kube_pods_subnet: 172.18.0.0/17
+kube_service_addresses: 172.18.128.0/17
+kube_apiserver_node_port_range: 2000-36767
+kube_network_plugin: calico
+kube_network_plugin_multus: true
+multus_version: stable
+ipip: false
+
+local_volume_provisioner_enabled: true
+
+# Applications
+dns_mode: coredns
+dns_cores_per_replica: 256
+dns_min_replicas: 1
+
+helm_enabled: true
+helm_deployment_type: host
+helm_version: v2.14.2
diff --git a/comac/sample/kubespray-inventory/group_vars b/comac/sample/kubespray-inventory/group_vars
new file mode 120000
index 0000000..a30ba68
--- /dev/null
+++ b/comac/sample/kubespray-inventory/group_vars
@@ -0,0 +1 @@
+../sample/group_vars
\ No newline at end of file
diff --git a/comac/sample/kubespray-inventory/hosts.ini b/comac/sample/kubespray-inventory/hosts.ini
new file mode 100644
index 0000000..06be3e8
--- /dev/null
+++ b/comac/sample/kubespray-inventory/hosts.ini
@@ -0,0 +1,50 @@
+# Copyright 2019-present Open Networking Foundation
+#
+# 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.
+
+[all]
+node1 ansible_host=10.0.0.240 etcd_member_name=etcd1
+node2 ansible_host=10.0.0.241 etcd_member_name=etcd2
+node3 ansible_host=10.0.0.242 etcd_member_name=etcd3
+
+[kube-master]
+node1
+node2
+node3
+
+[etcd]
+node1
+node2
+node3
+
+[kube-node]
+node1
+node2
+node3
+
+[k8s-cluster:children]
+kube-master
+kube-node
+
+[omec-cp]
+node1
+node2
+
+[omec-dp]
+node3
+
+[omec-cp:vars]
+node_labels={"omec-cp":"enabled"}
+
+[omec-dp:vars]
+node_labels={"omec-dp":"enabled"}
diff --git a/comac/sample/omec-override-values-multi.yaml b/comac/sample/omec-override-values-multi.yaml
new file mode 100644
index 0000000..a3db256
--- /dev/null
+++ b/comac/sample/omec-override-values-multi.yaml
@@ -0,0 +1,400 @@
+# Copyright 2019-present Open Networking Foundation
+#
+# 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.
+
+# Sample override values for 3-nodes cluster with SR-IOV configured on DP node.
+cassandra:
+ config:
+ cluster_size: 1
+
+config:
+ sriov:
+ resourceList:
+ vfio:
+ pfNames:
+ - eth2
+ netDevice:
+ pfNames:
+ - eth2
+ drivers:
+ - ixgbevf
+ mme:
+ cfgFiles:
+ config.json:
+ mme:
+ mcc:
+ dig1: 7
+ dig2: 3
+ dig3: 2
+ mnc:
+ dig1: 1
+ dig2: 1
+ dig3: 1
+ hss:
+ bootstrap:
+ enabled: true
+ users:
+ imsi: "732111000000420"
+ msisdn: "1122334455"
+ apn: apn1
+ key: "000102030405060708090a0b0c0d0e0f"
+ opc: "69d5c2eb2e2e624750541d3bbc692ba5"
+ numbers: 2
+ mme:
+ id: 1
+ isdn: "19136246000"
+ unreachability: 1
+ spgwu:
+ cpComm:
+ addr: 10.90.0.131
+ port: 30021
+ dpComm:
+ nodePort:
+ enabled: true
+ port: 30020
+ spgwc:
+ cpComm:
+ nodePort:
+ enabled: true
+ port: 30021
+ dpComm:
+ addr: 10.90.0.151
+ port: 30020
+ cfgFiles:
+ adc_rules.cfg: |
+ [GLOBAL]
+ NUM_ADC_RULES = 5
+
+ [ADC_RULE_1]
+ ADC_TYPE = 1
+ IP = 13.1.1.111
+
+ [ADC_RULE_2]
+ ADC_TYPE = 2
+ IP = 13.1.1.0
+ PREFIX = 24
+
+ [ADC_RULE_3]
+ ADC_TYPE = 1
+ IP = 13.1.1.112
+ PREFIX = 24
+
+ [ADC_RULE_4]
+ ADC_TYPE = 0
+ DOMAIN = www.example.gov
+
+ [ADC_RULE_5]
+ ADC_TYPE = 0
+ DOMAIN = www.drop_example.com
+ meter_profile.cfg: |
+ [GLOBAL]
+ NUM_OF_IDX = 7
+
+ [ENTRY_1]
+ ;Committed Information Rate (CIR). Measured in bytes per second.
+ ;MBR is mapped into CIR, convert MBR from bits to Bytes and set CIR.
+ CIR = 2342400
+ ;Committed Burst Size unit = Bytes
+ CBS = 5856
+ ;Excess Burst Size unit = Bytes
+ EBS = 11712
+ ;Meter profile index. Refer this index in static_pcc.cfg to set AMBR/MBR
+ MTR_PROFILE_IDX = 3
+
+ [ENTRY_2]
+ ;1200 = 1756800
+ ;1400 = 2049600
+ ;1600 = 2342400
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 4
+
+ [ENTRY_3]
+ ; QCI5,QCI7 15.571kbps = 1947 B
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 5
+
+ [ENTRY_4]
+ ; QCI1, 44kbps = 5500 B
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 6
+
+ [ENTRY_5]
+ ; QCI9, 31.143kbps = 3893 B
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 7
+
+ [ENTRY_6]
+ ; 128B, 7pps
+ CIR = 2342400
+ CBS = 512
+ EBS = 1024
+ MTR_PROFILE_IDX = 8
+
+ [ENTRY_7]
+ ; 128B, 2pps
+ CIR = 2342400
+ CBS = 512
+ EBS = 1024
+ MTR_PROFILE_IDX = 9
+
+ pcc_rules.cfg: |
+ [GLOBAL]
+ NUM_PCC_FILTERS = 9
+ ;To config AMBR/MBR values refer meter_profile.cfg. specify only the
+ ;meter profile index to be set here.
+ UL_AMBR_MTR_PROFILE_IDX = 3
+ DL_AMBR_MTR_PROFILE_IDX = 4
+
+ ;default filter - must be first for now (until DP doesn't install any filters)
+ ;associated with default adc rule
+ [PCC_FILTER_1]
+ RULE_NAME = DefaultRule
+ RATING_GROUP = 9
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 1
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 254
+ DROP_PKT_COUNT = 0
+ ;Specify the meter profile index from meter_profile.cfg
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of ADC filter indices
+ SDF_FILTER_IDX = 99998
+
+ [PCC_FILTER_2]
+ RULE_NAME = sdf_rule_1
+ RATING_GROUP = 5
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 2
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 1
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 5
+ DL_MBR_MTR_PROFILE_IDX = 5
+ ;List of SDF filter indices
+ SDF_FILTER_IDX = 1
+
+ [PCC_FILTER_3]
+ RULE_NAME = sdf_rule_2
+ RATING_GROUP = 1
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 3
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 18
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 6
+ DL_MBR_MTR_PROFILE_IDX = 6
+ ;List of SDF filter indices
+ SDF_FILTER_IDX = 2
+
+ [PCC_FILTER_4]
+ RULE_NAME = adc_rule_1
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Internet
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 8
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ REDIRECT_INFO = 0
+ SPONSOR_ID = Example
+ PRECEDENCE = 15
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 1
+
+ [PCC_FILTER_5]
+ RULE_NAME = adc_rule_2
+ RATING_GROUP = 0
+ SERVICE_ID = CIPA
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 9
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 4
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 0
+ DL_MBR_MTR_PROFILE_IDX = 0
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 2
+
+ [PCC_FILTER_6]
+ RULE_NAME = sdf_rule_3
+ RATING_GROUP = 7
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 4
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 17
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 5
+ DL_MBR_MTR_PROFILE_IDX = 5
+ ;List of SDF filter indices
+ SDF_FILTER_IDX = 3
+
+ [PCC_FILTER_7]
+ RULE_NAME = adc_rule_3
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Internet
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 5
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 210
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 4
+
+ [PCC_FILTER_8]
+ RULE_NAME = adc_rule_4
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Management
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 6
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 200
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 12
+
+ [PCC_FILTER_9]
+ RULE_NAME = adc_rule_5
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Provisioning
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 7
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 220
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 3
+ sdf_rules.cfg: |
+ [GLOBAL]
+ NUM_SDF_FILTERS = 4
+
+ [SDF_FILTER_1]
+ DIRECTION = downlink_only
+ IPV4_REMOTE = 13.2.1.113
+ IPV4_REMOTE_MASK = 255.255.255.0
+ PROTOCOL = 17
+ LOCAL_LOW_LIMIT_PORT = 0
+ LOCAL_HIGH_LIMIT_PORT = 65535
+ REMOTE_LOW_LIMIT_PORT = 0
+ REMOTE_HIGH_LIMIT_PORT = 65535
+
+ [SDF_FILTER_2]
+ DIRECTION = uplink_only
+ IPV4_LOCAL = 16.255.255.0
+ IPV4_LOCAL_MASK = 255.255.255.0
+ PROTOCOL = 17
+ LOCAL_LOW_LIMIT_PORT = 0
+ LOCAL_HIGH_LIMIT_PORT = 65535
+ REMOTE_LOW_LIMIT_PORT = 0
+ REMOTE_HIGH_LIMIT_PORT = 65535
+
+ [SDF_FILTER_3]
+ DIRECTION = downlink_only
+ IPV4_REMOTE = 130.10.0.0
+ IPV4_REMOTE_MASK = 255.255.0.0
+ PROTOCOL = 17
+ REMOTE_LOW_LIMIT_PORT = 5060
+ REMOTE_HIGH_LIMIT_PORT = 5060
+
+ [SDF_FILTER_4]
+ DIRECTION = uplink_only
+ IPV4_REMOTE = 103.1.0.0
+ IPV4_REMOTE_MASK = 255.255.0.0
+ PROTOCOL = 17
+ LOCAL_LOW_LIMIT_PORT = 17000
+ LOCAL_HIGH_LIMIT_PORT = 17010
+
+nodeSelectors:
+ enabled: true
diff --git a/comac/sample/omec-override-values.yaml b/comac/sample/omec-override-values.yaml
new file mode 100644
index 0000000..0ec90b0
--- /dev/null
+++ b/comac/sample/omec-override-values.yaml
@@ -0,0 +1,385 @@
+# Copyright 2019-present Open Networking Foundation
+#
+# 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.
+
+# Sample override values for 3-nodes cluster with SR-IOV configured on DP node.
+cassandra:
+ config:
+ cluster_size: 1
+
+config:
+ sriov:
+ resourceList:
+ vfio:
+ pfNames:
+ - eth2
+ netDevice:
+ pfNames:
+ - eth2
+ drivers:
+ - ixgbevf
+ mme:
+ cfgFiles:
+ config.json:
+ mme:
+ mcc:
+ dig1: 7
+ dig2: 3
+ dig3: 2
+ mnc:
+ dig1: 1
+ dig2: 1
+ dig3: 1
+ hss:
+ bootstrap:
+ enabled: true
+ users:
+ imsi: "732111000000420"
+ msisdn: "1122334455"
+ apn: apn1
+ key: "000102030405060708090a0b0c0d0e0f"
+ opc: "69d5c2eb2e2e624750541d3bbc692ba5"
+ numbers: 2
+ mme:
+ id: 1
+ isdn: "19136246000"
+ unreachability: 1
+ spgwc:
+ cfgFiles:
+ adc_rules.cfg: |
+ [GLOBAL]
+ NUM_ADC_RULES = 5
+
+ [ADC_RULE_1]
+ ADC_TYPE = 1
+ IP = 13.1.1.111
+
+ [ADC_RULE_2]
+ ADC_TYPE = 2
+ IP = 13.1.1.0
+ PREFIX = 24
+
+ [ADC_RULE_3]
+ ADC_TYPE = 1
+ IP = 13.1.1.112
+ PREFIX = 24
+
+ [ADC_RULE_4]
+ ADC_TYPE = 0
+ DOMAIN = www.example.gov
+
+ [ADC_RULE_5]
+ ADC_TYPE = 0
+ DOMAIN = www.drop_example.com
+
+ meter_profile.cfg: |
+ [GLOBAL]
+ NUM_OF_IDX = 7
+
+ [ENTRY_1]
+ ;Committed Information Rate (CIR). Measured in bytes per second.
+ ;MBR is mapped into CIR, convert MBR from bits to Bytes and set CIR.
+ CIR = 2342400
+ ;Committed Burst Size unit = Bytes
+ CBS = 5856
+ ;Excess Burst Size unit = Bytes
+ EBS = 11712
+ ;Meter profile index. Refer this index in static_pcc.cfg to set AMBR/MBR
+ MTR_PROFILE_IDX = 3
+
+ [ENTRY_2]
+ ;1200 = 1756800
+ ;1400 = 2049600
+ ;1600 = 2342400
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 4
+
+ [ENTRY_3]
+ ; QCI5,QCI7 15.571kbps = 1947 B
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 5
+
+ [ENTRY_4]
+ ; QCI1, 44kbps = 5500 B
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 6
+
+ [ENTRY_5]
+ ; QCI9, 31.143kbps = 3893 B
+ CIR = 2342400
+ CBS = 5856
+ EBS = 11712
+ MTR_PROFILE_IDX = 7
+
+ [ENTRY_6]
+ ; 128B, 7pps
+ CIR = 2342400
+ CBS = 512
+ EBS = 1024
+ MTR_PROFILE_IDX = 8
+
+ [ENTRY_7]
+ ; 128B, 2pps
+ CIR = 2342400
+ CBS = 512
+ EBS = 1024
+ MTR_PROFILE_IDX = 9
+ pcc_rules.cfg: |
+ [GLOBAL]
+ NUM_PCC_FILTERS = 9
+ ;To config AMBR/MBR values refer meter_profile.cfg. specify only the
+ ;meter profile index to be set here.
+ UL_AMBR_MTR_PROFILE_IDX = 3
+ DL_AMBR_MTR_PROFILE_IDX = 4
+
+ ;default filter - must be first for now (until DP doesn't install any filters)
+ ;associated with default adc rule
+ [PCC_FILTER_1]
+ RULE_NAME = DefaultRule
+ RATING_GROUP = 9
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 1
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 254
+ DROP_PKT_COUNT = 0
+ ;Specify the meter profile index from meter_profile.cfg
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of ADC filter indices
+ SDF_FILTER_IDX = 99998
+
+ [PCC_FILTER_2]
+ RULE_NAME = sdf_rule_1
+ RATING_GROUP = 5
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 2
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 1
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 5
+ DL_MBR_MTR_PROFILE_IDX = 5
+ ;List of SDF filter indices
+ SDF_FILTER_IDX = 1
+
+ [PCC_FILTER_3]
+ RULE_NAME = sdf_rule_2
+ RATING_GROUP = 1
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 3
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 18
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 6
+ DL_MBR_MTR_PROFILE_IDX = 6
+ ;List of SDF filter indices
+ SDF_FILTER_IDX = 2
+
+ [PCC_FILTER_4]
+ RULE_NAME = adc_rule_1
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Internet
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 8
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ REDIRECT_INFO = 0
+ SPONSOR_ID = Example
+ PRECEDENCE = 15
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 1
+
+ [PCC_FILTER_5]
+ RULE_NAME = adc_rule_2
+ RATING_GROUP = 0
+ SERVICE_ID = CIPA
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 9
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 4
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 0
+ DL_MBR_MTR_PROFILE_IDX = 0
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 2
+
+ [PCC_FILTER_6]
+ RULE_NAME = sdf_rule_3
+ RATING_GROUP = 7
+ SERVICE_ID = 0
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 4
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = 0
+ REDIRECT_INFO = 0
+ PRECEDENCE = 17
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 5
+ DL_MBR_MTR_PROFILE_IDX = 5
+ ;List of SDF filter indices
+ SDF_FILTER_IDX = 3
+
+ [PCC_FILTER_7]
+ RULE_NAME = adc_rule_3
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Internet
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 5
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 210
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 4
+
+ [PCC_FILTER_8]
+ RULE_NAME = adc_rule_4
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Management
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 6
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 200
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 12
+
+ [PCC_FILTER_9]
+ RULE_NAME = adc_rule_5
+ RATING_GROUP = Zero-Rate
+ SERVICE_ID = Provisioning
+ RULE_STATUS = 0
+ GATE_STATUS = 1
+ SESSION_CONT = 0
+ REPORT_LEVEL = 7
+ CHARGING_MODE = 0
+ METERING_METHOD = 0
+ MUTE_NOTIFY = 0
+ MONITORING_KEY = 0
+ SPONSOR_ID = Example
+ REDIRECT_INFO = 0
+ PRECEDENCE = 220
+ DROP_PKT_COUNT = 0
+ UL_MBR_MTR_PROFILE_IDX = 7
+ DL_MBR_MTR_PROFILE_IDX = 7
+ ;List of SDF filter indices
+ ADC_FILTER_IDX = 3
+ sdf_rules.cfg: |
+ [GLOBAL]
+ NUM_SDF_FILTERS = 4
+
+ [SDF_FILTER_1]
+ DIRECTION = downlink_only
+ IPV4_REMOTE = 13.2.1.113
+ IPV4_REMOTE_MASK = 255.255.255.0
+ PROTOCOL = 17
+ LOCAL_LOW_LIMIT_PORT = 0
+ LOCAL_HIGH_LIMIT_PORT = 65535
+ REMOTE_LOW_LIMIT_PORT = 0
+ REMOTE_HIGH_LIMIT_PORT = 65535
+
+ [SDF_FILTER_2]
+ DIRECTION = uplink_only
+ IPV4_LOCAL = 16.255.255.0
+ IPV4_LOCAL_MASK = 255.255.255.0
+ PROTOCOL = 17
+ LOCAL_LOW_LIMIT_PORT = 0
+ LOCAL_HIGH_LIMIT_PORT = 65535
+ REMOTE_LOW_LIMIT_PORT = 0
+ REMOTE_HIGH_LIMIT_PORT = 65535
+
+ [SDF_FILTER_3]
+ DIRECTION = downlink_only
+ IPV4_REMOTE = 130.10.0.0
+ IPV4_REMOTE_MASK = 255.255.0.0
+ PROTOCOL = 17
+ REMOTE_LOW_LIMIT_PORT = 5060
+ REMOTE_HIGH_LIMIT_PORT = 5060
+
+ [SDF_FILTER_4]
+ DIRECTION = uplink_only
+ IPV4_REMOTE = 103.1.0.0
+ IPV4_REMOTE_MASK = 255.255.0.0
+ PROTOCOL = 17
+ LOCAL_LOW_LIMIT_PORT = 17000
+ LOCAL_HIGH_LIMIT_PORT = 17010
+
+nodeSelectors:
+ enabled: true
diff --git a/scripts/omec-nodesetup.sh b/comac/scripts/node-setup.sh
similarity index 94%
rename from scripts/omec-nodesetup.sh
rename to comac/scripts/node-setup.sh
index e84bbb4..a39560d 100755
--- a/scripts/omec-nodesetup.sh
+++ b/comac/scripts/node-setup.sh
@@ -43,7 +43,7 @@
pfpci=$(readlink /sys/devices/pci*/*/*/net/"$SRIOV_PF"/device | awk '{print substr($1,10)}')
num_vfs=$(cat /sys/class/net/"$SRIOV_PF"/device/sriov_numvfs)
if [ "$num_vfs" = "0" ]; then
- echo "FAIL: SR-IOV VFs are not created"
+ echo "INFO: SR-IOV VF does not exist"
return 1
fi
@@ -55,7 +55,7 @@
vfpci=$(ls -l /sys/devices/pci*/*/"$pfpci" | awk -v vfn=$vfn 'vfn==$9 {print substr($11,4)}')
driver=$(lspci -vvv -s "$vfpci" | grep "Kernel driver in use" | awk '{print $5}')
if [ "$driver" != "vfio-pci" ]; then
- echo "FAIL: SR-IOV VF $idx does not exist or bind to vfio-pci"
+ echo "INFO: SR-IOV VF $idx does not exist or is not binded to vfio-pci"
return 1
fi
done
@@ -106,7 +106,7 @@
# --------------------------
if ! compgen -G "/sys/class/iommu/*/devices" > /dev/null; then
disabled=1
- echo "FAIL: IOMMU is disabled"
+ echo "INFO: IOMMU is disabled"
update_grub_cmdline "intel_iommu=on"
else
echo " OK: IOMMU is enabled"
@@ -117,7 +117,7 @@
hugepage=$(grep -i HugePages_Total /proc/meminfo | awk '{print $2}') || true
if [ "$hugepage" -eq "0" ]; then
disabled=1
- echo "FAIL: Hugepage is disabled"
+ echo "INFO: Hugepage is disabled"
update_grub_cmdline "hugepages=$NR_HUGEPAGE"
update_grub_cmdline "default_hugepagesz=1G"
diff --git a/scripts/sriov.sh b/comac/scripts/sriov.sh
similarity index 100%
rename from scripts/sriov.sh
rename to comac/scripts/sriov.sh