X-Git-Url: http://dxcluster.net/gitweb/gitweb.cgi?a=blobdiff_plain;f=perl%2Fcluster.pl;h=d82dd2e73bbd8d67aa68538a39dd19e49f6ae00e;hb=4f1c00b0c181d994b13bb9b0ff9ea03ee0cf120c;hp=86785a9777c45c8ae0a4284ec1a0b86c9b84d3da;hpb=d1daa87473f824fcae5751e2576c31265bf53544;p=spider.git diff --git a/perl/cluster.pl b/perl/cluster.pl index 86785a97..d82dd2e7 100755 --- a/perl/cluster.pl +++ b/perl/cluster.pl @@ -43,7 +43,10 @@ BEGIN { my $pid = ; if ($pid) { chomp $pid; - die "Lockfile ($lockfn) and process $pid exist, another cluster running?" if kill 0, $pid; + if (kill 0, $pid) { + warn "Lockfile ($lockfn) and process $pid exist, another cluster running?\n"; + exit 1; + } } unlink $lockfn; close CLLOCK; @@ -56,6 +59,7 @@ BEGIN { $systime = time; } + use Mojo::IOLoop; use DXVars;