3 # Copyright (C) SUSE LINUX GmbH 2016, all rights reserved.
5 # This library is free software; you can redistribute it and/or modify it
6 # under the terms of the GNU Lesser General Public License as published
7 # by the Free Software Foundation; either version 2.1 of the License, or
8 # (at your option) version 3.
10 # This library is distributed in the hope that it will be useful, but
11 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
13 # License for more details.
15 if [ ! -f /vm_autorun.env ]; then
16 echo "Error: autorun scripts must be run from within an initramfs VM"
25 cat /proc/mounts | grep debugfs &> /dev/null
27 mount -t debugfs debugfs /sys/kernel/debug/
30 cat /proc/mounts | grep configfs &> /dev/null
32 mount -t configfs configfs /sys/kernel/config/
35 for i in $DYN_DEBUG_MODULES; do
36 echo "module $i +pf" > /sys/kernel/debug/dynamic_debug/control || _fatal
38 for i in $DYN_DEBUG_FILES; do
39 echo "file $i +pf" > /sys/kernel/debug/dynamic_debug/control || _fatal
44 sed -i "s#keyring = .*#keyring = /etc/ceph/keyring#g; \
45 s#admin socket = .*##g; \
46 s#run dir = .*#run dir = /var/run/#g; \
47 s#log file = .*#log file = /var/log/\$name.\$pid.log#g" \