Project

General

Profile

Building OpenBSC » History » Version 14

laforge, 02/19/2016 10:47 PM
add iformation on libosmocore

1 14 laforge
[[PageOutline]]
2 1 tec
3 1 tec
== Debian HowTo ==
4 1 tec
5 1 tec
This page will describe the entire installation process of OpenBSC under Debian Linux.
6 1 tec
This tutorial is based on Debian Netinstall 5.0 but will work with other Debian versions.
7 1 tec
8 4 tec
To be able to access your OpenBSC machine easily from a remote Terminal, install ssh.
9 1 tec
This can be easily done with "apt-get install ssh".
10 1 tec
11 1 tec
12 14 laforge
=== Compiling + running OpenBSC ===
13 14 laforge
14 14 laforge
You should install the following debian packages before you start:
15 14 laforge
 * libdbi0
16 14 laforge
 * libdbi0-dev
17 14 laforge
 * libdbd-sqlite3
18 14 laforge
 * autoconf
19 14 laforge
 * git-core
20 14 laforge
(The list may be incomplete)
21 14 laforge
22 14 laforge
You can install those packages with {{{apt-get install libdbi0-dev libdbd-sqlite3 autoconf git-core}}}
23 14 laforge
24 14 laforge
Here are the actual instructions
25 14 laforge
 * Check out libosmocore from git using {{{git clone git://git.osmocom.org/libosmocore.git}}}
26 14 laforge
  * Change into the right directory using {{{cd libosmocore}}
27 14 laforge
  * Rebuild the configure script using {{{autoreconf -i}}}
28 14 laforge
  * Run the configure script using {{{./configure}}}
29 14 laforge
  * Build the actual software using {{{make}}}
30 14 laforge
  * Install the library by using {{{make install}}}
31 14 laforge
 * Check out OpenBSC from git using {{{git clone git://bs11-abis.gnumonks.org/openbsc.git}}}
32 14 laforge
  * Change into the right directory using {{{cd openbsc/openbsc}}}
33 14 laforge
  * Rebuild the configure script using {{{autoreconf -i}}}
34 14 laforge
  * Run the configure script using {{{./configure}}}
35 14 laforge
  * Build the actual software using {{{make}}}
36 14 laforge
37 14 laforge
Congratulations, you should now have the OpenBSC programs like ''bsc_hack'', ''ipaccess-config'' and others in the 'src/' subdirectory.
38 14 laforge
39 14 laforge
=== mISDN enabled kernel in case of BS-11 ===
40 14 laforge
41 1 tec
If you want to use a E1-based BTS (like the BS-11), you will need to install mISDN.
42 11 laforge
43 1 tec
'''If you have an IP/Ethernet based BTS (like the ip.access nanoBTS), you don't need this section!'''
44 6 tec
45 11 laforge
Because OpenBSC's E1 support relies on mISDN (named ISDN4Linux before) and hfcmulti as an interface to the BS11, it has to be integrated as a module into the kernel.
46 1 tec
47 11 laforge
First of all you will need to download the 2.6.31 Linux kernel from [http://www.kernel.org/pub/linux/kernel/v2.6/].
48 1 tec
49 12 laforge
Change to '''/usr/src/''' on your OpenBSC machine.
50 1 tec
Then simply do a {{{wget [http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.31.tar.bz2]}{}}
51 12 laforge
52 14 laforge
Unpack the archive:  {{{tar --bzip2 -xvf linux-2.6.31.tar.bz2}}}
53 1 tec
and create a symlink to fit the Linux standard conventions: {{{ln -s linux-2.6.30 linux}}}.[[BR]]
54 12 laforge
55 3 tec
Now change to linux-2.6.30 typing {{{cd linux-2.6.30}}}.
56 1 tec
57 1 tec
You are ready now to prepare for the main part:
58 1 tec
59 1 tec
Install some tools needed to build the kernel.
60 1 tec
61 1 tec
{{{apt-get install libncurses5-dev kernel-package}}}
62 1 tec
63 1 tec
Now configure the kernel modules with {{{make menuconfig}}}
64 1 tec
65 1 tec
Include the ''mISDN'' modules and ''hfcmulti /hfc e1 drivers''.
66 11 laforge
67 3 tec
Save the new configuration to '''.config''' .
68 11 laforge
69 3 tec
You can now try to build the Debian kernel package: {{{make-kpkg linux-image --initrd --revision=openbsc01.0}}} .
70 1 tec
71 3 tec
Go a directory higher (cd ..)
72 3 tec
73 3 tec
and install the new kernel package typing:
74 11 laforge
75 14 laforge
{{{dpkg -i  kernelpackagename.deb}}}
76 11 laforge
77 13 austin
Now you only have to add the dslot=1 parameter for hfcmulti to load with this parameter.
78 11 laforge
Otherwise OpenBSC will talk on signalling timeslot 15 where BS11 uses 1.
79 11 laforge
80 11 laforge
Simply add the following in '''/boot/grub/menu.lst''' :
81 11 laforge
82 11 laforge
Add this line to the "Kernel"-line
83 11 laforge
84 11 laforge
'''hfcmulti.dslot=1'''
85 11 laforge
86 11 laforge
Save changes and reboot your machine with your new kernel.
Add picture from clipboard (Maximum size: 48.8 MB)