blob: e468e46191734371e805757cf0d137f0ea4f8c52 [file] [log] [blame]
Larry Petersondef1b672023-08-07 14:06:24 -07001Physical RAN
2---------------
llpb3534642023-08-02 09:23:52 -07003
4We are now ready to replace the emulated RAN with physical gNBs and
5real UEs. You will need to edit ``hosts.ini`` to reflect the Aether
6cluster you want to support, where just a single server is sufficient
7and there is no reason to include nodes in the ``[gnbsim_nodes]`` set.
Larry Peterson5dc197c2023-10-02 14:31:06 -07008
9In addition to the server(s) in your cluster, bringing up a physical
10RAN requires the following hardware:
11
12* One or more 5G small cell radios (e.g., MOSO CANOPY 5G INDOOR SMALL CELL).
13* One or more 5G-capable UEs (e.g., unlocked Moto G 5G).
14* A SIM reader/writer and associated software (e.g., OYEITIMES MCR3516).
15* A set of programmable SIM cards (5 blank cards included with reader).
16
17There are multiple options for each component, but finding a
18combination that works together can be challenging. This section makes
19several recommendations based on working end-to-end systems. For
20simplicity, we pared the above list back to a single example for each
21item, but these should not be interpreted as the only possibility.
22
23.. admonition:: Troubleshooting Hint
24
25 We are tracking community experience with different hardware in the
26 ``#aether-onramp`` channel of the `ONF Workspace
27 <https://onf-community.slack.com/>`__, where the ``Troubleshooting``
28 bookmark for that channel includes summaries of different
29 combinations people have tried.
30
Larry Peterson782fec32023-10-09 12:30:57 -070031This blueprint assumes you start with a variant of ``vars/main.yml``
32customized for running physical 5G radios. This is easy to do:
llpb3534642023-08-02 09:23:52 -070033
34.. code-block::
35
36 $ cd vars
37 $ cp main-gNB.yml main.yml
38
Larry Peterson5dc197c2023-10-02 14:31:06 -070039This section focuses on bringing up a single gNB that is on the same
40L2 network as the Aether cluster. In our running example, this implies
41both are on subnet ``10.76.28.0/24``.
llpb3534642023-08-02 09:23:52 -070042
Larry Peterson8b1ed832023-08-29 12:06:06 -070043.. admonition:: Troubleshooting Hint
44
45 Physical gNBs connect to SD-Core (both the AMF in the control plane
46 and the UPF in the user plane) in exactly the same way as external
47 instances of gNBsim. Going through the process of bringing up gNBsim
48 in a second server, as described in the previous section, is a good
49 way to validate that your Core is "gNB-ready".
50
51
llpb3534642023-08-02 09:23:52 -070052Modify Configuration
53~~~~~~~~~~~~~~~~~~~~~~~~
54
55Modify the ``core`` section of ``vars/main.yml`` to match the
56following, substituting your local details for ``ens18`` and
57``10.76.28.113``. Of particular note, setting ``ran_subnet`` to the
58empty string indicates that the gNB is connected to the same physical
59L2 network as your Aether cluster, and the new ``values_file`` is
60tailored for a physical RAN rather than the emulated RAN we've been
61using.
62
63.. code-block::
64
65 core:
66 standalone: "true"
67 data_iface: ens18
68 values_file: "deps/5gc/roles/core/templates/radio-5g-values.yaml"
69 ran_subnet: ""
70 helm:
71 chart_ref: aether/sd-core
72 chart_version: 0.12.6
73 upf:
74 ip_prefix: "192.168.252.0/24"
75 amf:
76 ip: "10.76.28.113"
77
78
79Prepare UEs
80~~~~~~~~~~~~
81
Larry Petersond3294df2023-09-13 10:35:38 -040082When selecting UEs to connect to Aether, be aware that not all phones
83support the CBRS frequency bands that Aether uses. For band n78,
84Aether is known to work with recent iPhones (11 and greater), Google
85Pixel phones (4 and greater), OnePlus phones, and Moto G 5G
86phones. For band n48, Aether is known to work with Moto G 5G and
87OnePlus phones; Pixel 7 phones are purported to work as well. Another
88option is to use a 5G dongle connected to a Raspberry Pi as a
89demonstration UE. This makes it easier to run diagnostic tests from
90the UE. For example, we have used `APAL's 5G dongle
91<https://www.apaltec.com/dongle/>`__ with Aether.
92
llpb3534642023-08-02 09:23:52 -0700935G-connected devices must have a SIM card, which you are responsible
Larry Peterson5dc197c2023-10-02 14:31:06 -070094for programming and inserting. You will need a SIM card writer, such
95as the *OYEITIMES MCR3516* (available on Amazon), which comes with
96five blank cards. You will need to set the PLMN identifier
97(constructed from a valid MCC/MNC pair), the IMSI, and two secret keys
98for each SIM card. As working examples, we have used two different
99PLMN ids: ``315010`` constructed from MCC=315 (US) and MNC=010 (CBRS),
100and ``00101`` constructed from MCC=001 (TEST) and MNC=01 (TEST). You
101should use whatever values are appropriate for your local environment,
102where we use the following as a running example throughout this
103section:
llpb3534642023-08-02 09:23:52 -0700104
105* IMSI: each one is unique, matching pattern ``315010*********`` (up to 15 digits)
106* OPc: ``69d5c2eb2e2e624750541d3bbc692ba5``
107* Key: ``000102030405060708090a0b0c0d0e0f``
108
Larry Peterson505d4b32023-08-21 14:39:45 -0700109Note that the actual config files distributed with OnRamp have IMSIs
110constructed using PLMN id ``00101``. Both sets of examples are taken
Larry Peterson5d6b3b32023-09-05 15:11:55 -0700111from working deployments (``315010`` for a 4G/eNB and ``00101`` for a
1125G/gNB), so in principle either should work as a model you can emulate
113in your deployment. As a practical matter, however, it is certainly
114easiest (and safest) to start with the existing code.
Larry Peterson505d4b32023-08-21 14:39:45 -0700115
Larry Petersond3294df2023-09-13 10:35:38 -0400116After inserting the SIM card into the device and powering it up, log
Larry Peterson077f5882023-09-20 16:14:30 -0700117into the phone, select ``Network Settings > SIMs`` and create a new
118*Access Point Name (APN)*, configured as shown in :numref:`Figure %s
119<fig-apn>`. The entry name (``TEST SIM`` in the example) is arbitrary
120and the MCC/MNC pair is set automatically based on the newly inserted
121SIM card. The important value is the APN, which is set to
122``internet``. This value corresponds to variable ``dnn`` (*Data
123Network Name*) defined in
124``deps/5gc/roles/core/templates/radio-5g-values.yaml``. Loosely
125speaking, the role the APN plays in the mobile network is similar to
126the role an SSID plays in a WiFi network.
127
128.. _fig-apn:
129.. figure:: figures/Slide26.png
130 :width: 400px
131 :align: center
132
133 Configure an Access Point Name (APN) for the new SIM card on the UE.
llpb3534642023-08-02 09:23:52 -0700134
135Finally, modify the ``subscribers`` block of the
136``omec-sub-provision`` section in file
137``deps/5gc/roles/core/templates/radio-5g-values.yaml`` to record the IMSI,
138OPc, and Key values configured onto your SIM cards. The block also
139defines a sequence number that is intended to thwart replay
140attacks. For example, the following code block adds IMSIs between
141``315010999912301`` and ``315010999912310``:
142
143.. code-block::
144
145 subscribers:
146 - ueId-start: "315010999912301"
147 ueId-end: "315010999912310"
148 plmnId: "315010"
149 opc: "69d5c2eb2e2e624750541d3bbc692ba5"
150 key: "000102030405060708090a0b0c0d0e0f"
151 sequenceNumber: 135
152
153Further down in the same ``omec-sub-provision`` section you will find
154two other blocks that also need to be edited. The first,
155``device-groups``, assigns IMSIs to *Device Groups*. You will need to
156reenter the individual IMSIs from the ``subscribers`` block that will
157be part of the device-group:
158
159.. code-block::
160
161 device-groups:
162 - name: "5g-user-group1"
163 imsis:
164 - "315010999912301"
165 - "315010999912302"
166 - "315010999912303"
167
168The second block, ``network-slices``, sets various parameters
169associated with the *Slices* that connect device groups to
170applications. Here, you will need to reenter the PLMN information,
171with the other slice parameters remaining unchanged (for now):
172
173.. code-block::
174
175 plmn:
176 mcc: "315"
177 mnc: "010"
178
179Aether supports multiple *Device Groups* and *Slices*, but the data
180entered here is purposely minimal; it's just enough to bring up and
181debug the installation. Over the lifetime of a running system,
182information about *Device Groups* and *Slices* (and the other
183abstractions they build upon) should be entered via the ROC, as
184described the section on Runtime Control. When you get to that point,
185Ansible variable ``standalone`` in ``vars/main.yml`` (which
186corresponds to the override value assigned to
187``provision-network-slice`` in ``radio-5g-values.yaml``) should be set
188to ``false``. Doing so causes the ``device-groups`` and
189``network-slices`` blocks of ``radio-5g-values.yaml`` to be
190ignored. The ``subscribers`` block is always required to configure
191SD-Core.
192
193
194Bring Up Aether
195~~~~~~~~~~~~~~~~~~~~~
196
197You are now ready to bring Aether on-line. We assume a fresh install
Larry Petersondef1b672023-08-07 14:06:24 -0700198by typing the following:
llpb3534642023-08-02 09:23:52 -0700199
200.. code-block::
201
202 $ make aether-k8s-install
203 $ make aether-5gc-install
204
205You can verify the installation by running ``kubectl`` just as you did
206in earlier stages. Note that we postpone bringing up the AMP until
207later so as to have fewer moving parts to debug.
208
209
210gNodeB Setup
211~~~~~~~~~~~~~~~~~~~~
212
213Once the SD-Core is up and running, we are ready to bring up the
214physical gNB. The details of how to do this depend on the specific
215device you are using, but we identify the main issues you need to
Larry Peterson5d6b3b32023-09-05 15:11:55 -0700216address using SERCOMM's 5G femto cell (as distributed by MosoLabs) as
217an example. That particular device uses either the n48 or n78 band and
Larry Petersond3294df2023-09-13 10:35:38 -0400218is on the ONF MarketPlace, where you can also find a User's Guide that
219gives detailed instructions about configuring the gNB.
llpb3534642023-08-02 09:23:52 -0700220
221.. _reading_sercomm:
222.. admonition:: Further Reading
223
Larry Peterson5d6b3b32023-09-05 15:11:55 -0700224 `MOSO CANOPY 5G INDOOR SMALL CELL
225 <https://opennetworking.org/products/moso-canopy-5g-indoor-small-cell/>`__.
226
227.. admonition:: Troubleshooting Hint
228
229 The product data sheet shows support for frequency bands
230 n78/n48/n77, but individual devices do not necessarily support all
231 three. For example, we have experience with an n78 device and an n48
Larry Peterson5dc197c2023-10-02 14:31:06 -0700232 device, with the latter (n48) becoming the preferred band (due in
233 part to less risk of interfering with Radio Altimeters). For n48,
234 PLMN id ``00101`` is currently recommended.
llpb3534642023-08-02 09:23:52 -0700235
236For the purposes of the following description, we assume the gNB is
237assigned IP address ``10.76.28.187``, which per our running example,
238is on the same L2 network as our Aether server (``10.76.28.113``).
Larry Petersondef1b672023-08-07 14:06:24 -0700239:numref:`Figure %s <fig-sercomm>` shows a screenshot of the SERCOMM
llpb3534642023-08-02 09:23:52 -0700240gNB management dashboard, which we reference in the instructions that
241follow:
242
243.. _fig-sercomm:
244.. figure:: figures/Sercomm.png
245 :width: 500px
246 :align: center
247
248 Management dashboard on the Sercomm gNB, showing the dropdown
249 ``Settings`` menu overlayed on the ``NR Cell Configuration`` page
250 (which shows default radio settings).
251
252
2531. **Connect to Management Interface.** Start by connecting a laptop
254 directly to the LAN port on the small cell, pointing your laptop's
255 web browser at the device's management page
256 (``https://10.10.10.189``). You will need to assign your laptop an
257 IP address on the same subnet (e.g., ``10.10.10.100``). Once
258 connected, log in with the credentials provided by the vendor.
259
2602. **Configure WAN.** Visit the ``Settings > WAN`` page to configure
261 how the small cell connects to the Internet via its WAN port,
262 either dynamically using DHCP or statically by setting the device's
263 IP address (``10.76.28.187``) and default gateway (``10.76.28.1``).
264
2653. **Access Remote Management.** Once on the Internet, it should be
266 possible to reach the management dashboard without being directly
267 connected to the LAN port (``https://10.76.28.187``).
268
2694. **Connect GPS.** Connect the small cell's GPS antenna to the GPS
270 port, and place the antenna so it has line-of-site to the sky
271 (i.e., place it in a window). The ``Status`` page of the management
272 dashboard should report its latitude, longitude, and fix time.
273
2745. **Spectrum Access System.** One reason the radio needs GPS is so it
275 can report its location to a Spectrum Access System (SAS), a
276 requirement in the US to coordinate access to the CBRS Spectrum in
277 the 3.5 GHz band. For example, the production deployment of Aether
278 uses the `Google SAS portal
279 <https://cloud.google.com/spectrum-access-system/docs/overview>`__,
280 which the small cell can be configured to query periodically. To do
281 so, visit the ``Settings > SAS`` page. Acquiring the credentials
282 needed to access the SAS requires you go through a certification
283 process, but as a practical matter, it may be possible to test an
284 isolated/low-power femto cell indoors before completing that
285 process. Consult with your local network administrator.
286
2876. **Configure Radio Parameters.** Visit the ``Settings > NR Cell
288 Configuration`` page (shown in the figure) to set parameters that
289 control the radio. It should be sufficient to use the default
290 settings when getting started.
291
2927. **Configure the PLMN.** Visit the ``Settings > 5GC`` page to set
293 the PLMN identifier on the small cell (``00101``) to match the
294 MCC/MNC values (``001`` / ``01`` ) specified in the Core.
295
2968. **Connect to Aether Control Plane.** Also on the ``Settings > 5GC``
297 page, define the AMF Address to be the IP address of your Aether
298 server (e.g., ``10.76.28.113``). Aether's SD-Core is configured to
299 expose the corresponding AMF via a well-known port, so the server's
300 IP address is sufficient to establish connectivity. The ``Status``
301 page of the management dashboard should confirm that control
302 interface is established.
303
3049. **Connect to Aether User Plane.** As described in an earlier
305 section, the Aether User Plane (UPF) is running at IP address
306 ``192.168.252.3``. Connecting to that address requires installing a
307 route to subnet ``192.168.252.0/24``. How you install this route is
308 device and site-dependent. If the small cell provides a means to
309 install static routes, then a route to destination
310 ``192.168.252.0/24`` via gateway ``10.76.28.113`` (the server
311 hosting Aether) will work. If the small cell does not allow static
312 routes (as is the case for the SERCOMM gNB), then ``10.76.28.113``
313 can be installed as the default gateway, but doing so requires that
314 your server also be configured to forward IP packets on to the
315 Internet.
316
Larry Petersond3294df2023-09-13 10:35:38 -0400317.. admonition:: Troubleshooting Hint
318
319 For the SERCOMM gNB, if you elect to enable GPS, then ``Setting >
320 Sync_Settings > Sync_Mode`` should be set to ``TIME``. With GPS and
321 PTP disabled, ``Setting > Sync_Settings > Sync_Mode`` should be set
322 to ``FREE_RUNNING``.
323
324.. admonition:: Troubleshooting Hint
325
326 For the SERCOMM gNB, we recommend the following when the gNB's
327 addresses is acquired via DHCP, assuming that address is unlikely to
328 change. When configuring the WAN (via the LAN), start with DHCP
329 enabled. Note the IP address the gNB has been assigned, and then
330 after disconnecting from the LAN, connect to the GUI via this
331 address. You will be on the same L2 subnet as the Aether server,
332 which you should be able to ping using the gNBs diagnostic tool.
333 The default gateway DHCP returns does not know how to route data
334 packets to the UPF. To fix this, modify the WAN settings to use a
335 static IP, with the DHCP-provided IP used as the gNB's static
336 address. Then set the default gateway to the IP address of your
337 Aether server.
338
llpb3534642023-08-02 09:23:52 -0700339Run Diagnostics
340~~~~~~~~~~~~~~~~~
341
342Successfully connecting a UE to the Internet is not a straightforward
343exercise. It involves configuring the UE, gNB, and SD-Core software in
344a consistent way; establishing SCTP-based control plane (N2) and
345GTP-based user plane (N3) connections between the base station and
346Mobile Core; and traversing multiple IP subnets along the end-to-end
347path.
348
349The UE and gNB provide limited diagnostic tools. For example, it's
350possible to run ``ping`` and ``traceroute`` from both. You can also
351run the ``ksniff`` tool described in the Networking section, but the
352most helpful packet traces you can capture are shown in the following
353commands. You can run these on the Aether server, where we use our
354example ``ens18`` interface for illustrative purposes:
355
356.. code-block::
357
358 $ sudo tcpdump -i any sctp -w sctp-test.pcap
359 $ sudo tcpdump -i ens18 port 2152 -w gtp-outside.pcap
360 $ sudo tcpdump -i access port 2152 -w gtp-inside.pcap
361 $ sudo tcpdump -i core net 172.250.0.0/16 -w n6-inside.pcap
362 $ sudo tcpdump -i ens18 net 172.250.0.0/16 -w n6-outside.pcap
363
364The first trace, saved in file ``sctp.pcap``, captures SCTP packets
365sent to establish the control path between the base station and the
366Mobile Core (i.e., N2 messages). Toggling "Mobile Data" on the UE,
367for example by turning Airplane Mode off and on, will generate the
368relevant control plane traffic.
369
370The second and third traces, saved in files ``gtp-outside.pcap`` and
371``gtp-inside.pcap``, respectively, capture GTP packets (tunneled
372through port ``2152`` ) on the RAN side of the UPF. Setting the
373interface to ``ens18`` corresponds to "outside" the UPF and setting
374the interface to ``access`` corresponds to "inside" the UPF. Running
375``ping`` from the UE will generate the relevant user plane (N3) traffic.
376
377Similarly, the fourth and fifth traces, saved in files
378``n6-inside.pcap`` and ``n6-outside.pcap``, respectively, capture IP
379packets on the Internet side of the UPF (which is known as the **N6**
380interface in 3GPP). In these two tests, ``net 172.250.0.0/16``
381corresponds to the IP addresses assigned to UEs by the SMF. Running
382``ping`` from the UE will generate the relevant user plane traffic.
383
384If the ``gtp-outside.pcap`` has packets and the ``gtp-inside.pcap``
385is empty (no packets captured), you may run the following commands
386to make sure packets are forwarded from the ``ens18`` interface
387to the ``access`` interface and vice versa:
388
389.. code-block::
390
391 $ sudo iptables -A FORWARD -i ens18 -o access -j ACCEPT
392 $ sudo iptables -A FORWARD -i access -o ens18 -j ACCEPT
Larry Petersondef1b672023-08-07 14:06:24 -0700393
394Support for eNBs
395~~~~~~~~~~~~~~~~~~
396
397Aether OnRamp is geared towards 5G, but it does support physical eNBs,
398including 4G-based versions of both SD-Core and AMP. It does not
Larry Peterson782fec32023-10-09 12:30:57 -0700399support an emulated 4G RAN. The 4G blueprint uses all the same Ansible
400machinery outlined in earlier sections, but starts with a variant of
Larry Petersondef1b672023-08-07 14:06:24 -0700401``vars/main.yml`` customized for running physical 4G radios:
402
403.. code-block::
404
405 $ cd vars
406 $ cp main-eNB.yml main.yml
407
408Assuming that starting point, the following outlines the key
409differences from the 5G case:
410
4111. There is a 4G-specific repo, which you can find in ``deps/4gc``.
412
4132. The ``core`` section of ``vars/main.yml`` specifies a 4G-specific values file:
414
415 ``values_file: "deps/4gc/roles/core/templates/radio-4g-values.yaml"``
416
4173. The ``amp`` section of ``vars/main.yml`` specifies that 4G-specific
418 models and dashboards get loaded into the ROC and Monitoring
419 services, respectively:
420
421 ``roc_models: "deps/amp/roles/roc-load/templates/roc-4g-models.json"``
422
423 ``monitor_dashboard: "deps/amp/roles/monitor-load/templates/4g-monitor"``
424
4254. You need to edit two files with details for the 4G SIM cards you
426 use. One is the 4G-specific values file used to configure SD-Core:
427
428 ``deps/4gc/roles/core/templates/radio-4g-values.yaml``
429
430 The other is the 4G-specific Models file used to bootstrap ROC:
431
432 ``deps/amp/roles/roc-load/templates/radio-4g-models.json``
433
4345. There are 4G-specific Make targets for SD-Core (e.g., ``make
435 aether-4gc-install`` and ``make aether-4gc-uninstall``), but the
436 Make targets for AMP (e.g., ``make aether-amp-install`` and ``make
437 aether-amp-uninstall``) work unchanged in both 4G and 5G.
438
439The Quick Start and Emulated RAN (gNBsim) deployments are for 5G only,
440but revisiting the other sectionssubstituting the above for their 5G
441counterpartsserves as a guide for deploying a 4G version of Aether.
442Note that the network is configured in exactly the same way for both
4434G and 5G. This is because SD-Core's implementation of the UPF is used
444in both cases.