Browse Source

Fix a silent bug when mounting the iso in initramfs.

If /dev/sdX would be mounted instead of /dev/sdX1, it would render all
other partitions being EBUSY and not usable. By mounting /dev/sdX1
instead, we can create/edit partitions and make filesystems.
parazyd 1 year ago
parent
commit
1ce89f7c76
1 changed files with 1 additions and 1 deletions
  1. 1 1
      initramfs/skel/init

+ 1 - 1
initramfs/skel/init

@@ -22,7 +22,7 @@ sleep 3
22 22
 
23 23
 # First check if we have booted from a cd, otherwise it's probably
24 24
 # a usb drive
25
-for i in /dev/sr* /dev/sd* ; do
25
+for i in /dev/sr* /dev/sd?? ; do
26 26
 	mount -t iso9660 "$i" /mnt/root || continue
27 27
 	[ -f /mnt/root/live/filesystem.squashfs ] && {
28 28
 		echo " * found squashfs on $i"