version 1.29, 2007/04/03 00:47:28
|
version 1.30, 2007/05/31 05:20:06
|
Line 158 sub stop_daemon {
|
Line 158 sub stop_daemon {
|
print("\n"); |
print("\n"); |
} |
} |
|
|
|
sub clean_sockets { |
|
opendir(SOCKETS,"/home/httpd/sockets/"); |
|
while (my $fname=readdir(SOCKETS)) { |
|
next if (-d $fname |
|
|| $fname=~/(mysqlsock|maximasock|\Q$perlvar{'lonSockDir'}\E)/); |
|
unlink("/home/httpd/sockets/$fname"); |
|
} |
|
} |
|
|
if ($command eq "restart") { |
if ($command eq "restart") { |
print 'Restarting LON-CAPA'."\n"; |
print 'Restarting LON-CAPA'."\n"; |
Line 178 if ($command eq "restart") {
|
Line 186 if ($command eq "restart") {
|
&stop_daemon($daemon,$killallname); |
&stop_daemon($daemon,$killallname); |
} |
} |
&firewall_close_port(); |
&firewall_close_port(); |
|
&clean_sockets(); |
} elsif ($command eq "start") { |
} elsif ($command eq "start") { |
&firewall_open_port(); |
&firewall_open_port(); |
print 'Starting LON-CAPA'."\n"; |
print 'Starting LON-CAPA'."\n"; |