this article introduce install and configure srslte enb epc on ubuntu 16.04

if you are from China you can download ubuntu 16.04 livecd which has been install all required package for srslte

and you can go to step 4. the livecd url: extract code: zs09


1. install uhd

ubuntu 16.04 apt-get have uhd package but it is old version which may have problem working with new version srslte.

if you are from China, I suggest you change apt-get source to other. I use 清华大学 source which work fine for me, open /etc/apt/sources.list and replace all the content as below:

# deb cdrom:[Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)]/ xenial main restricted
deb xenial main restricted
deb xenial-updates main restricted
deb xenial universe
deb xenial-updates universe
deb xenial multiverse
deb xenial-updates multiverse
deb xenial-backports main restricted universe multiverse
deb xenial-security main restricted
deb xenial-security universe
deb xenial-security multiverse

the source for ubuntu 18.04 is:

deb bionic main restricted universe multiverse
deb-src bionic main restricted universe multiverse
deb bionic-updates main restricted universe multiverse
deb-src bionic-updates main restricted universe multiverse
deb bionic-backports main restricted universe multiverse
deb-src bionic-backports main restricted universe multiverse
deb bionic-security main restricted universe multiverse
deb-src bionic-security main restricted universe multiverse
deb bionic-proposed main restricted universe multiverse
deb-src bionic-proposed main restricted universe multiverse

the source for ubuntu 20.04 is:

deb focal main restricted
deb focal-updates main restricted
deb focal universe
deb focal-updates universe
deb focal multiverse
deb focal-updates multiverse
deb focal-backports main restricted universe multiverse
deb focal-security main restricted
deb focal-security universe
deb focal-security multiverse

run the command below one by one:

sudo apt-get remove -y uhd
sudo apt-get remove libuhd-dev libuhd003 uhd-host -y
sudo apt-add-repository --remove "deb trusty main"
sudo add-apt-repository ppa:ettusresearch/uhd -y
sudo apt-get update
sudo apt-get -y --allow-unauthenticated install python python-tk libboost-all-dev libusb-1.0-0-dev

for ubuntu 16.04 and 18.04

sudo apt-get -y --allow-unauthenticated install libuhd-dev libuhd003 uhd-host

for ubuntu 20.04:

sudo apt-get -y --allow-unauthenticated install libuhd-dev libuhd4.1.0 uhd-host

download usrp firmware:

sudo uhd_images_downloader -t b2xx


2. install the required package for srsran:

sudo apt-get install cmake libfftw3-dev libmbedtls-dev libboost-program-options-dev libconfig++-dev libsctp-dev git g++


3. install low latency kernel

just run:

sudo apt-get install linux-lowlatency 
sudo apt-get install linux-image-`uname -r | cut -d- -f1-2`-lowlatency 
sudo apt-get install linux-headers-`uname -r | cut -d- -f1-2`-lowlatency


4. download and compile srsran:

git clone
cd srsRAN
git checkout release_21_04
mkdir build
cd build
cmake ../
make test
sudo make install
sudo ldconfig

here use release 21.04 you can also use other release or master branch.


5. configure epc and enb:


cp srsenb/enb.conf.example srsenb/enb.conf
cp srsenb/rr.conf.example srsenb/rr.conf
cp srsenb/sib.conf.example srsenb/sib.conf
cp srsenb/drb.conf.example srsenb/drb.conf


cp srsepc/epc.conf.example srsepc/epc.conf
cp srsepc/user_db.csv.example srsepc/user_db.csv

edit enb.conf set dl_earfcn = 400


6.write sim card and configure hss

if you are use using srsue then ignore this step goto step 7

use a blank lte usim card and a sim card writer and download sim card write software from GRSIMWrite 3.10.rar (2 MB). open the sim card write software

write imsi, ki, opc as you want. and click the "same with lte" button on the "GSM Parameter" part. finally click "Write Card" button.

open user_db.csv file add line in below way, (imsi), (ki), (opc) should be copy from the sim card write software.


in my case it is:



7. configure srsue

if you are using cots ue then ignore this step.


cp srsue/ue.conf.example srsue/ue.conf

edit ue.conf set dl_earfcn = 400

the default usim information is:

mode = soft
algo = xor
#opc  = 63BFA50EE6523365FF14C1F45F88737D
k    = 00112233445566778899aabbccddeeff
imsi = 001010123456789
imei = 353490069873319
#reader = 
#pin  = 1234

the information also in the default user_db.csv so do not need to modify.


8. run srslte and connect ue

run epc:

cd srsRAN/srsepc
sudo srsepc epc.conf

run enb:

cd srsRAN/srsenb
sudo srsenb enb.conf

then run:


the srsenb ip is like this:

srs_spgw_sgi Link encap:UNSPEC  HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  
          inet addr:  P-t-P:  Mask:
          inet6 addr: fe80::9084:4d7c:40ed:6ca/64 Scope:Link
          RX packets:2 errors:0 dropped:0 overruns:0 frame:0
          TX packets:95 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:500 
          RX bytes:96 (96.0 B)  TX bytes:7248 (7.2 KB)

now connect ue.

for cots ue:

insert the written usim card to a phone then search network manually. the phone should be able to find your lte network.

you can type "t" on srsenb if shows this kind of message like below picture then it means your pc is not powerful enough to run enb. you need to use smaller prb or use more power pc.

for srsue:

cd srsRAN/srsue
sudo srsue ue.conf

after connect to enb you need to keep ping the enb unless the ue will disconnect soon.



 9. connect ue to internet

cd srsepc
sudo ./ enp1s0

enp1s0 is the network interface on pc. you need to change it to your network interface name.


10.  use usrp b210 external 10Mhz clock

if you want to use usrp b210 external 10Mhz clock then you need to configure enb.conf

open enb.conf find below line: 


modify to

device_args = clock=external