From: Marius Gavrilescu Date: Sun, 8 Mar 2015 17:38:38 +0000 (+0200) Subject: Set oom_score_adj to 900 in gruntmaster-exec X-Git-Tag: 5999.000_005~30 X-Git-Url: http://git.ieval.ro/?p=gruntmaster-daemon.git;a=commitdiff_plain;h=2ddfc5472cd27c537a9c37e3e6074c3f3997dc0d;hp=dbd5d64f321f42bf18d21b5274e88f7ffa1b44da;ds=sidebyside Set oom_score_adj to 900 in gruntmaster-exec --- diff --git a/gruntmaster-exec b/gruntmaster-exec index b1bcd61..5235e8e 100755 --- a/gruntmaster-exec +++ b/gruntmaster-exec @@ -88,6 +88,9 @@ if ($ret) { setrlimit RLIMIT_AS, $mlimit, $mlimit or die $! if $mlimit; setrlimit RLIMIT_FSIZE, $olimit, $olimit or die $! if $olimit; setrlimit RLIMIT_NPROC, $nproc, $nproc or die $! if $sudo; + open my $adj, '>', '/proc/self/oom_score_adj'; + print $adj 900; + close $adj; unshift @ARGV, @sudo; say STDERR "Executing: ", join ' ', map { "'$_'" } @ARGV if $debug; exec @ARGV;