瀏覽代碼

Differentiated between "lost" and readonly boot media

Boot media can become "lost" when it is not recognized as USB 2.0
during early boot (due to missing modules), and is recognized as
such later, in which case, e.g., /dev/sdb disappears and is replaced
with /dev/sdc, while /mnt/boot is still reported as a mountpoint
with a non-existing /dev/block/major:minor device.

This is useful for bug reporting.
Maxim Kammerer 12 年之前
父節點
當前提交
0325a254d3
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/etc/init.d/liberte

+ 2 - 0
src/etc/init.d/liberte

@@ -72,6 +72,8 @@ start() {
             mount -o remount,rw ${boot} && /usr/bin/test -w ${boot}
             mediaro=$?
             eend ${mediaro}
+        elif [ ! -e ${mediadev} ]; then
+            ewarn Boot media device lost, not remounting
         else
             ewarn Boot media is read-only, not remounting
         fi