Keita NISHIMOTO | d771cd1 | 2018-06-07 08:37:24 +0900 | [diff] [blame] | 1 | # 1. Overview |
| 2 | |
| 3 | The BBSim (Broadband Simulator) is for emulating the control message response sent from OLTs and ONUs which are connected to VOLTHA Adapter. |
| 4 | It is implemetend as a software process which runs outside VOLTHA, and acts as if it was multiple OLTs and ONUs. |
| 5 | This enables the scalability test of VOLTHA without actual hardware OLTs / ONUs. |
| 6 | The difference from the existing PONsim is to focus on emulating control messages, not data-path traffic which PONsim targets. |
| 7 | |
| 8 | It currently supports the following VOLTHA mode: |
| 9 | (Reference to https://github.com/opencord/voltha/blob/master/BUILD.md) |
| 10 | * Run in stand-alone mode |
| 11 | * Run with the "voltha ensamble" |
| 12 | |
| 13 | **Please note: Kubernetes mode is NOT supported by the current version.** |
| 14 | |
| 15 | ============== |
| 16 | VOLTHA |
| 17 | OpenOLT Adapter |
| 18 | ============== |
| 19 | ||| |
| 20 | ||| gRPC connections |
| 21 | ||| |
| 22 | ============== |
| 23 | BBSim |
| 24 | ============== |
| 25 | |
| 26 | # 2. PON Simulator Usage |
| 27 | |
| 28 | ``` |
| 29 | Usage of ./bbsim: |
| 30 | -H |
| 31 | IP and Port number which BBSim listens (default 172.17.0.1:50060) |
| 32 | -N |
| 33 | Number of OLTs |
| 34 | -i |
| 35 | Number of PON interfaces provided per OLT |
| 36 | -n |
| 37 | Number of ONUs per PON interface |
| 38 | ``` |
| 39 | |
| 40 | # 3. Requirements |
| 41 | |
| 42 | # Golang Installation |
| 43 | |
| 44 | If you plan on running the simulator locally, i.e. not in a container, you will need to first |
| 45 | install setup Golang on your system. Install using existing packages for your operating system |
| 46 | or issue the following commands (Linux). |
| 47 | |
| 48 | ``` |
| 49 | cd /tmp |
| 50 | wget https://storage.googleapis.com/golang/go1.9.3.linux-amd64.tar.gz |
| 51 | tar -C /usr/local -xzf /tmp/go1.9.3.linux-amd64.tar.gz |
| 52 | rm -f /tmp/go1.9.3.linux-amd64.tar.gz |
| 53 | mkdir ~/go |
| 54 | ``` |
| 55 | |
| 56 | Edit your profile (e.g. .bashrc) and add the following configuration |
| 57 | |
| 58 | ``` |
| 59 | export GOROOT=/usr/local/go |
| 60 | export GOPATH=~/go |
| 61 | export PATH=$PATH:$GOROOT/bin:$GOPATH/bin |
| 62 | ``` |
| 63 | |
| 64 | # 4. Run BBSim and VOLTHA-CLI commands |
| 65 | |
| 66 | ``` |
| 67 | # in VOLTHA docker |
| 68 | cd /cord/incubator/voltha/voltha/bbsim |
| 69 | ./bbsim -H 172.17.0.1:50060 -N 1 -i 1 -n 16 |
| 70 | |
| 71 | # After this, execute the following commands from VOLTHA-CLI |
| 72 | (voltha) health |
| 73 | { |
| 74 | "state": "HEALTHY" |
| 75 | } |
| 76 | (voltha) preprovision_olt -t openolt -H 172.17.0.1:50060 |
| 77 | success (device id = <deviceid>) |
| 78 | (voltha) enable |
| 79 | enabling <deviceid> |
| 80 | waiting for device to be enabled... |
| 81 | success (device id = <deviceid>) |
| 82 | (voltha) devices |
| 83 | ## You can see the list of devices (OLT/ONUs) ## |
| 84 | ``` |
| 85 | |