[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#565225: don't assume RESUME partition will never change



Package: initramfs-tools
Version: 0.93.4

How can one just _assume_ that nobody will ever adjust their disk
partitions ever?

In /var/lib/dpkg/info/initramfs-tools.preinst
you do
 # First time install.  Can we autodetect the RESUME partition?

So then forever and ever
/etc/initramfs-tools/conf.d/resume and thus
$ zcat /boot/initrd.img-2.6.*-trunk-686|cpio -i --to-stdout conf/conf.d/resume
contain this never changing resume partition from years ago when we
first bought the computer.

OK, now let's look at what happens when the user boots.
He will see
Loading... please wait
readlink: No such file or directory

Which of course also zip way off the screen, and don't end up in any
logs.

Now he will wonder "gee, those guys are missing the "readlink" command".
Bug#564812

And when one day he does actually try to resume... who knows what will
happen.

Anyway it makes much more sense to check where the swap space is located
upon each time /boot/initrd.img.* is made. -- And perhaps even more like
each boot or shutdown or ... suspend.

Or upon boot warn the user that it was detected that his swap partition
is not where it used to be, and he should now "remove and reinstall
initramfs-tools"! (as apparently there is no script command to fix it
short of editing the file by hand.) ... (And don't just let the message
fly off the screen beyond where Shift PgUp can reach, and not kept in
any log file.)

Also man initramfs-tools:
 resume
   On install initramfs-tools tries to autodetect the resume parti-
   tion. On success the RESUME variable is written to
   /etc/initramfs-tools/conf.d/resume. The boot variable noresume
   overrides it.
Here again it is like the author _just assumes_ that the RESUME part of
the computer is the only part of the computer that never could change.



Reply to: