5.7 Output Configuration

The statement discussed in this section configure formatting of the server load table on output.

Config: head number

Print at most number entries from the top of the table, i.e. the number of the less loaded server entries.

Config: tail number

Print at most number entries from the bottom of the table, i.e. the number of the most loaded server entries.

Config: output-file string

Send output to the channel, identified by string. Unless string starts with a pipe sign, it is taken as a literal name of the file. If this file does not exist, it is created. If it exists, it is truncated. The file name can refer to a regular file, symbolic link or named pipe.

If string starts with a ‘|’ (pipe), the rest of the string is taken as the name of an external program and its command line arguments. The program is started before slb enters its main loop and the formatted load table is piped on its standard input.

Config: begin-output-message string

Defines the text to be output before the actual load table contents. The string is taken literally. For example, if you want it to appear on a line by itself, put ‘\n’ at the end of it (see backslash-interpretation).

Config: end-output-message string

Defines the text to be output after the actual load table contents. The string is taken literally.

Config: output-format string

Defines format for outputting load table entries. See the subsection below (see section Output Format String), for a description of available format specifications.