Using GPRS with Local breakout in YateBTS

Local breakout allows mobile stations to receive data services using their LabKit/SatSite internet connection. In this setup YateBTS is using GPRS protocol to transmit IP packets to the phones and uses local GGSN and SGSN components.

More details about how devices support GRPS, upload and download speed can be found on GSM Concepts page.

Yate settings

Yate will create a tunnel named sgsntun in ybts.conf file, if there is a [ggsn] section, containing the following


MS.IP.Base and MS.IP.MaxCount settings define a range of IP addresses ( – from which GGSN will assign IP addresses on each of your mobile station.

Using NAT, iptables will forward the data coming from your phones to the Internet.

Operating system settings

Please be aware that all commands must be executed logged as root.

Allow IP Forwarding

By default, IP Forwarding is disabled on any modern Linux distro (file /proc/sys/net/ipv4/ip_forward contains a 0)

To tell your kernel that IP forwarding is allowed on your system, change the 0 (false) to 1 (true) by typing:

echo 1 > /proc/sys/net/ipv4/ip_forward

> sysctl net.ipv4.ip_forward
net.ipv4.ip_forward = 1

Add iptables rules

urpmi iptables

systemctl start iptables.service

iptables -A POSTROUTING -t nat -s ! -d -j MASQUERADE

iptables-save > /etc/sysconfig/iptables

Phone settings

Add new Access Point Name named internet with APN as internet. Depending on your phone you can find in different places Access Point Names settings



If the mobile station, although connected to the radio network, still does not have internet access, it’s a good idea to make another test starting from scratch. Follow this steps:

Log in to Yate rmanager console and stop ybts with ybts stop command.

> telnet 0 5037
Connected to 0.
Escape character is ‘^]’.
YateSDR (backend YATE 5.5.1-priv1) ready on node ybts-UNCONFIG.

ybts stop

2017-04-13_07:42:15.001726 Stopping transceiver: received STOP command
2017-04-13_07:42:15.001802 State changed PowerOn -> Idle [0x7ff250017a20]
2017-04-13_07:42:15.001966 TRXManager.cpp:216:clockHandler: TRX clock ‘EXITING’ indication
2017-04-13_07:42:15.007059 ARFCN[0]: Radio power off. RX: bursts=100838020 passed=6161303 (6.11%) dropped=94676717 (93.89%) (LowSNR=84083033 LowPeakMin=8997924 LowPower=1595760) ellapsed=59498sec avg=1694.81 bursts/sec [0x7ff250023f40]
2017-04-13_07:42:15.008721 <bladerf/3:NOTE> Powered OFF the radio [0x7ff250013490]

As described in #GGSN_Settings, a tunnel named sgsntun was created. Deleting it will force ybts to recreate it.

To delete it you must exit Yate rmanager console and type the following command as root from your terminal.

ip link delete sgsntun

Log in to Yate rmanager and start ybts

telnet 0 5037
Connected to 0.
Escape character is ‘^]’.
YateSDR (backend YATE 5.5.1-priv1) ready on node ybts-UNCONFIG.

ybts start

2017-04-13_07:42:27.657491 State changed Idle -> Starting restart counter 1/10
2017-04-13_07:42:27.658328 State changed Starting -> WaitHandshake
MBTS connected to YBTS
Yate-BTS MBTS Component
Starting MBTS…
2017-04-13_07:42:27.664090 State changed WaitHandshake -> Running
2017-04-13_07:42:27.947419 State changed Invalid -> Idle [0x7ff250032840]
2017-04-13_07:42:27.947550 State changed Idle -> PowerOff [0x7ff250032840]
2017-04-13_07:42:27.964752 <bladerf/4:NOTE> Powered ON the radio [0x7ff2500193d0]
2017-04-13_07:42:27.967991 State changed PowerOff -> PowerOn [0x7ff250032840]
2017-04-13_07:42:28.725630 State changed Running -> RadioUp
2017-04-13_07:42:33.003176 BTS is running