blob: e32b9a7b414d5ea7e8a5cee9acc4aca279b67869 [file] [log] [blame]
paul718e3742002-12-13 20:15:29 +00001@node Installation, Basic commands, Overview, Top
2@comment node-name, next, previous, up
3@chapter Installation
4
paul7190f4e2003-08-12 12:40:20 +00005@cindex How to install Quagga
paul718e3742002-12-13 20:15:29 +00006@cindex Installation
paul7190f4e2003-08-12 12:40:20 +00007@cindex Installing Quagga
paul718e3742002-12-13 20:15:29 +00008@cindex Building the system
paul7190f4e2003-08-12 12:40:20 +00009@cindex Making Quagga
paul718e3742002-12-13 20:15:29 +000010
11 There are three steps for installing the software: configuration,
12compilation, and installation.
13
14@menu
15* Configure the Software::
16* Build the Software::
17* Install the Software::
18@end menu
19
paul7190f4e2003-08-12 12:40:20 +000020 The easiest way to get Quagga running is to issue the following
paul718e3742002-12-13 20:15:29 +000021commands:
22
23@example
24% configure
25% make
26% make install
27@end example
28
29@node Configure the Software, Build the Software, Installation, Installation
30@comment node-name, next, previous, up
31@section Configure the Software
32
33@cindex Configuration options
34@cindex Options for configuring
35@cindex Build options
36@cindex Distribution configuration
37@cindex Options to @code{./configure}
38
paul7190f4e2003-08-12 12:40:20 +000039 Quagga has an excellent configure script which
paul718e3742002-12-13 20:15:29 +000040automatically detects most host configurations. There are several
41additional configure options you can use to turn off IPv6 support, to
42disable the compilation of specific daemons, and to enable SNMP support.
43
44@table @option
45@item --enable-guile
46Turn on compilation of the zebra-guile interpreter. You will need the
47guile library to make this. zebra-guile implementation is not yet
48finished. So this option is only useful for zebra-guile developers.
49@item --disable-ipv6
paul7190f4e2003-08-12 12:40:20 +000050Turn off IPv6 related features and daemons. Quagga configure script
paul718e3742002-12-13 20:15:29 +000051automatically detects IPv6 stack. But sometimes you might want to
paul7190f4e2003-08-12 12:40:20 +000052disable IPv6 support of Quagga.
paul718e3742002-12-13 20:15:29 +000053@item --disable-zebra
54Do not build zebra daemon.
55@item --disable-ripd
56Do not build ripd.
57@item --disable-ripngd
58Do not build ripngd.
59@item --disable-ospfd
60Do not build ospfd.
61@item --disable-ospf6d
62Do not build ospf6d.
63@item --disable-bgpd
64Do not build bgpd.
65@item --disable-bgp-announce
66Make @command{bgpd} which does not make bgp announcements at all. This
67feature is good for using @command{bgpd} as a BGP announcement listener.
68@item --enable-netlink
paul7190f4e2003-08-12 12:40:20 +000069Force to enable @sc{gnu}/Linux netlink interface. Quagga configure
paul718e3742002-12-13 20:15:29 +000070script detects netlink interface by checking a header file. When the header
71file does not match to the current running kernel, configure script will
72not turn on netlink support.
73@item --enable-snmp
74Enable SNMP support. By default, SNMP support is disabled.
paul971a4492003-06-20 01:18:07 +000075@item --enable-nssa
76Enable support for Not So Stubby Area (see RC3101) in ospfd.
77@item --enable-opaque-lsa
78Enable support for Opaque LSAs (RFC2370) in ospfd.
79@item --disable-ospfapi
80Disable support for OSPF-API, an API to interface directly with ospfd.
81OSPF-API is enabled if --enable-opaque-lsa is set.
82@item --disable-ospfclient
83Disable building of the example OSPF-API client.
84@item --enable-ospf-te
85Enable support for OSPF Traffic Engineering Extension (internet-draft) this
86requires support for Opaque LSAs.
87@item --enable-multipath=@var{ARG}
88Enable support for Equal Cost Multipath. @var{ARG} is the maximum number
89of ECMP paths to allow, set to 0 to allow unlimited number of paths.
90@item --enable-rtadv
91Enable support IPV6 router advertisement in zebra.
paul718e3742002-12-13 20:15:29 +000092@end table
93
94You may specify any combination of the above options to the configure
95script. By default, the executables are placed in @file{/usr/local/sbin}
96and the configuration files in @file{/usr/local/etc}. The @file{/usr/local/}
97installation prefix and other directories may be changed using the following
98options to the configuration script.
99
100@table @option
101@item --prefix=@var{prefix}
102Install architecture-independent files in @var{prefix} [/usr/local].
103@item --sysconfdir=@var{dir}
paul971a4492003-06-20 01:18:07 +0000104Look for configuration files in @var{dir} [@var{prefix}/etc]. Note
105that sample configuration files will be installed here.
106@item --localstatedir=@var{dir}
107Configure zebra to use @var{dir} for local state files, such
108as pid files and unix sockets.
paul718e3742002-12-13 20:15:29 +0000109@end table
110
paul971a4492003-06-20 01:18:07 +0000111Additionally, you may configure zebra to drop its elevated
112privileges shortly after startup and switch
113to another user, there are three configure options
114to control zebra's behaviour.
115
116@table @option
117@item --enable-user=@var{user}
118Switch to user @var{ARG} shortly after startup, and run as user @var{ARG}
119in normal operation.
120@item --enable-group=@var{group}
121Switch real and effective group to @var{group} shortly after
122startup.
123@item --enable-vty-group=@var{group}
124Create Unix Vty sockets (for use with vtysh) with group owndership set to
125@var{group}. This allows one to create a seperate group which is
126restricted to accessing only the Vty sockets, hence allowing one to
127delegate this group to individual users, or to run vtysh setgid to
128this group.
129@end table
130
paul7190f4e2003-08-12 12:40:20 +0000131The default user and group which will be configured is 'quagga' if no user
paul971a4492003-06-20 01:18:07 +0000132or group is specified. Note that this user or group requires write access
133to the local state directory (see --localstatedir) and requires at least
134read access, and write access if you wish to allow daemons
135to write out their configuration, to the configuration directory
136(see --sysconfdir).
137
138On systems which have the 'libcap' capabilities manipulation library
paul7190f4e2003-08-12 12:40:20 +0000139(currently only linux), the quagga system will retain
paul971a4492003-06-20 01:18:07 +0000140only minimal capabilities required, further it will only raise these
paul7190f4e2003-08-12 12:40:20 +0000141capabilities for brief periods. On systems without libcap, quagga will run
paul971a4492003-06-20 01:18:07 +0000142as the user specified and only raise its uid back to uid 0 for brief
143periods.
144
paul718e3742002-12-13 20:15:29 +0000145@example
146% ./configure --disable-ipv6
147@end example
148
149This command will configure zebra and the routing daemons.
150
paul7190f4e2003-08-12 12:40:20 +0000151@cindex Configuring Quagga
paul718e3742002-12-13 20:15:29 +0000152@cindex Configuration the software build
153@cindex Building on Linux boxes
154@cindex Linux configurations
155
156There are several options available only to @sc{gnu}/Linux systems:
157@footnote{GNU/Linux has very flexible kernel configuration features. If
158you use GNU/Linux, make sure that the current kernel configuration is
paul7190f4e2003-08-12 12:40:20 +0000159what you want. Quagga will run with any kernel configuration but some
paul718e3742002-12-13 20:15:29 +0000160recommendations do exist.
161
162@table @var
163
164@item CONFIG_NETLINK
165Kernel/User netlink socket.
166This is a brand new feature which enables
paul7190f4e2003-08-12 12:40:20 +0000167an advanced interface between the Linux kernel and zebra (@pxref{Kernel Interface}).
paul718e3742002-12-13 20:15:29 +0000168
169@item CONFIG_RTNETLINK
170Routing messages.
171This makes it possible to receive netlink routing messages. If you
172specify this option, @command{zebra} can detect routing information
173updates directly from the kernel (@pxref{Kernel Interface}).
174
175@item CONFIG_IP_MULTICAST
176IP: multicasting.
177This option should be specified when you use @command{ripd} or
178@command{ospfd} because these protocols use multicast.
179
180@end table
181
182IPv6 support has been added in @sc{gnu}/Linux kernel version 2.2. If you
paul7190f4e2003-08-12 12:40:20 +0000183try to use the Quagga IPv6 feature on a @sc{gnu}/Linux kernel, please
paul718e3742002-12-13 20:15:29 +0000184make sure the following libraries have been installed. Please note that
185these libraries will not be needed when you uses @sc{gnu} C library 2.1
186or upper.
187
188@table @code
189
190@item inet6-apps
191The @code{inet6-apps} package includes basic IPv6 related libraries such
192as @code{inet_ntop} and @code{inet_pton}. Some basic IPv6 programs such
193as @command{ping}, @command{ftp}, and @command{inetd} are also
194included. The @code{inet-apps} can be found at
195@url{ftp://ftp.inner.net/pub/ipv6/}.
196
197@item net-tools
198The @code{net-tools} package provides an IPv6 enabled interface and
199routing utility. It contains @command{ifconfig}, @command{route},
200@command{netstat}, and other tools. @code{net-tools} may be found at
201@url{http://www.tazenda.demon.co.uk/phil/net-tools/}.
202
203@end table
204@c A - end of footnote
205}.
206
207@node Build the Software, Install the Software, Configure the Software, Installation
208@comment node-name, next, previous, up
209@section Build the Software
210
211After configuring the software, you will need to compile it for your
212system. Simply issue the command @command{make} in the root of the source
213directory and the software will be compiled. If you have *any* problems
214at this stage, be certain to send a bug report @xref{Bug Reports}.
215
216@example
217% ./configure
218.
219.
220.
221./configure output
222.
223.
224.
225% make
226@end example
227@c A - End of node, Building the Software
228
229
230@node Install the Software, , Build the Software, Installation
231@comment node-name, next, previous, up
232@section Install the Software
233
234Installing the software to your system consists of copying the compiled
235programs and supporting files to a standard location. After the
236installation process has completed, these files have been copied
237from your work directory to @file{/usr/local/bin}, and @file{/usr/local/etc}.
238
paul7190f4e2003-08-12 12:40:20 +0000239To install the Quagga suite, issue the following command at your shell
paul718e3742002-12-13 20:15:29 +0000240prompt: @command{make install}.
241
242@example
243%
244% make install
245%
246@end example
247
248@c A - removed this section and placed it with Install the Software
249@c @node Additional Notes, , Install the Software, Installation
250@comment node-name, next, previous, up
251@c @section Additional Notes
252
paul7190f4e2003-08-12 12:40:20 +0000253Quagga daemons have their own terminal interface or VTY. After
paul718e3742002-12-13 20:15:29 +0000254installation, you have to setup each beast's port number to connect to
255them. Please add the following entries to @file{/etc/services}.
256
257@example
258zebrasrv 2600/tcp # zebra service
259zebra 2601/tcp # zebra vty
260ripd 2602/tcp # RIPd vty
261ripngd 2603/tcp # RIPngd vty
262ospfd 2604/tcp # OSPFd vty
263bgpd 2605/tcp # BGPd vty
264ospf6d 2606/tcp # OSPF6d vty
jardin5a514b12003-12-23 10:50:21 +0000265ospfapi 2607/tcp # ospfapi
266isisd 2608/tcp # ISISd vty
paul718e3742002-12-13 20:15:29 +0000267@end example
268
269If you use a FreeBSD newer than 2.2.8, the above entries are already
270added to @file{/etc/services} so there is no need to add it. If you
271specify a port number when starting the daemon, these entries may not be
272needed.
273
274You may need to make changes to the config files in
275@file{@value{INSTALL_PREFIX_ETC}/*.conf}. @xref{Config Commands}.