Project

General

Profile

OsmoGGSN » History » Version 15

wirelesss, 12/27/2016 09:37 AM

1 2 laforge
h1. [[OpenGGSN]]
2 1 laforge
3 2 laforge
[[OpenGGSN]] is an implementation of the Gateway GPRS Support Node ("GGSN":http://en.wikipedia.org/wiki/GGSN) element in the GPRS core network.
4
5 3 laforge
[[OpenGGSN]] was developed in 2002 to 2004 by Mondru AB and was abandoned for some years before adopted by the Osmocom project around 2010.
6 1 laforge
7 3 laforge
h2. Source Code / git repository
8
9
The source code is maintained in the osmcoom git at http://git.osmocom.org/openggsn/
10
11
h2. Binary packages
12 1 laforge
13
OpenGGSN packages are created as part of the Osmocom nightly debian builds, see [[cellular-infrastructure:NightlyBuilds]]
14 4 laforge
15
h2. Support / mailing lists
16
17
Please direct any questions regarding use, configuration or development of OpenGGSN to the osmocom-net-gprs@lists.osmocom.org mailing list, to which you can subscribe at https://lists.osmocom.org/mailman/listinfo/osmocom-net-gprs
18 5 wirelesss
19 14 wirelesss
h2. Building OpenGGSN with kernel which has GTP-U support
20 5 wirelesss
21 13 wirelesss
It is expected that complete openbsc project and dependencies are pre-installed. Check if package @libc-ares-dev@ is installed and if not please add it.
22 12 wirelesss
23 5 wirelesss
Ubuntu 16.10, kernel 4.8.0-30-generic is used. 
24
25
* Installing dependencies and build library @libgtpnl@
26
27 6 wirelesss
You can install those packages with:
28 5 wirelesss
29
<pre>
30
sudo apt install libtalloc-dev libpcsclite libmnl-dev
31
</pre>
32 1 laforge
33 12 wirelesss
Please follow instructions provided at [[cellular-infrastructure:Build from source]] in order to install following library and projects :
34 1 laforge
35 6 wirelesss
Information about dependencies between Osmocom projects is given at the above link:
36
37 5 wirelesss
* libgtpnl
38
39
<pre>
40
  sudo make install
41
  sudo ldconfig
42
</pre>
43
44
* libosmocore 
45
* openggsn
46
47
<pre>
48 1 laforge
./configure --enable-gtp-linux
49 8 wirelesss
make 
50
sudo make install
51
sudo ldconfig
52 5 wirelesss
</pre>
53
54 14 wirelesss
Following message is shown at end of the command: @ ./configure --enable-gtp-linux@ 
55 5 wirelesss
56
<pre>
57
openggsn Configuration:
58
  GTP Linux kernel support:			yes
59 6 wirelesss
</pre>
60
61
This means that appropriate header files are available.
62 1 laforge
63 7 wirelesss
64 14 wirelesss
h2. Using OpenGGSN with kernel which has GTP-U support
65 7 wirelesss
66
In order to find out whether gtp.ko module is available we can enter following command:
67 1 laforge
68 7 wirelesss
<pre>
69
find /lib/modules/`uname -r` -name gtp.ko
70
</pre>
71
72 11 wirelesss
Output below shows that gtp.ko module is present
73 7 wirelesss
74 1 laforge
<pre>
75 10 wirelesss
/lib/modules/4.8.0-30-generic/kernel/drivers/net/gtp.ko
76 7 wirelesss
</pre>
77 1 laforge
78 7 wirelesss
79 14 wirelesss
We are loading module gtp from kernel issuing command <pre>sudo modprobe gtp </pre> 
80 1 laforge
81 11 wirelesss
command: 
82
<pre>
83
lsmod | grep gtp
84
</pre>
85 7 wirelesss
86 8 wirelesss
give us information about gtp and related udp tunnel:
87 7 wirelesss
88
<pre>
89
gtp                    28672  0
90
udp_tunnel             16384  1 gtp
91 1 laforge
</pre>
92
93
94 13 wirelesss
Some helpful tools are available in: @libgtpnl/tools@
95 11 wirelesss
96 13 wirelesss
you can get more details about gtp-tunnel, entering command from the OpenGGSN shell:
97 1 laforge
98 13 wirelesss
<pre>
99 15 wirelesss
100
sudo ./gtp-tunnel list
101
102
version 1 tei 1/0 ms_addr 192.168.0.2 sgsn_addr 127.0.0.2
103
104 13 wirelesss
</pre>
105
106
107
Furthermore we can use: <pre> sudo starce ggsn --gtp-linux -c ggsn.conf -f -d </pre>  to determine if Ubuntu 16.10, kernel 4.8.0-30 is in use.   
108
109
Next two cases shall be considered as an indication whether gtp kernel module is active:
110
111
** If gtp kernel module is active then we can see the strace output just when PDP context activation or deactivation is done.
112
113
** If gtp kernel module is not active then we can see the strace output constantly running on the screen. 
114
115
116 11 wirelesss
Note: OpenGGSN is started by: 
117 1 laforge
<pre>
118 13 wirelesss
sudo  ggsn --gtp-linux -c ggsn.conf -f -d
119 1 laforge
</pre>
120
121 13 wirelesss
-d option is useful for debugging purposes. 
122 1 laforge
123 13 wirelesss
Related output should be similar to the one shown below: 
124
125 1 laforge
<pre>
126 13 wirelesss
conf: ggsn.conf
127
fg: 1
128
debug: 1
129
qos: 0x0b921f
130
apn: internet
131
net: 192.168.0.0/24
132
pidfile: /var/run/ggsn.pid
133
statedir: /var/lib/ggsn/
134
gtp_linux: 1
135
timelimit: 0
136
cmdline_parser_configfile
137
listen: 127.0.0.1
138
conf: ggsn.conf
139
fg: 1
140
debug: 1
141
qos: 0x0b921f
142
apn: internet
143
net: 192.168.0.0/24
144
pidfile: /var/run/ggsn.pid
145
statedir: /var/lib/ggsn/
146
gtp-linux: 1
147
timelimit: 0
148
<000c> gtp.c:701 GTP: gtp_newgsn() started
149
<0002> gtp-kernel.c:123 Using the GTP kernel mode (genl ID is 27)
150
151
<0002> gtp-kernel.c:156 GTP kernel configured
152
153
<000b> control_if.c:693 CTRL at 127.0.0.1 4257
154 1 laforge
</pre>
155
156 13 wirelesss
osmosgsn can be started with: 
157 1 laforge
158 13 wirelesss
<pre>
159
sudo osmo-sgsn -c sgsn.cfg    
160
</pre>
161
162
- d option is also available ins osmo-sgsn command. 
163
164
Additional information related to setup of openbsc and GPRS setup is available [[cellular-infrastructure:OpenBSC GPRS]]
165 7 wirelesss
 
166 13 wirelesss
For clarity purposes configuration files of openbsc, OpenGGSN, osmosgsn and sysmoBTS are added. 
Add picture from clipboard (Maximum size: 48.8 MB)