Previous Next Table of Contents

8. Nodelist-compiler

All nodelists in the config-file should be in the directory /var/spool/fnet/nodelist. Then one calls ifindex, which then creates index.dir and index.pag, which contain the compiled nodelist.

As a matter of fact ifindex is not very quick, thus I shorten the nodelist to what I need (in germany) before the compilation. I use the following script for that:


#!/bin/sh
#
# /var/spool/fnet/nodelist/strip.nodelist 
#
if [ ! $1 ]
then
    echo Syntax Error!
    echo Start with $0 xxx, whereas xxx is the number of the latest
    echo nodelist.
    exit
fi

NODELIST=nodelist.$1

if [ ! -s $NODELIST ]
then
    echo $NODELIST is not a correct nodelist
    exit
fi

NLSHORT=nl_short.$1

if [ -s $NLSHORT ]
then
    echo $NLSHORT already exists, moving to $NLSHORT.bak 
    mv -f $NLSHORT $NLSHORT.bak
fi

head -n 2 $NODELIST >> $NLSHORT
grep ',49-\|^Zone,' $NODELIST >> $NLSHORT

echo Done.

You have to start this script with strip.nodelist xxx, where xxx stands for the number of the latest nodelist. The script generates nl_short.xxx from nodelist.xxx.

And what about the diffs? Since ifmail-2.6 there is a the program nlpatch included with the package, which you call with the old nodelist and apply the latest diff, e.g.:

        nlpatch nodelist.123 NODEDIFF.130
By doing this the nodelist of day 130 is created.


Previous Next Table of Contents