lyskomd.texi 32.9 KB
Newer Older
David Byers's avatar
David Byers committed
1
\input texinfo
2
@c $Id: lyskomd.texi,v 1.10 1999/04/17 00:05:27 ceder Exp $
David Byers's avatar
David Byers committed
3
4
@c %**start of header
@setfilename lyskomd.info
5
6
@include version.texi
@settitle lyskomd @value{VERSION} Reference Manual
David Byers's avatar
David Byers committed
7
8
9
10
@setchapternewpage odd
@c %**end of header

@ifinfo
11
12
This is the reference manual for the lyskomd LysKOM server version
@value{VERSION}.
David Byers's avatar
David Byers committed
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27

Copyright @copyright{} 1999 Lysator ACS.

Permission is granted to make and distribute verbatim copies of this
specification provided the copyright notice and this permission notice
are preserved on all copies.
@end ifinfo

@dircategory LysKOM
@direntry
* lyskomd: (lyskomd).                lyskomd reference manual.
@end direntry

@titlepage
@sp 10
28
@title lyskomd Reference Manual
David Byers's avatar
David Byers committed
29
@sp 2
30
@subtitle Server version @value{VERSION}
David Byers's avatar
David Byers committed
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
@sp 2
@author by the lyskomd developers

@page
@vskip 0pt plus 1filll
Copyright @copyright{} 1995-1999 Lysator ACS

Permission is granted to make and distribute verbatim copies of this document
provided the copyright notice and this permission notice are preserved on all
copies.

Modified versions of this document may be redistributed with the added
condition that all modifications not cleared with the LysKOM development group
are clearly marked and that the entire modified work be redistributed under the
same conditions as the original.

Permission is granted to copy and distribute translations of this manual into
another language under the same conditions as for modified versions.

@end titlepage

@ifinfo
@node Top, Copying, (dir), (dir)
@comment  node-name,  next,  previous,  up
@top lyskomd

lyskomd is a server for the LysKOM conferencing system. This info file
58
documents version @value{VERSION} of lyskomd.
David Byers's avatar
David Byers committed
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92

@menu
* Copying::                     lyskomd is free software.
* Overview::                    Overview of LysKOM.
* Installation::                How to install lyskomd.
* Configuration::               How to configure lyskomd.
* Running lyskomd::             How to run lyskomd.
* Administration::              Administering a LysKOM server.
* Bugs::                        Known bugs.
@end menu

@end ifinfo

@node Copying, Overview, Top, Top
@comment  node-name,  next,  previous,  up
@chapter Copying

lyskomd is free software. It is distributed under the Gnu General Public 
License version 2. The file COPYING in the top level of the distribution 
contains the text of the license.


@node Overview, Installation, Copying, Top
@comment  node-name,  next,  previous,  up
@chapter Overview

LysKOM is a conferencing system@footnote{Or in modern terms, enabling
technology for Computer-Supported Cooperative Work (CSCW).}. Similar
systems were QZ-KOM and PortaCOM@footnote{Also known as ``PottaKOM'' and
``BortaKOM''.}. The LysKOM system is copyrighted by Lysator Academic
Computing Society and distributed under conditions of the GNU Public
License. LysKOM and its documentation is provided ``as is'' without
warranty of any kind.

93
94
This reference manual documents version @value{VERSION} of the lyskomd
LysKOM server. The lyskomd server is the work of several people. The main
David Byers's avatar
David Byers committed
95
96
97
contributors have been
Per Cederqvist @email{ceder@@lysator.liu.se}, 
Inge Wallin @email{inge@@lysator.liu.se}, 
98
99
100
Thomas Bellman @email{bellman@@lysator.liu.se}, 
David Byers @email{byers@@lysator.liu.se} and
Peter Eriksson @email{pen@@lysator.liu.se}.
David Byers's avatar
David Byers committed
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148

