The LOG Server

The LOG Server orders the logged data to avoid them to intermix with each other on the output media. The server offers buffering of the data to minimalize the impact to timing caused by the output. The logserver comes in two flavours. The simple one outputs the data using a putchar() function, which must be provided at compile-time. A network-flavoured version allows data to be transfered over the network using the tcp-based protocol.

Invocation

The logserver is a sigma0-client and should be loaded and started using the grub/rmgr pair. It requires the nameserver. The logserver supports the following cmdline-options:

--verbose
Print the task- and threadid of the thread that sent logging data together with the data.
--buffer
Set the size of the buffer to hold the log-data. If this option is not specified when compiled in no-net flavor, received log-data is printed immediately. With net flavor, the default buffer size is 4KB.
--net
Forward log-output to the network (ignored by simple flavour)
--nonet
Turn off network logging. (default)
--local
Print the log-output to the console. (default)
--nolocal
Turn off local logging.
--muxed
Flush the buffers in muxed format. This is only relevant when logging to the network. Then, this option allows to send data on Logging using multiple binary channels. (default in network flavour)
--nomuxed
Turn of the muxed mode. With the muxed mode beeing disabled, the data on a remote host can simply be shown using "telnet". However, binary data cannot be transfered this way.
--ip
Set the IP-address used for network-logging (ingored by simple flavour). If this option is not specified, the logserver will issue a bootp-request prior to network logging.
--prio
Set the L4-priority of the request thread (default 0x20).
--flushprio
Set the L4-priority of the flusher threads (default 0x20).

Receiving the logging data

To receive the logging data over the network, you need a suitable client-application. For non-muxed flushing mode (server cmdline-option "--nomuxed"), open a telnet-connection to the machine running the LOG server. When using the muxed flushing mode, you need an application the understands the The wire format of the muxed format. In both modes, the status messages of the LOG server itself will not be sent over the network, they are printed to the local terminal. The following box shows the begin example-session using the non-muxed flushing mode.

/home/jork/src/l4/pkg/log/server/src> telnet amalia      
Trying 141.76.48.118...
Connected to amalia.inf.tu-dresden.de.
Escape character is '^]'.

Welcome to the L4-Logserver.
Using a Buffersize of 14000. Log follows.

If you abort the TCP connection by stopping the remote client-applications, the LOG server will continue to fill its buffers. However, if the buffer is filled, local L4 clients trying to send data will be stopped until a new TCP connection is established and the data is flushed to the network.

Flushing the data

The buffered data is flushed regularly, if the server has the time to do so. A thread running at a low priority (1) triggers the flushing in a loop. The flushing is enforced by calling the LOG_flush() function at a log client, or by sending data on the telnet connection.

Building the LOG server

The directory of the Logserver (server/src/) contains a Makefile where you must specify the flavour of the server your want to build. Set the variable CONFIG_USE_TCPIP to 1 if you want networking support, set it to 0 if local printing is sufficient.

The server directory also contains a configfile (config.h), where you can tune the logserver to your needs.

Supported Network-Hardware

The logserver supports the following network cards:


Generated on Wed Apr 11 06:40:52 2012 for Logging and output facility for DROPS by  doxygen 1.5.6