version 1.23, 2003/09/15 09:24:49
|
version 1.24, 2003/09/16 09:46:42
|
Line 45
|
Line 45
|
|
|
# Change log: |
# Change log: |
# $Log$ |
# $Log$ |
|
# Revision 1.24 2003/09/16 09:46:42 foxr |
|
# Added skeletal infrastructure to support SIGUSR2 update hosts request. |
|
# |
# Revision 1.23 2003/09/15 09:24:49 foxr |
# Revision 1.23 2003/09/15 09:24:49 foxr |
# Add use strict and fix all the fallout from that. |
# Add use strict and fix all the fallout from that. |
# |
# |
Line 1596 $SIG{INT} = \&Terminate;
|
Line 1599 $SIG{INT} = \&Terminate;
|
$SIG{TERM} = \&Terminate; |
$SIG{TERM} = \&Terminate; |
$SIG{HUP} = \&Restart; |
$SIG{HUP} = \&Restart; |
$SIG{USR1} = \&CheckKids; |
$SIG{USR1} = \&CheckKids; |
|
$SIG{USR2} = \&UpdateKids; # LonManage update request. |
|
|
while(1) { |
while(1) { |
my $deadchild = wait(); |
my $deadchild = wait(); |
Line 1639 sub CheckKids {
|
Line 1643 sub CheckKids {
|
|
|
=pod |
=pod |
|
|
|
=head1 UpdateKids |
|
|
|
parent's SIGUSR1 handler. This handler: |
|
|
|
=item |
|
|
|
Rereads the hosts file. |
|
|
|
=item |
|
|
|
Kills off (via sigint) children for hosts that have disappeared. |
|
|
|
=item |
|
|
|
HUP's children for hosts that already exist (this just forces a status display |
|
and resets the connection retry count for that host. |
|
|
|
=item |
|
|
|
Starts new children for hosts that have been added to the hosts.tab file since |
|
the start of the master program and maintains them. |
|
|
|
=cut |
|
|
|
sub UpdateKids { |
|
} |
|
|
|
|
|
=pod |
|
|
=head1 Restart |
=head1 Restart |
|
|
Signal handler for HUP... all children are killed and |
Signal handler for HUP... all children are killed and |