]>
Commit | Line | Data |
---|---|---|
82705b6e MT |
1 | --- grub-0.95/docs/grub.texi.recheck-bad 2005-07-25 17:55:57.000000000 -0400 |
2 | +++ grub-0.95/docs/grub.texi 2005-07-25 17:58:00.000000000 -0400 | |
3 | @@ -3417,8 +3417,9 @@ | |
4 | ||
5 | @item --recheck | |
6 | Recheck the device map, even if @file{/boot/grub/device.map} already | |
7 | -exists. You should use this option whenever you add/remove a disk | |
8 | -into/from your computer. | |
9 | +exists. | |
10 | + | |
11 | +This option is unreliable and its use is strongly discouraged. | |
12 | @end table | |
13 | ||
14 | ||
15 | --- grub-0.95/util/grub-install.in.recheck-bad 2005-07-25 17:58:19.000000000 -0400 | |
16 | +++ grub-0.95/util/grub-install.in 2005-07-25 18:05:14.000000000 -0400 | |
17 | @@ -68,6 +68,8 @@ | |
18 | --force-lba force GRUB to use LBA mode even for a buggy | |
19 | BIOS | |
20 | --recheck probe a device map even if it already exists | |
21 | + This flag is unreliable and its use is | |
22 | + strongly discouraged. | |
23 | ||
24 | INSTALL_DEVICE can be a GRUB device name or a system device filename. | |
25 | ||
26 | @@ -328,7 +330,7 @@ | |
27 | ||
28 | # If --recheck is specified, remove the device map, if present. | |
29 | if test $recheck = yes; then | |
30 | - rm -f $device_map | |
31 | + mv $device_map ${device_map}.backup | |
32 | fi | |
33 | ||
34 | # Create the device map file if it is not present. | |
35 | @@ -357,7 +359,22 @@ | |
36 | tmp=`sed -n '/^([fh]d[0-9]*)/s/\(^(.*)\).*/\1/p' $device_map \ | |
37 | | sort | uniq -d | sed -n 1p` | |
38 | if test -n "$tmp"; then | |
39 | - echo "The drive $tmp is defined multiple times in the device map $device_map" 1>&2 | |
40 | + echo "The drive $tmp is defined multiple times in the new device map." 1>&2 | |
41 | + if test $recheck = yes; then | |
42 | + echo "Reverting to backed up copy." 1>&2 | |
43 | + mv ${device_map}.backup $device_map | |
44 | + fi | |
45 | + exit 1 | |
46 | +fi | |
47 | + | |
48 | +# Make sure device.map has at least one hd device | |
49 | +grep -q "^(hd[0-9]\+)" $device_map | |
50 | +if [ "x$?" != "x0" ]; then | |
51 | + echo "No suitable drive was found in the generated device map." 1>&2 | |
52 | + if test $recheck = yes; then | |
53 | + echo "Reverting to backed up copy." 1>&2 | |
54 | + mv ${device_map}.backup $device_map | |
55 | + fi | |
56 | exit 1 | |
57 | fi | |
58 | ||
59 | --- grub-0.95/docs/grub-install.8.recheck-bad 2004-06-13 13:44:59.000000000 -0400 | |
60 | +++ grub-0.95/docs/grub-install.8 2005-07-25 18:15:02.000000000 -0400 | |
61 | @@ -30,6 +30,8 @@ | |
62 | .TP | |
63 | \fB\-\-recheck\fR | |
64 | probe a device map even if it already exists | |
65 | + | |
66 | +This option is unreliable and its use is strongly discouraged. | |
67 | .PP | |
68 | INSTALL_DEVICE can be a GRUB device name or a system device filename. | |
69 | .SH "REPORTING BUGS" | |
70 | --- grub-0.95/docs/grub.info.recheck-bad 2004-05-11 08:22:54.000000000 -0400 | |
71 | +++ grub-0.95/docs/grub.info 2005-07-25 18:16:09.000000000 -0400 | |
72 | @@ -3373,9 +3373,9 @@ | |
73 | ||
74 | `--recheck' | |
75 | Recheck the device map, even if `/boot/grub/device.map' already | |
76 | - exists. You should use this option whenever you add/remove a disk | |
77 | - into/from your computer. | |
78 | + exists. | |
79 | ||
80 | + This option is unreliable and its use is strongly discouraged. | |
81 | \1f | |
82 | File: grub.info, Node: Invoking grub-md5-crypt, Next: Invoking grub-terminfo, Prev: Invoking grub-install, Up: Top | |
83 |