- docker
- helm
- k8s
curl -fsSL https://get.docker.com -o get-docker.sh
sudo sh get-docker.sh
Docker without sudo:
sudo usermod -aG docker $USER
newgrp docker
curl -fsSL -o get_helm.sh https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3
chmod 700 get_helm.sh
./get_helm.sh
- Add Kubernetes Signing Key
curl -s https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add
- Add Software Repositories
sudo apt-add-repository "deb http://apt.kubernetes.io/ kubernetes-xenial main"
PS.: if it fails on finding apt-add-repository command, install the package below:
sudo apt-get install software-properties-common -y
- Kubernetes Installation Tools
sudo apt-get install kubeadm kubelet kubectl
sudo apt-mark hold kubeadm kubelet kubectl
- disabling the swap memory on each server:
sudo swapoff -a
- Assign Unique Hostname for Each Server Node
sudo hostnamectl set-hostname master-node
- Initialize Kubernetes on Master Node
sudo kubeadm init --pod-network-cidr=10.244.0.0/16
PS.: in case of error
[ERROR CRI]: container runtime is not running: output: time="2020-09-24T11:49:16Z" level=fatal msg="getting status of runtime failed: rpc error: code = Unimplemented desc = unknown service runtime.v1alpha2.RuntimeService"
, error: exit status 1
follow the steps below and retry the init:
rm /etc/containerd/config.toml
systemctl restart containerd
- to create a directory for the cluster:
mkdir -p $HOME/.kube
sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
sudo chown $(id -u):$(id -g) $HOME/.kube/config
- Deploy Pod Network to Cluster
kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/master/Documentation/kube-flannel.yml
OBS: if the pod got tainted do:
kubectl taint nodes --all node-role.kubernetes.io/master-
in case of any other taint errors, use 'kubectl describe node' to find out more about it (check the field: Taints)
# Add project helm repositories
helm repo add cord https://charts.opencord.org
helm repo add atomix https://charts.atomix.io
helm repo add onos https://charts.onosproject.org
helm repo add sdran https://sdrancharts.onosproject.org
# Update repository helm
helm repo update
# Install atomix
helm install atomix-controller atomix/atomix-controller -n kube-system --version 0.6.9
helm install atomix-raft-storage atomix/atomix-raft-storage -n kube-system --version 0.1.25
# Install Onos-operator
helm install -n kube-system onos-operator onos/onos-operator --version 0.5.2
# Install ran-simulator e do onos-kpimon flags
helm -n sdran install sd-ran sdran/sd-ran --set import.ran-simulator.enabled=true --set import.onos-kpimon.enabled=true --set ran-simulator.pci.modelName=your-modal-name --version 1.4.2
helm install -n sdran onos-exporter sdran/onos-exporter --set import.fluent-bit.enabled=true --set import.opensearch.enabled=true --set import.prometheus-stack.enabled=true
OBS
: Precisa realizar o seguinte ajuste devido o opensearch e em seguida restartar o docker:
sysctl -w vm.max_map_count=262144
systemctl restart docker.service
obs: nao está funcionando dessa forma e está passando atraves da flag --set ran-simulator.pci.modelName=two-cell-two-node-model.
Por default, o RANSim usa o model.yaml como arquivo modelo. Para usar um diferente específico deve-se:
Dentro do pod onos-cli executar:
wget https://raw.githubusercontent.com/onosproject/sdran-helm-charts/master/ran-simulator/files/model/model-5cell-100ue.yaml
onos ransim load --data=/home/onos/model-5cell-100ue.yaml --data-name=model-5cell-100ue.yaml