IOSMCN O1 Adapter¶
Author: Shubham Kumar & Ronak Kanthaliya
Published: November 19, 2025
Please refer to OAI O1 Adapter repository for the official documentation.
Note: This documentation is a replica of the README available at the github/ngkore/IOSMCN-OAI. Please refer to the original repository for the most up-to-date information.
1. System Preparation¶
Clone repository¶
git clone https://github.com/ios-mcn/ios-mcn-releases.git
cd ios-mcn-releases/Agartala/v0.4.0/RAN/source-code/
tar -xzf ios-mcn-ran-0.4.0.iosmcn.ran.tar.gz
mv ios-mcn-ran-0.4.0.iosmcn.ran ~/ran
cd ~/ran/o1-adapter/
Set Execute Permissions¶
Set execute permissions for all scripts and executables.
chmod -R +x .
2. Update Configuration¶
Update configuration before building as this is common for deployment methods — docker, source, or Makefile.
For docker or source-based builds:¶
Modify docker/config/config.json:
Set host IP address and telnet server IP address to your host machine’s IP address.
Align telnet ports
docker/scripts/servertest.pyuses 9090config.jsondefaults to 9091Change
config.jsonto 9090
Update the
ves.urlparameter tohttp://<HOST_IP>:8080/eventListener/v7to connect with the SMO VES Collector (IOSMCN based).Update the
docker/scripts/servertest.pyto include the missing O1 configuration from CU. Either copy it fromdocker/scripts/cu_servertest.pyor use this servertest.py.
For Makefile-based builds:¶
Add missing
"gnb-cu-id": 0under theinfosection ofintegration/config/config.json.template:"info": { "gnb-du-id": 0, "gnb-cu-id": 0, // this line to be added "cell-local-id": 0, "node-id": "gNB-Eurecom-5GNRBox-00001", "location-name": "MountPoint 05, Rack 234-17, Room 234, 2nd Floor, Körnerstraße 7, 10785 Berlin, Germany, Europe, Earth, Solar-System, Universe", "managed-by": "ManagementSystem=O-RAN-SC-ONAP-based-SMO", "managed-element-type": "NodeB", "model": "nr-softmodem", "unit-type": "gNB" }
Update the
integration/.envfile as the values got further propagated tointegration/config/config.json.Rename the incorrect variable from
OAI_OAI_TELNET_HOSTtoOAI_TELNET_HOSTAdd a new variable
VES_PORTand set a default value of8080.VES_PORT=8080
Change
VES_COLLECTOR_URLvalue fromhttps://${VES_FQDN}/eventListener/v7tohttp://${VES_IP}:${VES_PORT}/eventListener/v7
Change the
portsparameter to9090inintegration/docker-compose-telnet.yaml.
3. Deployment Method 1: Docker-Based¶
3.1 Build the Adapter Container¶
Supported flags for build-adapter.sh:
Flag |
Description |
|---|---|
|
Build development container (debug tools included; not production-ready) |
|
Build production adapter container |
|
Disable docker build cache |
Build the adapter:
./build-adapter.sh --adapter
Tip: Rebuild after config changes using the same command.
3.2 Start Telnet Server (Separate Terminal)¶
The adapter uses a telnet-based interface to communicate with the RAN. Install dependencies:
sudo apt update
sudo apt install python3-pip
pip3 install telnetlib3
Run the telnet test server:
cd ran/o1-adapter/docker/scripts/
python3 servertest.py
3.3 Start the gNB Adapter¶
./start-adapter.sh --adapter
At this point, if the configuration is correct, the adapter will be listening for NETCONF clients and ready to communicate with the gNB’s telnet server.
4. Deployment Method 2: Source-Based Build¶
4.1 System Setup¶
sudo apt update && sudo apt upgrade -y
sudo apt install -y tzdata build-essential git cmake pkg-config unzip wget \
libpcre2-dev zlib1g-dev libssl-dev autoconf libtool python3-pip
sudo apt install -y --no-install-recommends psmisc unzip wget openssl \
openssh-client vsftpd openssh-server
pip3 install telnetlib3
4.2 NETCONF User Preparation¶
Create a dedicated system user:
sudo adduser --system netconf
echo "netconf:netconf!" | sudo chpasswd
SSH directory:
sudo mkdir -p /home/netconf/.ssh
sudo chmod 700 /home/netconf/.ssh
4.3 Configure OpenSSH for netconf User¶
Edit /etc/ssh/sshd_config:
sudo vim /etc/ssh/sshd_config
Append:
Match User netconf
ChrootDirectory /
X11Forwarding no
AllowTcpForwarding no
ForceCommand internal-sftp -d /ftp
Restart SSH:
sudo systemctl restart ssh
4.4 Configure vsftpd¶
Prepare directories:
sudo mkdir -p /ftp
sudo chown -R netconf:nogroup /ftp
sudo mkdir -p /var/run/vsftpd/empty
sudo mkdir -p /run/sshd
Edit /etc/vsftpd.conf:
sudo vim /etc/vsftpd.conf
Ensure the following settings are present:
listen=YES
listen_ipv6=NO
anonymous_enable=NO
local_enable=YES
write_enable=YES
local_umask=022
dirmessage_enable=YES
use_localtime=YES
xferlog_enable=YES
connect_from_port_20=YES
xferlog_std_format=YES
chroot_local_user=YES
allow_writeable_chroot=YES
secure_chroot_dir=/var/run/vsftpd/empty
pam_service_name=vsftpd
rsa_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
rsa_private_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
ssl_enable=NO
userlist_enable=YES
userlist_file=/etc/vsftpd.userlist
userlist_deny=NO
Add netconf to /etc/vsftpd.userlist:
sudo vim /etc/vsftpd.userlist
Insert:
netconf
4.5 Prepare O1 Adapter Source Tree¶
The adapter expects configuration inside src/:
cp -r docker/config/ src/
4.6 Install NETCONF Dependencies¶
cd o1-adapter/docker/scripts/
sudo ./netconf_dep_install.sh
sudo ldconfig
Run hostkey merge utilities:
sudo /usr/local/share/netopeer2/merge_hostkey.sh
sudo /usr/local/share/netopeer2/merge_config.sh
Fetch and install YANG models:
mkdir -p yang
./get-yangs.sh
sudo ./install-yangs.sh
4.7 Build the gNB Adapter¶
cd ../../src/
./build.sh
To rebuild after config changes:
rm gnb-adapter
./build.sh
Set environment variables:
export TERM=xterm-256color
4.8 Start Supporting Processes¶
Terminal 1: NETCONF Server¶
sudo netopeer2-server -d -v3 -t 60
Terminal 2: Telnet Test Server¶
cd ran/o1-adapter/docker/scripts/
python3 servertest.py
# Optional CU test:
# python3 cu_servertest.py
Terminal 3: gNB Adapter¶
cd ran/o1-adapter/src/
sudo ./gnb-adapter
5. Deployment Method 3: Makefile-Based Deployment¶
Through Makefile, we can deploy the four different combinations depending on what you want to integrate with:
Adapter alone (no gNB, no SMO)
Adapter + telnet test server (fake gNB)
Adapter + SMO (real O-RAN SMO integration, but still needs a telnet server or real gNB)
Adapter + SMO + telnet test server (full O-RAN environment with fake gNB)
5.1 Launch Adapter Using Makefile¶
Standalone Adapter¶
Build the gNB Adapter container:
make run-o1-oai-adapter
Start the gNB Adapter:
./start-adapter.sh --adapter
Install dependencies for telnet server:
sudo apt update
sudo apt install python3-pip
pip3 install telnetlib3
Run the telnet test server on a separate terminal:
cd ran/o1-adapter/docker/scripts/
python3 servertest.py
Adapter + Telnet Test Server¶
Build the gNB Adapter and telnet server containers:
make run-o1-adapter-telnet
Start the gNB Adapter:
./start-adapter.sh --adapter
Important: The below methods for SMO are not tested and still expected to fail. See iosmcn-osc-oam.md for more details on SMO deployment and integration.
Adapter + SMO¶
make run-o1-oai-adapter-smo
Adapter + SMO + Telnet Server¶
make run-o1-oai-adapter-smo-telnet
5.2 Teardown¶
make teardown
6. Testing the gNB Adapter with OAI gNB¶
6.1 Start gNB Adapter¶
Docker or makefile-based:
./start-adapter.sh --adapter
Source:
cd o1-adapter/src/
sudo ./gnb-adapter
6.2 Start OAI gNB (RFsim + O1 Telnet)¶
sudo ./nr-softmodem \
-O ../../../targets/PROJECTS/GENERIC-NR-5GC/CONF/gnb.sa.band78.fr1.106PRB.usrpb210.conf \
--rfsim \
--gNBs.[0].min_rxtxtime 6 \
--telnetsrv \
--telnetsrv.listenport 9090 \
--telnetsrv.shrmod o1