NetBSD/share/sushi/system/sysctl/script

14 lines
295 B
Plaintext
Raw Normal View History

#!/bin/sh
# $NetBSD: script,v 1.1 2001/04/26 02:44:47 garbled Exp $
if [ "$3" = "now" -o "$3" = "both" ]; then
sysctl -w $1=$2
fi
if [ "$3" = "boot" -o "$3" = "both" ]; then
IFS=" "
CONF=`cat /etc/sysctl.conf`
echo $CONF | grep -v $1 > /etc/sysctl.conf
echo "$1=$2" >>/etc/sysctl.conf
fi