diff options
-rwxr-xr-x | rc.d/rc.sysinit | 8 | ||||
-rw-r--r-- | sysconfig.txt | 3 | ||||
-rw-r--r-- | sysconfig/init | 4 |
3 files changed, 12 insertions, 3 deletions
diff --git a/rc.d/rc.sysinit b/rc.d/rc.sysinit index 55231a04..805e7629 100755 --- a/rc.d/rc.sysinit +++ b/rc.d/rc.sysinit @@ -45,8 +45,14 @@ fi action "Mounting proc filesystem" mount -n -t proc /proc /proc # Turn off sysrq -if [ "$MAGIC_SYSRQ" = "no" ]; then +if [ -f /proc/sys/kernel/sysrq -a "$MAGIC_SYSRQ" = "no" ]; then echo "0" > /proc/sys/kernel/sysrq + action "Turning off Magic SysRq key" /bin/true +fi +# Turn off Stop-A +if [ -f /proc/sys/kernel/stop-a -a "$MAGIC_SYSRQ" = "no" ]; then + echo "0" > /proc/sys/kernel/stop-a + action "Turning off Stop-A" /bin/true fi # Set the system clock. diff --git a/sysconfig.txt b/sysconfig.txt index 09089463..3fed0b1d 100644 --- a/sysconfig.txt +++ b/sysconfig.txt @@ -52,7 +52,8 @@ Files in /etc/sysconfig A command to set the color to 'normal'. Defaults to nasty ANSI sequences output by echo -e. MAGIC_SYSRQ=yes|no - Set to 'no' to disable the magic sysrq key. + Set to 'no' to disable the magic sysrq key, and Stop-A (break + on serial console.) on SPARC. PROMPT=yes|no Set to 'no' to disable the key check for interactive mode. diff --git a/sysconfig/init b/sysconfig/init index ef12b932..5fefe7fa 100644 --- a/sysconfig/init +++ b/sysconfig/init @@ -17,7 +17,9 @@ SETCOLOR_WARNING="echo -en \\033[1;33m" SETCOLOR_NORMAL="echo -en \\033[0;39m" # default kernel loglevel on boot (syslog will reset this) LOGLEVEL=1 -# Set to something other than 'no' to turn on magic sysrq keys... +# Setting this to something other than 'no' will turn on: +# - magic sysrq keys +# - stop-a (Sparc only) MAGIC_SYSRQ=no # Set to anything other than 'no' to allow hotkey interactive startup... PROMPT=yes |