Project

General

Profile

Statistics
| Branch: | Tag: | Revision:

gdp / README-server-install.md @ master

History | View | Annotate | Download (4.33 KB)

1 ebd10406 Eric Allman
2
INSTALLING A GLOBAL DATAPLANE SERVER FROM SOURCE CODE
3
=====================================================
4
5
These instructions are relevant *only* if you are installing the
6
server code from the source tree.  If you have installed the
7
server code from a package, or if it is already installed, read
8
the document `doc/gdp-server-admin.md`.
9
10 632861ce Eric Allman
Generally speaking, we are moving toward distributions using Docker
11
images (first choice) and Debian packages.  Installations from
12
source should only be used if you are collaborating with us on the
13
base system.
14
15 ebd10406 Eric Allman
These steps assume you are building and installing the code from the
16
source tree.  If you are using a Debian package, see the instructions
17
with it and skip to the next section.
18
19
Installing Step by Step
20
-----------------------
21
22
  * Run the script `adm/gdp-setup.sh` to set up your system
23
    so that the source code can be compilied.  In particular,
24
	this installs all the third party packages you should need.
25
  * Create `/usr/local/etc/gdp.conf.sh` or `/etc/gdp.conf.sh`
26
    if you want to override any of the defaults.
27
  * Run the script `adm/init-gdp-server.sh` from the root of
28
    the GDP source tree.  This creates the `gdp` user, creates
29
	the system directories, etc.  Note that this has certain
30
	dependencies on Berkeley.  See below for details.
31
  * Compile the source tree using `make` from the source root.
32
    Details can be found in `README-compiling.md`.
33
  * Install the header files, libraries, and binaries using
34
    `make install`.  You will probably need to be root for
35
	this to work.  If you changed the setting for `GDP_ROOT`
36
	in `gdp.conf.sh` you will also have to set `LOCAL_ROOT`
37
	on the command line, e.g., if you have set `GDP_ROOT` to
38
	/usr/local/gdp, use:
39
40
		make install LOCAL_ROOT=/usr/local/gdp
41
42
Details
43
-------
44
45
### Changing Defaults
46
47
If you want to change defaults, create `/usr/local/etc/gdp.conf.sh`
48
or `/etc/gdp.conf.sh`.  This is read as a shell file, and should
49
consist of NAME=value definitions.  There are several parameters
50 632861ce Eric Allman
that can be changed, the most useful of which is `GDP_ROOT`.
51 ebd10406 Eric Allman
52
There are three cases for `GDP_ROOT`:
53
54
  * `GDP_ROOT` = `/usr` means that everything will be installed
55 0dc3d148 Eric Allman
    in the "normal" system directories: `/usr/bin`, `/usr/sbin`,
56 9e62cb26 Eric Allman
    `/var/log`, and `/etc/gdp`.  Note that files in `/etc` are in
57
    a subdirectory.  This is the default.
58
  * `GDP_ROOT` = `/usr/local` or `/opt/local` means that everything
59
    will be installed in subdirectories of `GDP_ROOT` with the
60
    exception of configuration files, which will be stored in
61
    `GDP_ROOT/etc/gdp`.
62 ebd10406 Eric Allman
  * Otherwise everything is installed in subdirectories of
63
    the indicated directory.  For example, if `GDP_ROOT` is
64 9e62cb26 Eric Allman
    `/home/gdp` then all installation will go into that
65
    directory instead of the system directories, i.e.,
66
    `/home/gdp/bin`, `/home/gdp/etc`, etc.
67 ebd10406 Eric Allman
68 0dc3d148 Eric Allman
Other locations can be set explicitly (rather that deriving from
69
`GDP_ROOT`):
70
71
  * `GDP_ETC`: the location for configuration files.
72
  * `GDP_LOG_DIR`: where system logs are stored.
73
74 ebd10406 Eric Allman
### Initializing the Server
75
76
The script `adm/init-gdp-server.sh` should do most of the steps
77
necessary for initializing a server.  This:
78
79
  * Creates a user and group named `gdp:gdp` if it doesn not exist.
80
  * Creates directories needed by the GDP.  See below for details.
81
  * Creates initial parameter files.
82
83
This script does have some Berkeley dependencies that may require
84
editing some files after you have run the script.  These will
85 9e62cb26 Eric Allman
be located in the directory `$GDP_ETC/params`.
86 ebd10406 Eric Allman
87
The parameter `swarm.gdp.routers` (file `gdp`) is set to the
88
list of hosts to search to find a GDP router.  This will be
89
initialized with the names of routers at Berkeley.  If you are
90
running your own router you will probably want to change this.
91
92
The parameter `swarm.gdplogd.gdpname` (file `gdplogd`) assumes
93
that your domain name is "eecs.berkeley.edu".  You should change
94
this to match your domain.  The convention is to use the
95
reversed domain name of the host running `gdplogd` with
96
`.gdplogd` appended.  For example, if your `gdplogd` server
97
is named `server.foo.example.com`, the value of that parameter
98
should be `com.example.foo.server.gdplogd`.
99
100
Next Steps
101
----------
102
103
Proceed to the documenet `doc/gdp-server-admin.md` for details about
104
post-install operation.
105
106
<!-- vim: set ai sw=4 sts=4 ts=4 : -->
107 632861ce Eric Allman
<!-- Use
108
	pandoc -sS -o README-server-install.html README-server-install.md
109
to process this to HTML -->