Hi Stable-RMs,
This is an e-mail to ask if the patch below would be acceptable for a
point release. If so I believe I have to upload to
stable-proposed-updates, right?
This is about bug 427104, a summary of the bug:
D-I in etch uses devfs-style naming for devices. This means that
discovering the swap-device and writing it to a file will result in
having the wrong file name. Luckily the installer writes a file with a
`correct' device filename.
This was discovered quite close to the release. I thought I fixed the
issue with an upload during the freeze. That fix just uses the device
file name from the file the installer wrote and disables a check for
the existence of the swap-file for one pass.
Unfortunately the tests I performed (installing the fixed package with
dpkg -i) didn't capture the normal use case. If the install goes
through apt the package will be pre-configured, which means that the
package gets configured twice. The second run the normal check is on
again, which results in a confusing message to the user.
In other words: everybody who installs the laptop task gets a useless
and confusing question. In joeys words:
> ... the laptop task is broken, and something has to be done about this.
> It's sort of on the edge between a cosmetic problem and a serious bug,
> so the best way to make sure it's accepted will be to have a good and
> clear patch.
The patch below will set a flag on a debconf question to signal we disabled
the check in d-i and we should not ask the question. In posinst the flag is
cleared so that in the further life of the package the test will be done.
Index: uswsusp.config
===================================================================
--- uswsusp.config (revision 490)
+++ uswsusp.config (working copy)
@@ -85,8 +85,11 @@
# found to the list of valid swaps without checking. This is because
# what is in /proc/swaps uses devfs style naming...
if [ -n "$USERSWAP" ] && ! echo "$SWAPLIST" | grep -q -e '\(^\|, \)'$USERSWAP'\(,\|$\)'; then
- SWAPLIST=${SWAPLIST}${KOMMA}${USERSWAP}
- SWAPDEFAULT=${USERSWAP}
+ # We do that by making sure we skip the continue_without_swap question.
+ # We'll clear this in postinst.
+ db_set uswsusp/continue_without_swap true
+ db_fset uswsusp/continue_without_swap seen true
+ db_fset uswsusp/continue_without_swap d_i true
fi
fi
@@ -98,6 +101,8 @@
SWAPLIST=${SWAPLIST}${KOMMA}${USERSWAP} ;
SWAPDEFAULT=${USERSWAP}
fi
+elif [ -n "$USERSWAP" ]; then
+ SWAPDEFAULT=${USERSWAP}
fi
# We had to move this untill after the config file parsing, because
Index: uswsusp.postinst
===================================================================
--- uswsusp.postinst (revision 490)
+++ uswsusp.postinst (working copy)
@@ -24,6 +24,15 @@
[ "$RET" = "false" ] || exit 0;
db_fget uswsusp/no_snapshot seen
[ "$RET" = "false" ] || exit 0;
+
+ # If we've set this under d-i to skip the sanity checks, reset it
+ db_fget uswsusp/continue_without_swap d_i
+ if [ "$RET" = "true" ]; then
+ db_fset uswsusp/continue_without_swap seen false
+ db_fset uswsusp/continue_without_swap d_i false
+ db_reset uswsusp/continue_without_swap
+ fi
+
# If we don't have /proc or /sys we can't work, this will probably
# be a chroot or so.
mountpoint -q /sys || exit 0;
Attachment:
signature.asc
Description: PGP signature