fs

morpheus filesystem files
git clone git://git.2f30.org/fs
Log | Files | Refs

commit 9dacf0a1e60b9af73f0a4ecb8627d27b840cb538
parent 455d5fe479dd328f50d9133a76c94eb8dd48a91b
Author: sin <sin@2f30.org>
Date:   Sun, 16 Mar 2014 16:08:01 +0000

Respect dmesg_restrict

Diffstat:
Mbin/rc.init | 9++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/bin/rc.init b/bin/rc.init @@ -80,7 +80,14 @@ echo Setting random seed [ -f /etc/random-seed ] && cat /etc/random-seed >/dev/urandom dd if=/dev/urandom of=/etc/random-seed count=1 bs=512 2>/dev/null -dmesg > /var/log/dmesg.log +echo Storing dmesg output to /var/log/dmesg.log +env dmesg > /var/log/dmesg.log +if [ -e /proc/sys/kernel/dmesg_restrict ] && [ $(cat /proc/sys/kernel/dmesg_restrict) = "1" ]; +then + chmod 0600 /var/log/dmesg.log +else + chmod 0644 /var/log/dmesg.log +fi if [ -x /bin/rc.svc ]; then echo Running rc.svc