Changeset 26


Ignore:
Timestamp:
Feb 4, 2008, 3:55:00 PM (17 years ago)
Author:
g7moreau
Message:
  • Begin to test the running environnement to see if it's OK
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/klask

    r25 r26  
    1515# arping fping bind9-host arpwatch
    1616
    17 my $KLASK_DB_FILE  = '/var/cache/klask/klaskdb';
    18 my $KLASK_SW_FILE  = '/var/cache/klask/switchdb';
     17my $KLASK_VAR      = '/var/cache/klask';
    1918my $KLASK_CFG_FILE = '/etc/klask.conf';
     19my $KLASK_DB_FILE  = '$KLASK_VAR/klaskdb';
     20my $KLASK_SW_FILE  = '$KLASK_VAR/switchdb';
     21
     22test_running_environnement();
    2023
    2124my $KLASK_CFG = YAML::LoadFile("$KLASK_CFG_FILE");
     
    99102exit;
    100103
     104sub test_running_environnement {
     105   die "Configuration file $KLASK_CFG_FILE does not exists. Klask need it !\n" if not -e "$KLASK_CFG_FILE";
     106   die "Var folder $KLASK_VAR does not exists. Klask need it !\n"              if not -d "$KLASK_VAR";
     107   }
     108
    101109###
    102110# fast ping dont l'objectif est de remplir la table arp de la machine
Note: See TracChangeset for help on using the changeset viewer.