summaryrefslogtreecommitdiff
path: root/user/dracut/dracut.easy-boot
diff options
context:
space:
mode:
Diffstat (limited to 'user/dracut/dracut.easy-boot')
-rw-r--r--user/dracut/dracut.easy-boot14
1 files changed, 14 insertions, 0 deletions
diff --git a/user/dracut/dracut.easy-boot b/user/dracut/dracut.easy-boot
new file mode 100644
index 000000000..53c95c54e
--- /dev/null
+++ b/user/dracut/dracut.easy-boot
@@ -0,0 +1,14 @@
+#!/bin/sh -e
+
+for i in /boot/vmlinu[xz]*; do
+ version="${i##*/vmlinu[xz]}"
+ # Support filenames with no version. LILO supports this, but GRUB
+ # doesn't (currently).
+ version="${version#-}"
+ if ! [ -d /lib/modules/"$version" ]; then
+ printf '>>> %s: no modules installed, skipping\n' "$version" >&2
+ continue
+ fi
+ printf '>>> %s\n' "$version" >&2
+ dracut --force --quiet /boot/initramfs-"$version".img "$version"
+done