LJ Archive

Listing 4. The config.pl Script, Called from postinstall

#!/usr/bin/perl
# config.pl : This script parses a file called
 in initialservices
# to switch on/off various services at startup.
 Syntax for this file is:
# service {on|off} e.g.
# netfs on
# named off

open (SERVLIST, "intialservices");
while(<SERVLIST>) {
   chop($_);
$command = "/sbin/chkconfig ".$_;
system($command);
}
LJ Archive