Don't suspend to disk if uncertain about resume
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
powermanagement-interface (Ubuntu) |
New
|
Medium
|
Unassigned |
Bug Description
gnome-power-manager should check if the computer is likely to resume from suspend to disk before suspending. If g-p-m is uncertain, a popup could be shown which tells the user how to fix it or how to override it.
There are cases when the computer is upgraded from an older release and no resume parameter is given in the boot config. This is likely to cause data loss.
The easiest way to check wether resume is likely to happen is to grep for resume= in lilo.conf and menu.lst and check that the resume parameter matches the current swap drive. If there is no lilo.conf or menu.lst or the swap name doesn't match, the user could override this by setting a setting in some config file. This is for cases where the user has a custom setup and knows that resuming works even though the configuration looks messed up.
This check should actually be done by acpi-support, but g-p-m does this by default and has an existing method of communicating with the user.
Ideally /usr/sbin/pmi should do these checks and not report hibernate capability to hal unless it is likely to work.