projects
/
live-initramfs-grml.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5503759
)
Add 10validateroot to validate root device before accessing it.
author
Michael Prokop
<mika@grml.org>
Sat, 20 Feb 2010 15:00:27 +0000
(16:00 +0100)
committer
Michael Prokop
<mika@grml.org>
Sat, 20 Feb 2010 16:19:20 +0000
(17:19 +0100)
grml/10validateroot
[new file with mode: 0755]
patch
|
blob
diff --git a/grml/10validateroot
b/grml/10validateroot
new file mode 100755
(executable)
index 0000000..
8d42afc
--- /dev/null
+++ b/
grml/10validateroot
@@ -0,0
+1,27
@@
+#!/bin/sh
+
+#set -e
+
+# initramfs-tools header
+
+PREREQ=""
+
+prereqs()
+{
+ echo "${PREREQ}"
+}
+
+case "${1}" in
+ prereqs)
+ prereqs
+ exit 0
+ ;;
+esac
+
+. /scripts/live-functions
+. /scripts/live-helpers
+
+if ! [ -x "/root/sbin/init" ] ; then
+ panic "rootfs can not be mounted as supposed because of fatal error during bootup."
+fi
+