blob: 197bd5d2175670992bf3913e3fd876f1ccc1e12c [file] [log] [blame]
jjako33258ef2003-07-06 21:30:54 +00001
Harald Welte632e8432017-09-05 18:12:14 +02002.\" * OsmoGGSN - Gateway GPRS Support Node
jjako33258ef2003-07-06 21:30:54 +00003.\" * Copyright (C) 2002, 2003 Mondru AB.
4.\" *
5.\" * The contents of this file may be used under the terms of the GNU
6.\" * General Public License Version 2, provided that the above copyright
7.\" * notice and this permission notice is included in all copies or
8.\" * substantial portions of the software.
9.\" *
10.\" * The initial developer of the original code is
11.\" * Jens Jakobsen <jj@openggsn.org>
12.\" *
13.\" * Contributor(s):
14.\" *
15.\" Manual page for ggsn
16.\" SH section heading
17.\" SS subsection heading
18.\" LP paragraph
19.\" IP indented paragraph
20.\" TP hanging label
21
jjako7e051d32004-05-27 20:06:36 +000022.TH sgsnemu 8 "May 2004"
jjako33258ef2003-07-06 21:30:54 +000023.SH NAME
24sgsnemu \- Serving GPRS Support Node Emulator
25.SH SYNOPSIS
26.B sgsnemu
27\-\-help
28
29.B sgsnemu
30\-\-version
31
32.B sgsnemu
33[
34.BI \-\-debug
35] [
36.BI \-\-conf " file"
37] [
38.BI \-\-pidfile " file"
39] [
40.BI \-\-statedir " file"
41] [
42.BI \-\-dns " host"
43] [
44.BI \-\-listen " host"
45] [
46.BI \-\-remote " host"
47] [
48.BI \-\-contexts " num"
49] [
50.BI \-\-timelimit " seconds"
51] [
jjako193e8b12003-11-10 12:31:41 +000052.BI \-\-gtpversion " version"
53] [
jjako33258ef2003-07-06 21:30:54 +000054.BI \-\-apn " apn"
55] [
jjako1a51df72004-07-20 08:30:21 +000056.BI \-\-selmode " selmode"
57] [
jjako33258ef2003-07-06 21:30:54 +000058.BI \-\-imsi " imsi"
59] [
jjako193e8b12003-11-10 12:31:41 +000060.BI \-\-nsapi " nsapi"
61] [
jjako33258ef2003-07-06 21:30:54 +000062.BI \-\-msisdn " msisdn"
63] [
64.BI \-\-qos " qos"
65] [
jjako7e051d32004-05-27 20:06:36 +000066.BI \-\-charging " charging"
67] [
jjako33258ef2003-07-06 21:30:54 +000068.BI \-\-uid " uid"
69] [
70.BI \-\-pwd " pwd"
71] [
72.BI \-\-createif
73] [
jjako193e8b12003-11-10 12:31:41 +000074.BI \-\-net " net"
75] [
jjako33258ef2003-07-06 21:30:54 +000076.BI \-\-defaultroute
77] [
78.BI \-\-ipup " script"
79] [
80.BI \-\-ipdown " script"
81] [
82.BI \-\-pinghost " host"
83] [
84.BI \-\-pingrate " num"
85] [
86.BI \-\-pingsize " num"
87] [
88.BI \-\-pingcount " num"
89]
90.SH DESCRIPTION
91.B sgsnemu
92is part of the
Harald Welte632e8432017-09-05 18:12:14 +020093.B OsmoGGSN
jjako33258ef2003-07-06 21:30:54 +000094project, and implements a Serving GPRS Support Node (SGSN)
95emulator. It can be used for testing Gateway GPRS Support Nodes
96(GGSNs), GPRS core networks as well as GPRS roaming connections.
97
98The GPRS functionality and protocols has been standardised by the
99Third Generation Partnership Project (3GPP). According to the 3GPP
100specifications an SGSN has several interfaces.
101.B sgsnemu
102implements the Gn/Gp interface which is used towards GGSNs.
103
104The Gn/Gp interface can be seen as the uplink interface of the
105SGSN. It is used for communicating with a GGSN which is typically
106connected to the Internet. The Gn/Gp interface uses the GPRS tunneling
107protocol (GTP). User data packets (typically IP packets) are tunneled
108over GTP, which again uses UDP over IP.
109
110
111.B sgsnemu
112will establish a number of connections to the GGSN. An internal ping
113facility will transmit ping requests through the established
114connections. Alternatively a local network interface can be
115created. In this case
116.B sgsnemu
117will forward packets between the local network interface and the
118established connections on the Gn/Gp interface.
119
120.B sgsnemu
121uses the
122.B TUN/TAP driver
123for the local interface. A tun network interface is established for
124each connection established to the GGSN.
125
Holger Hans Peter Freyther9c7fd8e2014-12-04 16:32:37 +0100126Runtime errors are reported using the Osmocom logging framework.
jjako33258ef2003-07-06 21:30:54 +0000127
128
129.SH OPTIONS
130.TP
131.BI --help
132Print help and exit.
133
134.TP
135.BI --version
136Print version and exit.
137
138.TP
139.BI --debug
140Run in debug mode (default = off)
141
142.TP
143.BI --conf " file"
144Read configuration
145.I file
146where each line corresponds to one command line option, but with the
147leading '--' removed. Command line options override the options given
148in the configuration file.
149
150.TP
151.BI --pidfile " file"
152Filename of process id
153.I file
154(default = ./sgsnemu.pid)
155
156.TP
157.BI --statedir " path"
158.I path
159to directory of nonvolatile data (default = ./)
160
161.TP
162.BI --dns " host"
163DNS server to use for APN lookups. If omitted the default system DNS
164configuration will be used.
165
166.TP
167.BI --listen " host"
168Local interface IP address to use for the Gn/Gp interface. If omitted
169.B sgsnemu
170will listen to any IP address.
171
172.TP
173.BI --remote " host"
174GGSN
175.I host
176to connect to. If DNS is setup correctly it should be possible to
177specify the access point name (APN) as the remote host.
178
179.TP
180.BI --contexts " num"
jjako193e8b12003-11-10 12:31:41 +0000181Number of contexts to establish. (default = 1). For multiple contexts
182the the first context is established using imsi + 0 and msisdn +
1830. The second context is established using imsi + 1 and msisdn +
1841. The third....
jjako33258ef2003-07-06 21:30:54 +0000185
186.TP
187.BI --timelimit " seconds"
188Exit
jjako7b8fad42003-07-07 14:37:42 +0000189.B sgsnemu
jjako33258ef2003-07-06 21:30:54 +0000190after
jjako7b8fad42003-07-07 14:37:42 +0000191.I seconds.
192When using the ping facility
193.B sgsnemu
194will also exit after
195.B --pingcount
196packets has been transmitted.
jjako33258ef2003-07-06 21:30:54 +0000197
198.TP
jjako193e8b12003-11-10 12:31:41 +0000199.BI --gtpversion " version"
200.I version
201of GTP to use when establishing a context (default = 1). If not able
202to establish a GTPv1 context sgsnemu will fall back to using GTPv0.
203
204.TP
jjako33258ef2003-07-06 21:30:54 +0000205.BI --apn " apn"
206.I apn
207to use when connecting to the GGSN (default = internet). APN is an
208abbreviation of Access Point Name.
209
210.TP
jjako1a51df72004-07-20 08:30:21 +0000211.BI --selmode " selmode"
212Selection mode to use when connecting to the GGSN (default =
2130x01). The encoding of the selection mode is as follows: 0: MS or
214network provided APN, subscribed verified, 1: MS provided APN,
215subscription not verified, 2: Network provided APN, subscription not
216verified.
217
218
219.TP
jjako33258ef2003-07-06 21:30:54 +0000220.BI --imsi " imsi"
221.I imsi
222to use when connecting to the GGSN (default = 240010123456789). IMSI
223is an abbreviation of International Mobile Subscriber Identity. Must
jjako193e8b12003-11-10 12:31:41 +0000224be exactly 15 digits. See the
225.I contexts
226option for the the use of the
227.I imsi
228option with multiple contexts.
229
230.TP
231.BI --nsapi " nsapi"
232.I nsapi
233to use when connecting to the GGSN (default = 0). Must be between 0
234and 15.
jjako33258ef2003-07-06 21:30:54 +0000235
236.TP
237.BI --msisdn " msisdn"
238.I msisdn
239to use when connecting to the GGSN (default = 46702123456). MSISDN is
240an abbreviation of International Mobile Integrated Services Digital
241Network. Effectly a phone number in international format without the
jjako193e8b12003-11-10 12:31:41 +0000242leading 00 or 011. See the
243.I contexts
244option for the the use of the
245.I msisdn
246option with multiple contexts.
jjako33258ef2003-07-06 21:30:54 +0000247
248.TP
249.BI --qos " qos"
250.I qos
251to use when connecting to the GGSN (default = 0x0b921f). QoS is an
252abbreviation of Quality of Service. See 3GPP specification 09.60 for
253the format of this string.
254
255.TP
jjako7e051d32004-05-27 20:06:36 +0000256.BI --charging " charging"
257Charging characteristics to use when connecting to the GGSN (default =
2580x0800). 0x0800 = Normal, 0x0400 = Prepaid, 0x0200 = Flat rate, 0x0100
259= Hot billing. See 3GPP specification 32.015 for the format of this
260field.
261
262.TP
jjako33258ef2003-07-06 21:30:54 +0000263.BI --uid " uid"
264User ID to send to GGSN as protocol configuration option.
265
266.TP
267.BI --pwd " pws"
268Password to send to GGSN as protocol configuration option.
269
270.TP
271.BI --createif
272Create a local tun interface. This interface will be used for
273forwarding packets to and from the Gn/Gp interface. Use with caution
274as the Gn/Gp interface is normally be routed to the Internet by the
jjako193e8b12003-11-10 12:31:41 +0000275GGSN. Only one interface will be created, even if several contexts are
276established. The interface will be given an IP address for each
277established context, or the address can be specified with the
278.I net
279option.
280
281.TP
282.BI --net " net"
283Network address of the local interface. The
284.I net
285option is only valid when the
286.I createif
287option is used. The
288.I net
289option is given in cidr format (net/mask bits). If the
290.I net
291option omitted an IP address is allocated for each context established.
jjako33258ef2003-07-06 21:30:54 +0000292
293.TP
294.BI --defaultroute
295Create a defaultroute to the local tun interface.
296
297.TP
298.BI --ipup " script"
299Script executed after the tun network interface has been brought up.
300Executed with the following parameters: <devicename> <ip address>
301
302.TP
303.BI --ipdown " script"
304Script executed after the tun network interface has been taken down.
305Executed with the following parameters: <devicename> <ip address>
306
307.TP
308.BI --pinghost " host"
309Ping
310.I host
311through the Gn/GP interface. Ping statistics are reported much like
312done by the original ping program. Use this facility for performance
313test of GGSNs.
314
315.TP
316.BI --pingrate " num"
317Number of ping requests per second (default = 1)
318
319.TP
320.BI --pingsize " num"
321The size of each ping requests in octets (default = 56)
322
323
324.TP
325.BI --pingcount " num"
326Number of ping requests to send (default = 0). A value of 0 (zero)
327indicates infinite.
328
329.TP
330.BI --pingquiet
331Do not print information for each packet received (default = off). Is
Ruben Undheimcc077ae2016-05-24 23:31:47 +0200332quite useful for high pingrates.
jjako33258ef2003-07-06 21:30:54 +0000333
334
335.SH FILES
336.I sgsnemu.conf
337.RS
338The configuration file for
339.B sgsnemu.
340.RE
341.I .sgsnemu.pid
342.RS
343Process ID file.
344.RE
345.I ./
346.RS
347Directory holding nonvolatile data.
348.RE
349
350.SH BUGS
Harald Welte632e8432017-09-05 18:12:14 +0200351Report all bugs to the OsmoGGSN bug tracking list at
352.I http://osmocom.org/projects/openggsn/issues
jjako33258ef2003-07-06 21:30:54 +0000353
354
355.SH "SEE ALSO"
Holger Hans Peter Freyther9c7fd8e2014-12-04 16:32:37 +0100356.BR ggsn (8)
jjako33258ef2003-07-06 21:30:54 +0000357
358.SH NOTES
359.LP
360
361Besides the long options documented in this man page
362.B sgsnemu
363also accepts a number of short options with the same functionality. Use
364.B sgsnemu --help
365for a full list of all the available options.
366
367The TUN/TAP driver is required for proper operation of
368.B sgsnemu.
369For linux kernels later than 2.4.7 the TUN/TAP driver is included in
370the kernel, but typically needs to be loaded manually with
371.B modprobe tun.
372For automatic loading the line
373.B alias char-major-10-200 tun
374can be added to
375.B /etc/modules.conf.
376For other platforms see
377.I http://vtun.sourceforge.net/tun/
378for information on how to install and configure the tun driver.
379
380.B sgsnemu
381uses the GPRS Tunneling Protocol (GTP) as specified by the Third
382Generation Partnership Project (3GPP). 3GPP protocols specifications
383can be found at
384.I http://www.3gpp.org
385
386.SH COPYRIGHT
387
jjako7e051d32004-05-27 20:06:36 +0000388Copyright (C) 2002, 2003, 2004 by Mondru AB.
jjako33258ef2003-07-06 21:30:54 +0000389
390The contents of this file may be used under the terms of the GNU
391General Public License Version 2, provided that the above copyright
392notice and this permission notice is included in all copies or
393substantial portions of the software.
394
395.SH AUTHORS
396Jens Jakobsen <jj@openggsn.org>