Had these changes regarding memory cutoffs for a while. Committing them so I can be running a clean codebase, but people shouldn't use this. Queue is way better.
git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@4740 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
parent
ecd496cf51
commit
c40c9aa5ef
|
|
@ -39,7 +39,7 @@ sub new {
|
||||||
'hosts' => "",
|
'hosts' => "",
|
||||||
|
|
||||||
'queue' => undef,
|
'queue' => undef,
|
||||||
'memLimit' => 2202009,
|
'memLimit' => 2,
|
||||||
'outputFile' => 'distributedmake.log',
|
'outputFile' => 'distributedmake.log',
|
||||||
'mailTo' => 'crd-lsf@broad.mit.edu',
|
'mailTo' => 'crd-lsf@broad.mit.edu',
|
||||||
'wait' => 1,
|
'wait' => 1,
|
||||||
|
|
@ -104,14 +104,18 @@ sub addRule {
|
||||||
push(@prepcmds, $mklogdircmd);
|
push(@prepcmds, $mklogdircmd);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
my $memRequest = $bja{'memLimit'} * 1.5;
|
||||||
|
my $integerMemRequest = int($memRequest);
|
||||||
|
my $memCutoff = $bja{'memLimit'} * 1024 * 1024 * 1.25;
|
||||||
|
|
||||||
# A quick check to make sure that java commands being dispatched to the farm are instructed to run under a default memory limit
|
# A quick check to make sure that java commands being dispatched to the farm are instructed to run under a default memory limit
|
||||||
for (my $i = 0; $i <= $#cmds; $i++) {
|
for (my $i = 0; $i <= $#cmds; $i++) {
|
||||||
if ($cmds[$i] =~ /^java / && $cmds[$i] =~ / -jar / && $cmds[$i] !~ / -Xmx/) {
|
if ($cmds[$i] =~ /^java / && $cmds[$i] =~ / -jar / && $cmds[$i] !~ / -Xmx/) {
|
||||||
$cmds[$i] =~ s/^java /java -Xmx2048m /;
|
$cmds[$i] =~ s/^java /java -Xmx$bja{'memLimit'}g /;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$cmdprefix = "bsub -q $bja{'queue'} -M $bja{'memLimit'} -P $bja{'projectName'} -o $bja{'outputFile'} -u $bja{'mailTo'} $wait $rerunnable $migrationThreshold $bja{'extra'} ";
|
$cmdprefix = "bsub -q $bja{'queue'} -M $memCutoff -P $bja{'projectName'} -o $bja{'outputFile'} -u $bja{'mailTo'} -R \"rusage[mem=$integerMemRequest]\" $wait $rerunnable $migrationThreshold $bja{'extra'} ";
|
||||||
}
|
}
|
||||||
|
|
||||||
my $rootdir = dirname($targets[0]);
|
my $rootdir = dirname($targets[0]);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue