Blame contrib/mrtg_php_portal/update.pl

Packit 667938
#!/bin/perl
Packit 667938
#
Packit 667938
#
Packit 667938
Packit 667938
my ($filelist,$file,$result);
Packit 667938
my @f_list;
Packit 667938
Packit 667938
# Change the path to the folder where you store the mrtg .cfg files
Packit 667938
$deleted=`del /F /Q c:\\mrtg\\conf\\*_l`;  # this is to remove the _l files before running Mrtg
Packit 667938
$filelist=`dir /B c:\\mrtg\\conf\\*.cfg`; # Get the list of the cfg files
Packit 667938
@f_list=split(/\n/,$filelist);
Packit 667938
Packit 667938
foreach $file (@f_list){
Packit 667938
    if($file||($file ne "File not Found")||($file=~/\.cfg$/)){
Packit 667938
	$result=`perl.exe e:\\mrtg\\bin\\mrtg e:\\mrtg\\conf\\$file`; # Run Mrtg for each host with a cfg file.
Packit 667938
    }
Packit 667938
}