summaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
authorThomas Bächler <thomas@archlinux.org>2010-02-14 17:30:48 +0100
committerThomas Bächler <thomas@archlinux.org>2010-02-14 17:30:48 +0100
commitcb73c11c846d1376c0f4754e4367b28a2b2a36ad (patch)
tree08e86e78d592a1198e3f85a9cdbb06ec0cf16cf4 /init
parent3dd8022171c41dbbd32f6828ebe0ac96c57a06e2 (diff)
downloadmkinitcpio-cb73c11c846d1376c0f4754e4367b28a2b2a36ad.tar.gz
mkinitcpio-cb73c11c846d1376c0f4754e4367b28a2b2a36ad.tar.xz
If filesystem type detection fails, print an error and instructions
Diffstat (limited to 'init')
-rw-r--r--init13
1 files changed, 13 insertions, 0 deletions
diff --git a/init b/init
index 7d4b226..9dfb43f 100644
--- a/init
+++ b/init
@@ -158,6 +158,19 @@ if [ -z "${nfsroot}" -a "${root}" != "/dev/nfs" ]; then
fstype="${rootfstype}"
else
fstype=$(eval $(/sbin/blkid -o udev -p "${root}"); echo $ID_FS_TYPE)
+ if [ -z "${fstype}" ]; then
+ err "Unable to determine the file system type of ${root}:"
+ echo "Either it contains no filesystem, an unknown filesystem,"
+ echo "or more than one valid file system signature was found."
+ echo
+ echo "Try adding"
+ echo " rootfstype=your_filesystem_type"
+ echo "to the kernel command line."
+ echo "You are now being dropped into an emergency shell."
+ echo
+ launch_interactive_shell
+ msg "Trying to continue (this will most likely fail) ..."
+ fi
fi
if [ "${readwrite}" = "yes" ]; then
rwopt="rw"