Technical data

8. Documentation for Developers
LOG_BOOT_SEQ Setting this variable to “yes” will cause bootlogd to log all console output
during boot to the file /var/tmp/boot.log. This variable has “yes” as a default value.
DEBUG_KEEP_BOOTLOGD Normally bootlogd is terminated at the end of the boot pro-
cess. Activating this variable prevents this and thus allows for logging console output
during the whole runtime.
DEBUG_MDEV Setting this variable generates a logfile for the mdev-daemon, which is re-
sponsible for creating device nodes under /dev.
8.4.5. Hints
It is always better to use curly brackets “{. . . }” instead of normal ones“(. . . )”. However,
care must be taken to ensure that after the opening bracket a space or a new line follows
before the next command and before the closing brackets a Semicolon or a new line. For
example:
{ echo "cpu"; echo "quit"; } | ...
is equal to:
{
echo "cpu"
echo "quit"
} | ...
A script may be stopped by an “exit” at any time. This is deadly for start scripts
(opt/etc/boot.d/..., opt/etc/rc.d/...), stop-scripts (opt/etc/rc0.d/...) and
ip-up/ip-down-scripts (opt/etc/ppp/...) because the following scripts will not be run
as well. If in doubt, keep your fingers away.
KISS Keep it small and simple. You want to use Perl for scripting? The scripting
abilities of fli4l are not enough for you? Rethink your attitude! Is your OPT really
necessary? fli4l after all is “only” a router and a router should not really offer server
services.
The error message “: not found” usually means the script is still in DOS format. Another
source of errors: the script is not executable. In both cases the opt/<PACKAGE>.txt file
should be checked whether it contains the correct options for “mode”, “gid”, “uid” and
Flags. If the script is created during boot, execute “chmod +x <script name>”.
Use the path /tmp for temporary files. However, it is important to keep in mind that
there is little space there because it is situated in the rootfs-RAM disc! If more space is
needed, you have to create and mount your own ramdisk. Detailed informations on this
topic can be found in the section “RAM-Disks” of this documentation.
In order to create temporary files with unique names you should always append the
current process-ID stored in the shell variable “$” to the file name. /tmp/<OPT-Name>.$$
hence is a perfect file name, /tmp/<OPT-Name> rather not (<OPT-Name> of course has to
be replaced by the according OPT-Name).
320