version 1.103.2.1, 2003/03/14 21:25:44
|
version 1.104, 2002/12/18 20:43:29
|
Line 272 sub checkchildren {
|
Line 272 sub checkchildren {
|
} |
} |
} |
} |
sleep 5; |
sleep 5; |
$SIG{ALRM} = sub { die "timeout" }; |
|
$SIG{__DIE__} = 'DEFAULT'; |
|
foreach (sort keys %children) { |
foreach (sort keys %children) { |
unless (-e "$docdir/lon-status/londchld/$_.txt") { |
unless (-e "$docdir/lon-status/londchld/$_.txt") { |
eval { |
|
alarm(300); |
|
&logthis('Child '.$_.' did not respond'); |
&logthis('Child '.$_.' did not respond'); |
kill 9 => $_; |
kill 9 => $_; |
$emailto="$perlvar{'lonAdmEMail'},$perlvar{'lonSysEMail'}"; |
$emailto="$perlvar{'lonAdmEMail'},$perlvar{'lonSysEMail'}"; |
$subj="LON: $perlvar{'lonHostID'} killed lond process $_"; |
$subj="LON: $perlvar{'lonHostID'} killed lond process $_"; |
my $result=`echo 'Killed lond process $_.' | mailto $emailto -s '$subj' > /dev/null`; |
my $result=`echo 'Killed lond process $_.' | mailto $emailto -s '$subj' > /dev/null`; |
$execdir=$perlvar{'lonDaemons'}; |
$execdir=$perlvar{'lonDaemons'}; |
$result=`/bin/cp $execdir/logs/lond.log $execdir/logs/lond.log.$_`; |
$result=`/bin/cp $execdir/logs/lond.log $execdir/logs/lond.log.$_` |
alarm(0); |
|
} |
|
} |
} |
} |
} |
$SIG{ALRM} = 'DEFAULT'; |
|
$SIG{__DIE__} = \&cathcexception; |
|
} |
} |
|
|
# --------------------------------------------------------------------- Logging |
# --------------------------------------------------------------------- Logging |
Line 729 sub make_new_child {
|
Line 721 sub make_new_child {
|
} |
} |
} |
} |
} elsif ($howpwd eq 'krb4') { |
} elsif ($howpwd eq 'krb4') { |
$null=pack("C",0); |
$null=pack("C",0); |
unless ($upass=~/$null/) { |
unless ($upass=~/$null/) { |
$pwdcorrect=( |
my $krb4_error = &Authen::Krb4::get_pw_in_tkt |
Authen::Krb4::get_pw_in_tkt($uname,"", |
($uname,"",$contentpwd,'krbtgt', |
$contentpwd,'krbtgt',$contentpwd,1, |
$contentpwd,1,$upass); |
$upass) == 0); |
if (!$krb4_error) { |
} else { $pwdcorrect=0; } |
$pwdcorrect = 1; |
|
} else { |
|
$pwdcorrect=0; |
|
# log error if it is not a bad password |
|
if ($krb4_error != 62) { |
|
&logthis('krb4:'.$uname.','.$contentpwd.','. |
|
&Authen::Krb4::get_err_txt($Authen::Krb4::error)); |
|
} |
|
} |
|
} |
} elsif ($howpwd eq 'krb5') { |
} elsif ($howpwd eq 'krb5') { |
$null=pack("C",0); |
$null=pack("C",0); |
unless ($upass=~/$null/) { |
unless ($upass=~/$null/) { |