|
|
This tutorila illustrates an example on how to build kube5g and deploy LTE-OAI network on kubernets.
|
|
|
|
|
|
|
|
|
More tutorials are availables on [kube5g-tutorials](https://gitlab.eurecom.fr/osama.arouk/kube5g/wikis/home)
|
|
|
|
|
|
# How to deploy OAI-LTE using Kubernetes
|
|
|
|
|
|
## Requirements
|
|
|
The following requirements shall be met to sucessfully deploy 4G network using docker:
|
|
|
* One PC with Ubuntu 16.04/18.04 with (preferable) 8GB RAM
|
|
|
* Kubernetes deployment microk8s
|
|
|
* Snap enabled
|
|
|
* An USRP (as frontend) attached to the PC
|
|
|
* Commecial phone equipped with SIM card to be connected to the network
|
|
|
|
|
|
|
|
|
For this tutorial we use the following:
|
|
|
- GigaByte Box with ubuntu 16.04 and 16 BG RAM
|
|
|
- microk8s version: v1.14.10
|
|
|
- kubectl version: 1.17.3
|
|
|
- USRP: B210 mini
|
|
|
- Phone: Google pixel 2
|
|
|
|
|
|
The following figure illustrates the network that we will deploy. It is composed of i) mysql ii) oai-cn iii) oai-ran.
|
|
|
|
|
|
![Fig_oai_lte](https://i.imgur.com/wDSQiza.jpg)
|
|
|
|
|
|
## kube5g setup
|
|
|
*
|
|
|
|
|
|
* Use the build_m5g script to install the requirements of kube5g
|
|
|
```bash
|
|
|
$ ./build_m5g --install-kube5g-req
|
|
|
````
|
|
|
|
|
|
* Use the build_m5g script to build kube5g:
|
|
|
```bash
|
|
|
$ ./build_m5g -k
|
|
|
````
|
|
|
|
|
|
* Add ```--allow-privileged=true``` to both kubelet and kube-apiserver the microk8s, and then restart the services
|
|
|
- Edit the files
|
|
|
```bash
|
|
|
# kubelet config. Note that you can you your favirite editor, f.g. vim, nano, etc.
|
|
|
sudo vim /var/snap/microk8s/current/args/kubelet
|
|
|
```
|
|
|
```bash
|
|
|
#kube-apiserver config. Note that you can you your favirite editor, f.g. vim, nano, etc.
|
|
|
sudo vim /var/snap/microk8s/current/args/kube-apiserver
|
|
|
```
|
|
|
- Restart services:
|
|
|
```bash
|
|
|
sudo systemctl restart snap.microk8s.daemon-kubelet.service
|
|
|
sudo systemctl restart snap.microk8s.daemon-apiserver.service
|
|
|
```
|
|
|
* Apply the manifest in oai-cn and oai-ran (in order).
|
|
|
```bash
|
|
|
kubectl apply -f kube5g/kubernetes/lte/oai-cn/
|
|
|
kubectl apply -f /kube5g/kubernetes/lte/oai-ran/
|
|
|
```
|
|
|
|
|
|
At this stage, the USRP should start functioning after certain time
|
|
|
|
|
|
In order to shutdown the network, type the following:
|
|
|
```bash
|
|
|
kubectl delete -f /kube5g/kubernetes/lte/oai-cn/
|
|
|
kubectl delete -f /kube5g/kubernetes/lte/oai-ran/
|
|
|
```
|
|
|
You may also want to stop microk8s by typing ```microk8s.stop``` in the terminal |
|
|
\ No newline at end of file |