dfhack/package/ubuntu-10.10/postinst

14 lines
458 B
Plaintext

#!/bin/sh
2011-03-19 17:54:11 -06:00
echo "Setting required kernel parameters."
# I actually do it three times, hoping to hammer this into Ubuntu's dense skull.
sysctl -w kernel.randomize_va_space=0
2011-03-19 17:54:11 -06:00
sysctl -w kernel.yama.ptrace_scope=0
2011-03-27 08:06:44 -06:00
if grep -q "kernel.yama.ptrace_scope=0" /etc/sysctl.conf
then
echo "Already installed into /etc/sysctl.conf, doing nothing."
else
echo "kernel.randomize_va_space=0" >> /etc/sysctl.conf
echo "kernel.yama.ptrace_scope=0" >> /etc/sysctl.conf
fi