]> arthur.barton.de Git - ngircd-alex.git/blob - INSTALL
eec2b37f6c9c7cfbf21963bcf9f7b2d65d3f5bf7
[ngircd-alex.git] / INSTALL
1
2                      ngIRCd - Next Generation IRC Server
3                            http://ngircd.barton.de/
4
5                (c)2001-2013 Alexander Barton and Contributors.
6                ngIRCd is free software and published under the
7                    terms of the GNU General Public License.
8
9                                 -- INSTALL --
10
11
12 I. Upgrade Information
13 ~~~~~~~~~~~~~~~~~~~~~~
14
15 Differences to previous version 
16
17 - Starting with ngIRCd 21, the ciphers used by SSL are configurable and
18   default to HIGH:!aNULL:@STRENGTH (OpenSSL) or SECURE128 (GnuTLS).
19   Previous version were using the OpenSSL or GnuTLS defaults, DEFAULT
20   and NORMAL respectively.
21
22 Differences to version 19.x
23
24 - Starting with ngIRCd 20, users can "cloak" their hostname only when the
25   configuration variable "CloakHostModeX" (introduced in 19.2) is set.
26   Otherwise, only IRC operators, other servers, and services are allowed to
27   set mode +x. This prevents regular users from changing their hostmask to
28   the name of the IRC server itself, which confused quite a few people ;-)
29
30 Differences to version 17
31
32 - Support for ZeroConf/Bonjour/Rendezvous service registration has been
33   removed. The configuration option "NoZeroconf" is no longer available.
34
35 - The structure of ngircd.conf has been cleaned up and three new configuration
36   sections have been introduced: [Limits], [Options], and [SSL].
37   Lots of configuration variables stored in the [Global] section are now
38   deprecated there and should be stored in one of these new sections (but
39   still work in [Global]):
40     "AllowRemoteOper"    -> [Options]
41     "ChrootDir"          -> [Options]
42     "ConnectIPv4"        -> [Options]
43     "ConnectIPv6"        -> [Options]
44     "ConnectRetry"       -> [Limits]
45     "MaxConnections"     -> [Limits]
46     "MaxConnectionsIP"   -> [Limits]
47     "MaxJoins"           -> [Limits]
48     "MaxNickLength"      -> [Limits]
49     "NoDNS"              -> [Options], and renamed to "DNS"
50     "NoIdent"            -> [Options], and renamed to "Ident"
51     "NoPAM"              -> [Options], and renamed to "PAM"
52     "OperCanUseMode"     -> [Options]
53     "OperServerMode"     -> [Options]
54     "PingTimeout"        -> [Limits]
55     "PongTimeout"        -> [Limits]
56     "PredefChannelsOnly" -> [Options]
57     "SSLCertFile"        -> [SSL], and renamed to "CertFile"
58     "SSLDHFile"          -> [SSL], and renamed to "DHFile"
59     "SSLKeyFile"         -> [SSL], and renamed to "KeyFile"
60     "SSLKeyFilePassword" -> [SSL], and renamed to "KeyFilePassword"
61     "SSLPorts"           -> [SSL], and renamed to "Ports"
62     "SyslogFacility"     -> [Options]
63     "WebircPassword"     -> [Options]
64   You should adjust your ngircd.conf and run "ngircd --configtest" to make
65   sure that your settings are correct and up to date!
66
67 Differences to version 16
68
69 - Changes to the "MotdFile" specified in ngircd.conf now require a ngircd
70   configuration reload to take effect (HUP signal, REHASH command).
71
72 Differences to version 0.9.x
73
74 - The option of the configure script to enable support for Zeroconf/Bonjour/
75   Rendezvous/WhateverItIsNamedToday has been renamed:
76     --with-rendezvous  ->  --with-zeroconf
77
78 Differences to version 0.8.x
79
80 - The maximum length of passwords has been raised to 20 characters (instead
81   of 8 characters). If your passwords are longer than 8 characters then they
82   are cut at an other position now.
83
84 Differences to version 0.6.x
85
86 - Some options of the configure script have been renamed:
87     --disable-syslog  ->  --without-syslog
88     --disable-zlib    ->  --without-zlib
89   Please call "./configure --help" to review the full list of options!
90
91 Differences to version 0.5.x
92
93 - Starting with version 0.6.0, other servers are identified using asynchronous
94   passwords: therefore the variable "Password" in [Server]-sections has been
95   replaced by "MyPassword" and "PeerPassword".
96
97 - New configuration variables, section [Global]: MaxConnections, MaxJoins
98   (see example configuration file "doc/sample-ngircd.conf"!).
99
100
101 II. Standard Installation
102 ~~~~~~~~~~~~~~~~~~~~~~~~~
103
104 ngIRCd is developed for UNIX-based systems, which means that the installation
105 on modern UNIX-like systems that are supported by GNU autoconf and GNU
106 automake ("configure") should be no problem.
107
108 The normal installation procedure after getting (and expanding) the source
109 files (using a distribution archive or GIT) is as following:
110
111   0) Satisfy prerequisites
112   1) ./autogen.sh  [only necessary when using GIT]
113   2) ./configure
114   3) make
115   4) make install
116
117 (Please see details below!)
118
119 Now the newly compiled executable "ngircd" is installed in its standard
120 location, /usr/local/sbin/.
121
122 The next step is to configure and afterwards starting the daemon. Please
123 have a look at the ngircd(8) and ngircd.conf(5) manual pages for details
124 and all possible options -- and don't forget to run "ngircd --configtest"
125 to validate your configuration file!
126
127 If no previous version of the configuration file exists (the standard name
128 is /usr/local/etc/ngircd.conf), a sample configuration file containing all
129 possible options will be installed there. You'll find its template in the
130 doc/ directory: sample-ngircd.conf.
131
132
133 0): Satisfy prerequisites
134
135 When building from source, you'll need some other software to build ngIRCd:
136 for example a working C compiler, make tool, GNU automake and autoconf (only
137 when not using a distribution archive), and a few libraries depending on the
138 features you want to compile in (like IDENT support, SSL, and PAM).
139
140 If you are using one of the "big" operating systems or Linux distributions,
141 you can use the following commands to install all the required packages to
142 build the sources including all optional features and to run the test suite:
143
144 * RedHat / Fedora based distributions:
145
146   yum install \
147     autoconf automake expect gcc glibc-devel gnutls-devel \
148     libident-devel make pam-devel tcp_wrappers-devel telnet zlib-devel
149
150 * Debian / Ubuntu based distributions:
151
152   apt-get install \
153     autoconf automake build-essential expect libgnutls-dev \
154     libident-dev libpam-dev libwrap0-dev libz-dev telnet
155
156
157 1): "autogen.sh"
158
159 The first step, autogen.sh, is only necessary if the configure-script isn't
160 already generated. This never happens in official ("stable") releases in
161 tar.gz-archives, but when using GIT.
162
163 This step is therefore only interesting for developers.
164
165 autogen.sh produces the Makefile.in's, which are necessary for the configure
166 script itself, and some more files for make. To run autogen.sh you'll need
167 GNU autoconf and GNU automake: at least autoconf 2.61 and automake 1.10 are
168 requird, newer is better. But don't use automake 1.12 or newer for creating
169 distribution archives: it will work but lack "de-ANSI-fucation" support in the
170 generated Makefile's! Stick with automake 1.11.x for this purpose ...
171 So automake 1.11.x and autoconf 2.67+ is recommended.
172
173 Again: "end users" do not need this step and neither need GNU autoconf nor GNU
174 automake at all!
175
176
177 2): "./configure"
178
179 The configure-script is used to detect local system dependencies.
180
181 In the perfect case, configure should recognize all needed libraries, header
182 files and so on. If this shouldn't work, "./configure --help" shows all
183 possible options.
184
185 In addition, you can pass some command line options to "configure" to enable
186 and/or disable some features of ngIRCd. All these options are shown using
187 "./configure --help", too.
188
189 Compiling a static binary will avoid you the hassle of feeding a chroot dir
190 (if you want use the chroot feature). Just do something like:
191   CFLAGS=-static ./configure [--your-options ...]
192 Then you can use a void directory as ChrootDir (like OpenSSH's /var/empty).
193
194
195 3): "make"
196
197 The make command uses the Makefiles produced by configure and compiles the
198 ngIRCd daemon.
199
200
201 4): "make install"
202
203 Use "make install" to install the server and a sample configuration file on
204 the local system. Normally, root privileges are necessary to complete this
205 step. If there is already an older configuration file present, it won't be
206 overwritten.
207
208 These files and folders will be installed by default:
209
210 - /usr/local/sbin/ngircd: executable server
211 - /usr/local/etc/ngircd.conf: sample configuration (if not already present)
212 - /usr/local/share/doc/ngircd/: documentation
213 - /usr/local/share/man/: manual pages
214
215
216 III. Additional features
217 ~~~~~~~~~~~~~~~~~~~~~~~~
218
219 The following optional features can be compiled into the daemon by passing
220 options to the "configure" script. Most options can handle a <path> argument
221 which will be used to search for the required libraries and header files in
222 the given paths ("<path>/lib/...", "<path>/include/...") in addition to the
223 standard locations.
224
225 * Syslog Logging (autodetected by default): 
226   --with-syslog[=<path>] / --without-syslog
227
228   Enable (disable) support for logging to "syslog", which should be
229   available on most modern UNIX-like operating systems by default.
230
231 * ZLib Compression (autodetected by default):
232   --with-zlib[=<path>] / --without-zlib
233
234   Enable (disable) support for compressed server-server links.
235   The Z compression library ("libz") is required for this option.
236   
237 * IO Backend (autodetected by default):
238   --with-select[=<path>] / --without-select
239   --with-poll[=<path>] / --without-poll
240   --with-devpoll[=<path>] / --without-devpoll
241   --with-epoll[=<path>] / --without-epoll
242   --with-kqueue[=<path>] / --without-kqueue  
243
244   ngIRCd can use different IO "backends": the "old school" select() and poll()
245   API which should be supported by most UNIX-like operating systems, or the
246   more efficient and flexible epoll() (Linux >=2.6), kqueue() (BSD) and
247   /dev/poll APIs.
248   By default the IO backend is autodetected, but you can use "--without-xxx"
249   to disable a more enhanced API.
250   When using the epoll() API, support for select() is compiled in as well by
251   default to enable the binary to run on older Linux kernels (<2.6), too.
252
253 * IDENT-Support:
254   --with-ident[=<path>]
255
256   Include support for IDENT ("AUTH") lookups. The "ident" library is
257   required for this option.
258
259 * TCP-Wrappers:
260   --with-tcp-wrappers[=<path>] 
261
262   Include support for Wietse Venemas "TCP Wrappers" to limit client access
263   to the daemon, for example by using "/etc/hosts.{allow|deny}".
264   The "libwrap" is required for this option.
265
266 * PAM:
267   --with-pam[=<path>]
268
269   Enable support for PAM, the Pluggable Authentication Modules library.
270   See doc/PAM.txt for details.
271
272 * SSL:
273   --with-openssl[=<path>]
274   --with-gnutls[=<path>]
275
276   Enable support for SSL/TLS using OpenSSL or gnutls libraries.
277   See doc/SSL.txt for details.
278
279 * IPv6:
280   --enable-ipv6
281
282   Adds support for version 6 of the Internet Protocol.
283
284
285 IV. Useful make-targets
286 ~~~~~~~~~~~~~~~~~~~~~~~
287
288 The Makefile produced by the configure-script contains always these useful
289 targets:
290
291  - clean: delete every product from the compiler/linker
292    next step: -> make
293
294  - distclean: the above plus erase all generated Makefiles
295    next step: -> ./configure
296
297  - maintainer-clean: erase all automatic generated files
298    next step: -> ./autogen.sh
299
300
301 V. Sample configuration file ngircd.conf
302 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
303
304 In the sample configuration file, there are comments beginning with "#" OR
305 ";" -- this is only for the better understanding of the file.
306
307 The file is separated in five blocks: [Global], [Features], [Operator],
308 [Server], and [Channel].
309
310 In the [Global] section, there is the main configuration like the server
311 name and the ports, on which the server should be listening. Options in
312 the [Features] section enable or disable functionality in the daemon.
313 IRC operators of this server are defined in [Operator] blocks, remote
314 servers are configured in [Server] sections, and [Channel] blocks are
315 used to configure pre-defined ("persistent") IRC channels.
316
317 The meaning of the variables in the configuration file is explained in the 
318 "doc/sample-ngircd.conf", which is used as sample configuration file in
319 /usr/local/etc after running "make install" (if you don't already have one)
320 and in the ngircd.conf(5) manual page.
321
322
323 VI. Command line options
324 ~~~~~~~~~~~~~~~~~~~~~~~~
325
326 These parameters could be passed to the ngIRCd:
327
328 -f, --config <file>
329         The daemon uses the file <file> as configuration file rather than
330         the standard configuration /usr/local/etc/ngircd.conf.
331
332 -n, --nodaemon
333         ngIRCd should be running as a foreground process.
334
335 -p, --passive
336         Server-links won't be automatically established.
337
338 -t, --configtest
339         Reads, validates and dumps the configuration file as interpreted
340         by the server. Then exits.
341
342 Use "--help" to see a short help text describing all available parameters
343 the server understands, with "--version" the ngIRCd shows its version
344 number. In both cases the server exits after the output.
345
346 Please see the ngircd(8) manual page for complete details!