version 1.97, 2013/02/02 14:42:01
|
version 1.98, 2013/02/08 14:49:51
|
Line 271 sub log_machine_info {
|
Line 271 sub log_machine_info {
|
|
|
&log($fh,"<h3>distprobe</h3>"); |
&log($fh,"<h3>distprobe</h3>"); |
&log($fh,"<pre>"); |
&log($fh,"<pre>"); |
&get_distro($perlvar{'lonDaemons'},$fh); |
&log($fh,&encode_entities(&LONCAPA::distro(),'<>&"')); |
&log($fh,"</pre>"); |
&log($fh,"</pre>"); |
|
|
&errout($fh); |
&errout($fh); |
Line 752 sub write_serverhomeIDs {
|
Line 752 sub write_serverhomeIDs {
|
} |
} |
|
|
sub write_checksums { |
sub write_checksums { |
my $distro = &get_distro($perlvar{'lonDaemons'}); |
my $distro = &LONCAPA::distro(); |
if ($distro) { |
if ($distro) { |
print "Retrieving file version and checksumming.\n"; |
print "Retrieving file version and checksumming.\n"; |
my $numchksums = 0; |
my $numchksums = 0; |
Line 788 sub send_mail {
|
Line 788 sub send_mail {
|
} |
} |
} |
} |
|
|
sub get_distro { |
|
my ($dir,$fh) = @_; |
|
my $distro; |
|
if (open(my $disth,"$dir/distprobe |")) { |
|
while (my $line=<$disth>) { |
|
if ($fh) { |
|
&log($fh,&encode_entities($line,'<>&"')); |
|
} |
|
$distro .= $line; |
|
} |
|
close($disth); |
|
} |
|
return $distro; |
|
} |
|
|
|
sub usage { |
sub usage { |
print(<<USAGE); |
print(<<USAGE); |
loncron - housekeeping program that checks up on various parts of Lon-CAPA |
loncron - housekeeping program that checks up on various parts of Lon-CAPA |