Commercial service for LysKOM is available from Signum Support
@url{http://www.signum.se/}.


@section History

In 1990, Per Cederqvist @email{ceder@@lysator.liu.se} and Peter Eriksson
@email{pen@@lysator.liu.se} and a few other persons started to write the
server. It was operational in the summer of 1990, even though the
members of Lysator discovered a thing called MUD. We started using RCS
on 20 May 1991. The first release was made on 16 Sept 1991. Around that
time we switched from RCS to CVS, and ceder started to write pcl-cvs (a
GNU Emacs front-end to CVS) instead of LysKOM. After a while, he started
writing Bugtrack, to be able to handle all bug reports he recieved about
pcl-cvs. He hopes to be able to devote some more time to LysKOM in the
future.



@node Installation, Configuration, Overview, Top
@comment  node-name,  next,  previous,  up
@chapter Installation

Instructions for compiling and installing lyskomd are in the file
INSTALL, located in the top level of the lyskomd distribution.
Installation should be straightforward on most platforms.


@node Configuration, Running lyskomd, Installation, Top
@comment  node-name,  next,  previous,  up
@chapter Configuration

There are two configuration files for lyskomd. One defines the server
options and the other defines aux-item types @ref{(protocol-a)The
Aux-Item List,The Aux-Item List}. 

@menu
* Server Configuration File::   The server configuration file.
* Aux-Item Definition File::    The aux-item definition file.
@end menu


@node Server Configuration File, Aux-Item Definition File, Configuration, Configuration
@comment  node-name,  next,  previous,  up
@section Server Configuration File

The server reads its configuration from a configuration file. The
149
default configuration file is @file{/usr/lyskom/etc/config}. The
David Byers's avatar
David Byers committed
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
location of the configuration file can be changed at run-time by
supplying an argument to lyskomd.

The configuration file is line oriented. Each line consists of a
parameter name followed by a colon, and the value of the parameter.
Empty lines and lines whose first non-blank character is a @code{#} are
ignored.

@menu
* Parameter Types::             Types of configuration parameters.
* Parameters::                  Valid configuration parameters.
@end menu

@node Parameter Types, Parameters, Server Configuration File, Server Configuration File
@comment  node-name,  next,  previous,  up
@subsection Parameter Types

Every parameter has a type. The legal types are:

@table @code
@item bool
The parameter can be true or false. Legal values are @code{on},
@code{true}, @code{yes} and @code{1} for true and @code{off},
@code{false}, @code{no} and @code{0} for false.

@item locale-name
The parameter is a locale name. The value must be a legal locale name of 
the system where lyskomd is running.

@item path
The parameter is a path name. The value must be a legal path on the
181
182
system where lyskomd is running. Most paths you can specify can be
either absolute paths (if they begin with a @samp{/}) or paths relative 
David Byers's avatar
David Byers committed
183
to the installation prefix which is specified at compile time or with
184
the @samp{Prefix} parameter in the configuration file.
David Byers's avatar
David Byers committed
185
186
187

@item portname
The parameter is a TCP/IP port. It can be a symbolic port name
188
(traditionally looked up in @file{/etc/services}) or a port number.
David Byers's avatar
David Byers committed
189
190
191
192
193
194
195
196
197
198
199
200
201
202

@item int
The parameter is a number of some sort. It can be a conference number,
text number or perhaps a timeout. 

@end table


@node Parameters,  , Parameter Types, Server Configuration File
@comment  node-name,  next,  previous,  up
@subsection Parameters

@table @code

203
204
@item Locale: @var{string}
Use @var{string} as the locale to run in. This parameter is only
David Byers's avatar
David Byers committed
205
206
207
208
available om systems which support the @code{setlocale} call. If this
parameter is not set, no call to @code{setlocale} will be made. The
default is unset.

209
@item Force ISO 8859-1: @var{bool}
David Byers's avatar
David Byers committed
210
211
This option is provided for those with dysfunctional computers that
cannot handle @code{setlocale} properly. If this is set, lyskomd will
212
handle texts according to the ISO 8859-1 (latin1) alphabet. Default
David Byers's avatar
David Byers committed
213
214
is off.

215
@item Prefix: @var{path}
David Byers's avatar
David Byers committed
216
217
All files that the server uses are found in sub-directories of this
directory. The default value of this parameter is set at compile time. 
218
The default at compile time is @file{/usr/lyskom}.
David Byers's avatar
David Byers committed
219

220
@item Send async: @var{bool}
David Byers's avatar
David Byers committed
221
222
223
224
Do not send any non-requested messages. This disables the sending of
messages about events in the server to all connections. Use of this
parameter is not recommended. Default is on.

225
226
@item Client port: @var{portname}
Listen for new clients on port @var{portname}. The default is 4894, which
David Byers's avatar
David Byers committed
227
228
229
is what all clients expect. Do not change this parameter without really
good reason.

230
231
@item Mux port: @var{portname}
Listen for mux connections on @var{portname}. Muxes can be used to
David Byers's avatar
David Byers committed
232
233
234
235
236
237
238
multiplex several clients on a single file descriptor. The mux runs as a
separate process. This was used historically when LysKOM ran on a
machine were only 20 file descriptors coule be open at once. The mux
code has not been released. Send a mail to
@email{bug-lyskom@@lysator.liu.se} if you need it. The default port
number is 4895.

239
@item Presentation of conferences: @var{int}
David Byers's avatar
David Byers committed
240
241
242
243
244
The number of the conference where presentations should be sent. 
Defaults to 1. This option is ignored in lyskomd 1.9 and later. Set this
using dbck or the @ref{(protocol-a)set-info,set-info}.


245
@item Presentation of persons: @var{int}
David Byers's avatar
David Byers committed
246
247
248
249
The number of the conference where presentations should be sent. 
Defaults to 2. This option is ignored in lyskomd 1.9 and later. Set this
using dbck or the @ref{(protocol-a)set-info,set-info}.

250
@item Motd-conference: @var{int}
David Byers's avatar
David Byers committed
251
252
253
254
The number of the conference where "message-of-the-day" messages should
be sent. Defaults to 3. This option is ignored in lyskomd 1.9 and later. 
Set this using dbck or the @ref{(protocol-a)set-info,set-info}.

255
@item News-conference: @var{int}
David Byers's avatar
David Byers committed
256
257
258
259
260
261
262
263
The number of the conference where news of interest to the readers of
this LysKOM server should be written. This is typically a conference
with very low traffic which everyone shoule be a member of. Clients
should offer new users to join it. Defaults to 4. This option is ignored
in lyskomd 1.9 and later. Set this using dbck or the
@ref{(protocol-a)set-info,set-info}.


264
@item Message of the day: @var{int}
David Byers's avatar
David Byers committed
265
266
267
268
269
270
Default message-of-the-day of this server. The text will be shown
automatically by conforming LysKOM clients when a user logs on. This
option is ignored in lyskomd 1.9 and later. Set this using dbck or the
@ref{(protocol-a)set-info,set-info}.


271
@item Garb: @var{bool}
David Byers's avatar
David Byers committed
272
273
274
Should the database be automatically purged of old texts?  The default
is on.

275
@item Never save: @var{bool}
David Byers's avatar
David Byers committed
276
277
278
279
280
Do not use unless you know what you are doing. (Note: there is currently
no-one in the LysKOM development group which knows exactly what this
option does, so if you @i{do} know what you're doing, by all means let
us know!) The default is off.

281
@item Log accesses: @var{path}
David Byers's avatar
David Byers committed
282
283
284
285
286
287
This parameter can only be set if the server has been compiled with
@code{LOGACCESSES} defined. It will save a trace of all activity in the
database to a file, for later use in simulations et c. Compiling with
@code{LOGACCESSES} slows the server down quite a lot, so it is normally
not defined. 

288
@item Data file: @var{path}
David Byers's avatar
David Byers committed
289
The path relative to the installation prefix where part of the database
290
is kept. The default is @file{db/lyskomd-data}.
David Byers's avatar
David Byers committed
291

292
@item Backup file: @var{path}
David Byers's avatar
David Byers committed
293
294
The path relative to the installation prefix where a backup of the
database is kept. This file will always contain a complete database, but 
295
it may be a little out-of-date. Default is @file{db/lyskomd-backup}.
David Byers's avatar
David Byers committed
296

297
@item Backup file 2: @var{path}
David Byers's avatar
David Byers committed
298
299
300
The path relative to the installation prefix where a previous generation
of the backup of the database is kept. This file may be needed if an
error in the backup file is detected during the creation of the data
301
file. Default is @file{db/lyskomd-backup-prev}.
David Byers's avatar
David Byers committed
302

303
@item Text file: @var{path}
David Byers's avatar
David Byers committed
304
The path relative to the installation prefix where the actual texts in
305
the database are kept. Default is @file{db/lyskomd-texts}.
David Byers's avatar
David Byers committed
306

307
@item Text backup file: @var{path}
David Byers's avatar
David Byers committed
308
309
310
311
When dbck is run with the @code{-g} option (@ref{(dbck)Invoking
dbck,Invoking dbck}, it will store the previous contents of the text
file in the file specified by this option. The path is relative to the
installation prefix. This file is never used by lyskomd itself. Default
312
is @file{db/lyskomd-texts-backup}.
David Byers's avatar
David Byers committed
313

314
@item Log file: @var{path}
David Byers's avatar
David Byers committed
315
The path relative to the installation prefix where log messages from
316
lyskomd are written. Default is @file{etc/server-log}.
David Byers's avatar
David Byers committed
317

318
319
@item Log statistics: @var{path}
Whenever lyskomd receives a SIGUSR1 it will append a timestamp and
David Byers's avatar
David Byers committed
320
321
a count of how many different atomic calls have been made in this file.
The path is relative to the installation prefix. Default is
322
@file{etc/lyskomd-log}.
David Byers's avatar
David Byers committed
323

324
@item Pid file: @var{path}
David Byers's avatar
David Byers committed
325
326
327
When lyskomd is up and running it will write its pid in this file. The
path is relative to the installation prefix. This file is used so the
@code{updateLysKOM} script can easily find out what pid the LysKOM
328
server has. Default is @file{etc/pid}.
David Byers's avatar
David Byers committed
329

330
@item Memory usage file: @var{path}
David Byers's avatar
David Byers committed
331
332
When lyskomd exits normally it appends some info on its usage of memory
to this file. The path is relative to the installation prefix. Almost
333
334
any memory leak bugs should be detectable by looking in this file.
Default is @file{etc/memory-usage}.
David Byers's avatar
David Byers committed
335

336
@item Aux-item definition file: @var{path}
David Byers's avatar
David Byers committed
337
338
339
This file defines which aux-items the server should support and how it
should handle them. @xref{Aux-Item Definition File} for more details. 
The path is relative to the installation prefix. Default is
340
@file{etc/aux-items.conf}.
David Byers's avatar
David Byers committed
341

342
343
344
345
346
347
@item Status file: @var{path}
This file is created by @code{komrunning} to indicate that lyskomd
should currently not be running.  When this file exists
@code{updateLysKOM} will send it a @code{SIGHUP} signal, so that it
saves the database and dies.  Default is @file{etc/status}.

348
@item Core directory: @var{path}
David Byers's avatar
David Byers committed
349
The Directory where core dumps are written. This path is relative to the 
350
installation prefix. Default is @file{cores}.
David Byers's avatar
David Byers committed
351

352
@item Idle timeout: @var{int}
David Byers's avatar
David Byers committed
353
354
355
Number of milliseconds to sleep when there is nothing for lyskomd
to do. Default is @code{120000} (two minutes.)

356
@item Garb timeout: @var{garb}
David Byers's avatar
David Byers committed
357
358
359
360
Number of milliseconds to sleep when the server is garbage-collecting
texts, but has nothing else important to do. Default is @code{100} (0.1
seconds.)

361
@item Sync timeout: @var{sync}
David Byers's avatar
David Byers committed
362
363
364
Number of milliseconds to sleep when lyskomd is saving its database.
Defaults to 0.

365
@item Permissive sync: @var{bool}
David Byers's avatar
David Byers committed
366
367
368
369
Turning this option on lets any session sync the LysKOM database.
Turning it off restricts the operation to LysKOM administrators. Default 
is off.

370
@item Garb interval: @var{int}
David Byers's avatar
David Byers committed
371
372
373
Number of minutes between each garb sweep. Defaults to @code{1440}, that
is, a garb sweep will be run once per day.

374
@item Sync interval: @var{int}
David Byers's avatar
David Byers committed
375
376
377
378
379
Number of minutes between syncs. The current version of lyskomd keeps
changes to the database in memory until they are synced to disk. This
parameter specifies the number of minutes the server waits before
attempting to dump the database. The default is @code{5}.

380
@item Sync retry interval: @var{int}
David Byers's avatar
David Byers committed
381
382
383
384
If anything goes wrong while trying to dump the data base (such as if
the disk is full), lyskomd will wait for this many minutes before trying
again. Default is @code{1}.

385
@item Max conference name length: @var{int}
David Byers's avatar
David Byers committed
386
387
The maximum length of conference names. The default is @code{60}.

388
@item Max password length: @var{int}
David Byers's avatar
David Byers committed
389
390
391
392
Only the first eight characters of the password are currently
significant, even if this number is much larger. The default is
@code{128}.

393
@item Max what am I doing length: @var{int}
David Byers's avatar
David Byers committed
394
395
396
397
The maximum length of the string permitted in the protocol A call
@ref{(protocol-a)change-what-i-am-doing, change-what-i-am-doing}. The
default is 60.

398
@item Max username length: @var{int}
David Byers's avatar
David Byers committed
399
400
The maximum length permitted for user names. Default is 128.

401
@item Max text length: @var{int}
David Byers's avatar
David Byers committed
402
403
The maximum length allowed for a text. The default is 131072 characters.

404
@item Max broadcast length: @var{int}
David Byers's avatar
David Byers committed
405
406
407
The maximum length allowed for broadcast messges. The default is 1024
characters.

408
@item Max regexp length: @var{int}
David Byers's avatar
David Byers committed
409
410
411
The maximum length allowed for regexps in various calls. The default is
1024 characters.

412
@item Max marks per person: @var{int}
David Byers's avatar
David Byers committed
413
414
415
The maximum number of marks a person is allowed to have. The default is
2048.

416
@item Max marks per text: @var{int}
David Byers's avatar
David Byers committed
417
418
The maximum number of marks a text can have. The default is 1024.

419
@item Max recipients per text: @var{int}
David Byers's avatar
David Byers committed
420
421
The maximum number of recipients of a text. The default is 512.

422
@item Max comments per text: @var{int}
David Byers's avatar
David Byers committed
423
424
425
The maximum number of comments a text can have. The default is 128.


426
@item Max footnotes per text: @var{int}
David Byers's avatar
David Byers committed
427
428
The maximum number of footnotes a text can have. The default is 32.

429
@item Max links per text: @var{int}
David Byers's avatar
David Byers committed
430
431
FIXME: What is this?

432
@item Max mark_as_read chunks: @var{int}
David Byers's avatar
David Byers committed
433
434
FIXME: What is this?

435
@item Max super_conf loop: @var{int}
David Byers's avatar
David Byers committed
436
437
FIXME: What is this?

438
@item Max accept_async len: @var{int}
David Byers's avatar
David Byers committed
439
440
441
Maximum length of list accepted in the accept_async call. Default is
128.

442
@item Max aux_items deleted per call: @var{int}
David Byers's avatar
David Byers committed
443
444
445
Maximum number of aux_items that can be deleted in one call. Default is
128.

446
@item Max aux_items added per call: @var{int}
David Byers's avatar
David Byers committed
447
448
Maximum number of aux_items that can be added at once. Default is 2048.

449
@item Default garb nice: @var{int}
David Byers's avatar
David Byers committed
450
451
452
453
454
Each conference has a lifetime for texts written in it. The lifetime is
counted in days, and can be set for each conference by the administrator
of the conference. This is the default value assigned to new
conferences. Default is 77 days.

455
@item Default keep commented nice: @var{int}
David Byers's avatar
David Byers committed
456
457
458
459
460
A text will not be removed if it has comments newer than a certain
number of days. This number can be set for each conference. This
parameter specifies the default value for that number of days. The
default is 77.

461
@item Max client transmit queue: @var{int}
Per Cederqvist's avatar
Per Cederqvist committed
462
Max number of pending data blocks in the reply queue to a client. If
David Byers's avatar
David Byers committed
463
464
465
466
there is ever more than this many data blocks in the queue the client
will be disconnected. Each atomic question typically generates two data
blocks. Default is 300.

467
@item Max simultaneous client replies: @var{int}
David Byers's avatar
David Byers committed
468
469
470
This is a performance tuning parameter of little real interest. Default
is 10.

471
@item Open files: @var{int}
David Byers's avatar
David Byers committed
472
473
474
475
476
Try to persuade the operating system to allow lyskomd to have this many
open file descriptors simultaneously. Each client that is connected to
the server occupies one file descriptor, and lyskomd needs several file
descriptors for internal purposes. Default is to not use this parameter.

477
@item Anyone can create new persons: @var{bool}
David Byers's avatar
David Byers committed
478
479
480
If this is set, anyone can create a new person, even if he lacks
special bits for doing so. Default is on.

481
@item Anyone can create new conferences: @var{bool}
David Byers's avatar
David Byers committed
482
483
484
If this is set, anyone can create a new conferences, even if he lacks
special bits for doing so. Default is on.

485
@item Allow creation of persons before login: @var{bool}
David Byers's avatar
David Byers committed
486
487
488
489
490
If this is set, persons can connect the the server and create a new
person without logging in.  This is how new users register in open
environments. If this option is off, then new persons can only be
created by existing users. The default is on.

491
@item Default change name capability: @var{bool}
David Byers's avatar
David Byers committed
492
493
494
If this is set, new users are created with the ability to change their
own name. Default is on.

495
@item Ident-authentication: @var{policy}
David Byers's avatar
David Byers committed
496
497
Decide how strictly the server should use the IDENT protocol.
The policy can take any of three values:
498

David Byers's avatar
David Byers committed
499
500
501
502
503
504
505
506
507
508
509
510
@table @asis
@item @code{off} or @code{never}
Do not use the IDENT protocol.

@item @code{on} or @code{try}
Use it, but allow logins even if the lookup fails.

@item @code{require} or @code{required}
Disallow connections if the server cannot find a IDENT login name.
@end table


511
@item Log login: @var{bool}
David Byers's avatar
David Byers committed
512
513
Should logins be logged to the log file?  Default value is off.

514
@item Cache conference limit: @var{int}
David Byers's avatar
David Byers committed
515
516
517
518
How many conference statuses the server cache should hold in main
memory. Default is 20. This parameter should be set to at least the
number of expected simultaneous logins.

519
@item Cache person limit: @var{int}
David Byers's avatar
David Byers committed
520
521
522
523
How many person statuses the server cache should hold in main
memory. Default is 20. This parameter should be set to at least the
number of expected simultaneous logins.

524
@item Cache text_stat limit: @var{int}
David Byers's avatar
David Byers committed
525
526
527
528
How many text statuses the server cache should hold in main
memory. The default is 20. This parameter should be increased on busy
servers.

529
530
@item Echo: @var{string}
Write @var{string} in the log when the config file is read.
David Byers's avatar
David Byers committed
531

532
533
534
@item Jubel: @var{pers_no} @var{text_no}
States that @var{pers_no} is not allowed to create text number
@var{text_no}. Default is unset.
David Byers's avatar
David Byers committed
535

536
537
538
@item Jubel: @var{pers_no} @var{dividend} @var{remainder}
States that @var{pers_no} is not allowed to create any text number
@var{T} which meets the condition @var{T} % @var{dividend} == @var{remainder}.
David Byers's avatar
David Byers committed
539
540
Default is unset.

541
@item Add members by invitation: @var{bool}
David Byers's avatar
David Byers committed
542
543
544
545
If this is set, then adding others as members to a conference sets the
invitation bit of the membership. If this is off, the membership bit is
set to whatever the caller specifies. The default is on.

546
@item Allow secret memberships: @var{bool}
David Byers's avatar
David Byers committed
547
548
549
550
If this is set, then memberships may be secret. Otherwise any attempt
to create a secret membership or change an existing membership to a
secret membership will fail. The default is on.

551
@item Allow reinvitations: @var{bool}
David Byers's avatar
David Byers committed
552
553
554
555
556
557
If this is set, then it is possible to set the invitation bit of a
membership even after it has been cleared. If it is not set, then the
invitation bit of a conference type can only be set when the
membership is created. It can be cleared at any time. The default is
off.

558
@item Regexps use collate table: @var{bool}
David Byers's avatar
David Byers committed
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
If this is set, regexp matching of conference names uses the same
collate table used by regular matching. This usually implies that the
regexp ``foo'' will match ``foo'', ``Foo'', ``fOo'' and several other
variants. The defalt is on.

@end table


@node Aux-Item Definition File,  , Server Configuration File, Configuration
@comment  node-name,  next,  previous,  up
@section Aux-Item Definition File

The default aux-item definition file should not be changed unless it is
really necessary. The need to change the definitions will probably only
arise at installations used for client or server development.

575
576
The location of the aux-item definition file is specified by the
@code{Aux-item definition file} option in the server configuration
577
file. The default location is @file{/usr/lyskom/etc/aux-items.conf}.
David Byers's avatar
David Byers committed
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597


@subsection Syntax of the Aux-Item Definition File

The aux-item definition file contains a sequence of aux-item
definitions. Each definition specifies one type of predefined aux-item:
its number, name, and properties. Empty lines and all characters from a
# character to the end of the line are ignored.

Each entry has the following format:

@example
        tag : name (target, target, ... )
        @{
            field = value;
            field = value;
            ...
        @}
@end example

598
@var{tag} is an integer, the aux-item's tag. If a tag is defined more than 
David Byers's avatar
David Byers committed
599
600
once, the last definition is used. 

601
The @var{target}s specify what kind of objects aux-items with tag @var{tag}
David Byers's avatar
David Byers committed
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
can be added to. Valid targets are:

@table @code
@item any
Aux-items with the specified tag can be added to any object in the
database. This is shorthand for @code{text,conference,letterbox,server}.

@item text
Aux-items with the specified tag can be added to texts.

@item conference
Aux-items with the specified tag can be added to conferences that are
@i{not} letterboxes.

@item letterbox
Aux-items with the specified tag can be added to conferences that are
letterboxes.
619
620
621
622

@item server
Aux-items with the specified tag can be added to the server itself.

David Byers's avatar
David Byers committed
623
624
625
626
627
628
629
630
631
632
@end table

It is legal to add one of the keywords @code{create} or @code{modify}
before any target except @code{server}. If @code{create} is specified,
aux-items with the specified tag can only be added when an object is
being created. They cannot be added later. If @code{modify} is
specified, aux-items with the specified tag can only be added after an
object has been created. They cannot be added when the object is being
created.

633
Each @var{field}/@var{value} pair specifies a property of aux-items with the 
David Byers's avatar
David Byers committed
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
specified tag. Most values are boolean or trillian. Legal values for
either type are @code{true} and @code{false}. Boolean values have
reasonable defaults; trillian values can be unset.

@table @code

@item author-only
Boolean, default false. When true, only the author of a text or
supervisor of a conference can create items with this tag. 

@item supervisor-only
Boolean, default false. When true, only the supervisors of the author or
letterbox can create items with this tag. In all likelihood, the
implementation of this flag is screwed up.

@item permanent           
650
651
652
Boolean, default false. When true, aux-items with this tag cannot be
deleted once they have been created.  (They will be deleted
automatically when the object they are assigned to is deleted.)
David Byers's avatar
David Byers committed
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738

@item unique
Boolean, default false. When true, there can only be one non-deleted
item with this tag per creator.

@item inherit-limit
Integer, default 0. The maximum number of times items with this tag can
be inherited, plus one. Zero means an unlimited number of times, one
means no times, 2 means once and so forth. This number overrides the
inherit-limit set by the client only if that number is higher than this
one.

@item inherit
Trillian. When set, the inherit bit on new items with this tag is forced
to the specified value.

@item secret
Trillian. When set, the secret bit on new items with this tag is forced
to the specified value.

@item hide-creator        
Trillian. When set, the hide-creator bit on new items with this tag is
forced to the specified value.

@item dont-garb	    
Trillian. When set, the dont-garb bit on new items will be forced to the
specified value.

@item reserved-2
@item reserved-3
@item reserved-4
Trillian. When set, these flags force the values of the three reserved
bits in the aux-item flags field. These should only be used by lyskomd
developers, and then only very carefully.

@item validate            
String, default none. When set, this specifies a regexp that must match
the data field in newly created items with this tag. If the regexp fails
to match, then the item will not be created. The syntax for strings is
essentially the same as the syntax used in C files.

@end table

There are a few fields which specify actions the server is to take when
something happens to aux-items with the specified tag. Each of these
values is a function specification, the name of a trigger function
defined in lyskomd. The syntax for functions is the name followed by
an empty pair of parens. It is not possible to pass arguments to the
functions yet.

@table @code
@item add-trigger
Function to call when an item with the specified tag is added to an
object.

@item delete-trigger
Function to call when an item with the specified tag is scheduled for
deletion.

@item undelete-trigger
Function to call when an item with the specified tag scheduled for
deletion is unscheduled. It should undo the effects of the delete
trigger.
@end table



@node Running lyskomd, Administration, Configuration, Top
@comment  node-name,  next,  previous,  up
@chapter Running lyskomd

This section explains how to run lyskomd, the files it uses and how it
can be controlled while running.

@menu
* Invoking lyskomd::            How to run lyskomd.
* Signals::                     How to control lyskomd with Unix signals.
* Files::                       Files used by lyskomd.
@end menu


@node Invoking lyskomd, Signals, Running lyskomd, Running lyskomd
@comment  node-name,  next,  previous,  up
@section Invoking lyskomd

@example
739
        lyskomd [-d] [@var{config-file}]
David Byers's avatar
David Byers committed
740
741
742
743
744
745
746
@end example

The option @code{-d} adds one to the debug level. The amount of output
on stderr is increased for each time the option is specified on the
command line. Furthermore, if this option is used, lyskomd will not run
as a daemon, but will stay in forground mode.

747
Using one @code{-d} makes the process print a `>' for every timeout, a
David Byers's avatar
David Byers committed
748
749
750
751
message for every person that is connecting or disconnecting and a
message for every successful or unsuccessful communication to the
process.

752
The optional @var{config-file} argument can be used to specify the server
David Byers's avatar
David Byers committed
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
configuration file. @xref{Server Configuration File}.


@node Signals, Files, Invoking lyskomd, Running lyskomd
@comment  node-name,  next,  previous,  up
@section Signals

It is possible to control some aspects of lyskomd using Unix signals.
The following signals have special meaning to the server:

@table @code
@item SIGHUP
Logs out all sessions, saves the database and exits normally.

@item SIGQUIT
Saves the database and dump core. (This should only be used for
debugging purposes.)

@item SIGUSR1
Print statistics about how often different commands have been used
since the process started.

@item SIGUSR2
Forks a child that immediately dumps core. The main process just waits
777
until the child is done and then continues.
David Byers's avatar
David Byers committed
778
779
780
781
782
783
784
785
786
787
@end table


@node Files,  , Signals, Running lyskomd
@comment  node-name,  next,  previous,  up
@section Files Used by lyskomd

All file names can be changed in the server configuration file.
@xref{Parameters}.

788
@table @file
David Byers's avatar
David Byers committed
789
@item /usr/lyskom
790
791
792
Default value of the @code{Prefix} parameter. The default of this value
is set at compile time, but it can be changed in the server
configuration file.  @xref{Parameters}.
David Byers's avatar
David Byers committed
793

794
@item @code{Prefix}/db/lyskomd-data
795
Half of the database: all status information.
David Byers's avatar
David Byers committed
796

797
@item @code{Prefix}/db/lyskomd-texts
David Byers's avatar
David Byers committed
798
799
The other half of the database: the actual texts.

800
801
@item @code{Prefix}/db/lyskomd-backup
A backup copy of @file{lyskomd-data}. Never, ever delete this file
David Byers's avatar
David Byers committed
802
803
804
unless you know what you are doing, or you may lose the entire data
base. Most of the time this is the only complete database file!

805
@item @code{Prefix}/etc/pid
David Byers's avatar
David Byers committed
806
807
File with the pid of the lyskom-process.

808
@item @code{Prefix}/etc/memory-usage
David Byers's avatar
David Byers committed
809
810
811
On normal exit, @code{lyskomd} will append some statistics to this file. 
It can be used for detecting memory leaks.

812
@item @code{Prefix}/etc/aux-items.conf
David Byers's avatar
David Byers committed
813
814
815
816
817
818
819
820
821
822
823
824
This file contains definitions of the aux-items that the server should
support.  It is read by @code{lyskomd} at startup. 

@end table



@node Administration, Bugs, Running lyskomd, Top
@comment  node-name,  next,  previous,  up
@chapter Administration

The first thing you will have to do is to follow the instructions in the
825
file @file{INSTALL}. This will set up the LysKOM system with a database
David Byers's avatar
David Byers committed
826
827
828
829
830
831
832
833
834
835
836
837
containing a few necessary conferences and one person - the
administrator.

Once the LysKOM system is running, there is not much you will have to do
to keep it that way. One thing to remember is that the current release
of the server has an incomplete handling of garbage collection of the
database. The database is split into two files, the information file and
the text file. Newly written texts are concatenated to the text file and
old texts are never removed. The information file contains information
about conferences, users and where in the text file the texts are. This
file is properly garbage collected, but not the text file.

838
839
840
841
842
843
844
845
846
847
848
849
850
851
There is a program called @code{dbck} (Data Base Check) which is used to
check the consistency of the LysKOM database. This program can also be
used to shrink the text file. To do this, just type @samp{dbck
-g}. @xref{(dbck)}. When @code{dbck} is to be run on the database, the
LysKOM server @emph{must} be stopped, or unrepairable damage may
result. See below for a description on how to stop the server.

There is a program called @code{updateLysKOM} which is used to ensure
continuous operation. This program should be run with certain intervals,
for instance from @code{cron}. If the LysKOM server has died for some
reason, @code{updateLysKOM} restarts it. If the server is still running
properly, @code{updateLysKOM} sends a signal (@code{SIGUSR1}) to it,
which causes the server to write some statistics to a file named
@file{etc/lyskomd-log} in the lyskom directory.
David Byers's avatar
David Byers committed
852
853
854

Taking the server down cleanly can be done in two ways: through the use
of the LysKOM protocol on a socket, preferably through the use of a
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
suitable client, or by sending the signal @code{SIGHUP} to it. This will
cause the server to save the database and close all client
connections. It will also create a file named @file{etc/memory-usage} in
which the memory usage of the server is reported.

To prevent @code{updateLysKOM} from restarting a server, create a file
named @file{/usr/lyskom/etc/status}. The file should contain a valid
mail address on the first line. @code{updateLysKOM} will not restart the
server as long as that file exists. In addition, if the file is between
1 and 2 hours old an email will be sent to the mail address found in the
file. If the file is older than that, an error message will be printed
on stderr and updateLysKOM will exit with a non-zero exit status. cron
is expected to deliver the error message to an operator.

The shell script @code{komrunning} can be used to start and stop the
LysKOM server. With no arguments, it will report the status.
David Byers's avatar
David Byers committed
871
872
873
874
875

@example
	komrunning off
@end example

876
877
878
879
880
will (attempt to) shut down the server, creating the file
@file{/usr/lyskom/etc/status}.  If the user running @code{komrunning}
doesn't have permission to send signals to @code{lyskomd} the actual
shutdown will be delayed until the next time that @code{updateLysKOM} is
run.
David Byers's avatar
David Byers committed
881
882
883
884
885

@example
	komrunning on
@end example

886
887
888
will restart the server.  The actual starting of the server will be done
by @code{updateLysKOM} the next time it is run.  @code{komrunning} only
removes the lock file.
David Byers's avatar
David Byers committed
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914


@node Bugs,  , Administration, Top
@comment  node-name,  next,  previous,  up
@chapter Known Bugs

@itemize @bullet
@item lyskomd should re-read the config file when a @code{SIGHUP} is
received.

@item lyskomd should terminate when a @code{SIGINT} or @code{SIGTERM} is
received.

@item The security policy is vague and the implementation is frayed at
the edges.

@item The choice of asynchronous messages is not very good.

@item The server uses too much memory.

@end itemize



@contents
@bye