Skip to content
README.md 4.92 KiB
Newer Older
Javier Velázquez's avatar
Javier Velázquez committed
# Network Slice Controller (NSC) Architecture
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
The Network Slice Controller (NSC) is a component defined by the IETF to orchestrate the request, realization, and lifecycle control of network slices. It consists of two main modules: the mapper and the realizer. 
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
## Overview
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
The NSC handles end-to-end network slice requests originating from 5G customers. These requests are managed by the 5G end-to-end orchestrator, which configures RAN and Core Network elements accordingly and passes the request to the NSC for processing. The NSC then interacts with relevant network controllers to implement the network slice into the transport network.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
## Main Modules
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
### Mapper
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
The mapper processes client network slice requests and correlates them with existing slices. When a slice request arrives, the mapper translates it by converting the request expressed in 3GPP NRM terms into the IETF NBI data model. This involves identifying the service demarcation points (SDPs) that define the connectivity in the transport network. Once these parameters are identified and mapped into the data model, the next step is to check the feasibility of implementing the slice request.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
Realizing a slice requires an existing network resource partition (NRP) with the specified slice requirements, which may not be available at the time of the request. This information will be retrieved from an external module, which is beyond the scope of this definition. This module will provide a response regarding the feasibility of realizing the slice.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
If there are no available NRPs for instantiating the slice, the mapper will request the realizer to create a new NRP. This involves interacting with the network controllers responsible for the transport network handled by the NSC. This process is iterative until the mapper determines that the slice realization is feasible. In the current version, it is assumed that there is only one available NRP corresponding to the entire network, and that it is always accessible to the user.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
### Realizer
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
The realizer module determines the realization of each slice by interacting with specific network controllers. This version is currently working with Teraflow SDN controller. It receives requests from the mapper and decides on the technologies to be used to instantiate the slice based on the selected NRP associated with the slice. For example, Layer 2 VPN is the technology employed to realize network slices in this version. To achieve this, the realizer generates a request for the network controller to establish a Layer 2 VPN between two SDPs with the requirements specified in the slice request.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
## Workflow
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
1. **Request Initiation**: Network slice request originates from a 5G customer and is managed by the 5G end-to-end orchestrator.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
2. **Mapper Processing**: Converts the request into the IETF NBI data model, identifies SDPs, and checks feasibility.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
3. **Realizer Action**: Determines technology (e.g., Layer 2 VPN) and interacts with network controllers to instantiate the slice.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
4. **Implementation**: Network controllers configure the transport network as per the slice requirements.
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
## Arquitecture
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
<img src="images/NSC_Architecture.png" alt="NSC Architecture">
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
## Requirements
- Python3
- python3-pip
- python3-venv
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
## Configuration Constants
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
In the main configuration file, several constants can be adjusted to customize the Network Slice Controller (NSC) behavior:
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
### Logging
- `DEFAULT_LOGGING_LEVEL`: Sets logging verbosity
  - Default: `logging.INFO`
  - Options: `logging.DEBUG`, `logging.INFO`, `logging.WARNING`, `logging.ERROR`
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
### Server
- `NSC_PORT`: Server port
  - Default: `8081`
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
### Paths
- `SRC_PATH`: Absolute path to source directory
- `TEMPLATES_PATH`: Path to templates directory
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
### Teraflow Configuration
- `TFS_UPLOAD`: Enable/disable uploading slice service to Teraflow
  - Default: `False`
- `TFS_IP`: Teraflow SDN controller IP
  - Default: `"192.168.165.10"`
- `TFS_L2VPN_SUPPORT`: Enable additional L2VPN configuration support
  - Default: `False`
Javier Velázquez's avatar
Javier Velázquez committed

## Usage

Javier Velázquez's avatar
Javier Velázquez committed
To deploy and execute the NSC, follow these steps:

0. **Preparation**
    ```
    git clone https://github.com/Telefonica/network_slice_controller.git
    cd network_slice_controller
    python3 -m venv venv
    source venv/bin/activate
    pip install -r requirements.txt
    ```

1. **Start NSC Server**:
    ```
    python3 app.py
    ```
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
2. **Generate Slice Requests**:
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
    To send slice request, the NSC accepts POST request at the endpoint /slice. It is available in the swagger documentation panel at {ip}:{NSC_PORT}/nsc
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
<!-- ## Versioning and Assumptions
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
- The current version assumes a single available Network Resource Partition (NRP) for the entire network.
- It interacts with specific network controllers tailored to the technology required for slice instantiation (e.g., Teraflow SDN controller).
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
## External Modules
Javier Velázquez's avatar
Javier Velázquez committed

Javier Velázquez's avatar
Javier Velázquez committed
The planner module, which is out of the scope of this development, provides information on NRP availability and feasibility of slice realization. -->
Javier Velázquez's avatar
Javier Velázquez committed