Failing to resume from hibernation

I am not sure if this should be here or in another part of the forum; I apologise if not. Please let me know where it should be, if not here.

I have been having problems with resuming from hibernation lately. There are two symptons, one new, and the other old but now become more frequent.

System: Thinkpad T60, OpenSuse 11.4 with Gnome and KDE installed (fresh install only four days old), Mobility Radeon graphics.

New Symptom:

In Gnome, the computer goes into hibernation just fine. When resuming when the image is finished loading instead of returning to the desktop the screen goes blank, not even the backlight is on, and the caps lock light flashes. The computer is not responsive to anything except a forced shut down by holding down the power button.

Background: I have been using runing just Gnome for about a year, and hibernation worked fine (except for the old symptom described below). Recently I installed the KDE workspace, so I could also log into a KDE desktop, from the opensuse 11.4 repository. This was around when this started, but only once or twice. A few days ago I decided to do a fresh reinstalation 11.4, with gnome as the main desktop but also with KDE. This now happens about once every two or three times I try to resume from hibernation.

Old Symptom:

This used to happen in Gnome about once a month, now it happens about every second or third time I try to resume from hibernation. Computer hibernates fine, when resuming the image finishes loading but instead of returning to the desktop the screen displays:

resuming…

or

resuming…
resuming…

and the mouse cursor. I cannot see anything if I click or right click the mouse, but if it happens to be over an icon (or where I would see one) it does whatever should happen. Basically everything is there, except that I cannot see it. Logging out reactivates the screen, and then when I log back things are as they should be. If I open a terminal (with a shortcut) and try to open an application I get a message that the display cannot be found.

Here is the pm-suspend log the last time the new symptom occured:


Initial commandline parameters: 
Mon Oct 10 14:05:54 EDT 2011: Running hooks for hibernate.
Running hook /usr/lib/pm-utils/sleep.d/00logging hibernate hibernate:
hibernate initiated: Mon Oct 10 14:05:54 EDT 2011

Linux linux-djjb.site 2.6.37.6-0.7-desktop #1 SMP PREEMPT 2011-07-21 02:17:24 +0200 i686 i686 i386 GNU/Linux
kernel command line: 'root=/dev/disk/by-id/ata-HTS721010G9SA00_MPCZN7Y0HZWMLL-part2 resume=/dev/disk/by-id/ata-HTS721010G9SA00_MPCZN7Y0HZWMLL-part1 splash=silent quiet vga=0x345'
Module                  Size  Used by
ip6t_LOG                7940  5 
xt_tcpudp               3052  2 
xt_pkttype               960  3 
ipt_LOG                 7845  5 
xt_limit                1753  10 
fuse                   72011  3 
af_packet              20330  0 
rfcomm                 65655  4 
sco                    16183  2 
bnep                   14394  2 
l2cap                  64125  16 rfcomm,bnep
edd                     8752  0 
ip6t_REJECT             4192  3 
nf_conntrack_ipv6       8286  3 
nf_defrag_ipv6          9434  1 nf_conntrack_ipv6
ip6table_raw            1203  1 
xt_NOTRACK               864  4 
ipt_REJECT              2200  3 
iptable_raw             1294  1 
iptable_filter          1466  1 
ip6table_mangle         1636  0 
nf_conntrack_netbios_ns     1366  0 
nf_conntrack_ipv4       8584  3 
nf_defrag_ipv4          1281  1 nf_conntrack_ipv4
ip_tables              13128  2 iptable_raw,iptable_filter
xt_conntrack            2480  6 
nf_conntrack           75967  5 nf_conntrack_ipv6,xt_NOTRACK,nf_conntrack_netbios_ns,nf_conntrack_ipv4,xt_conntrack
ip6table_filter         1375  1 
ip6_tables             13404  4 ip6t_LOG,ip6table_raw,ip6table_mangle,ip6table_filter
x_tables               18727  16 ip6t_LOG,xt_tcpudp,xt_pkttype,ipt_LOG,xt_limit,ip6t_REJECT,ip6table_raw,xt_NOTRACK,ipt_REJECT,iptable_raw,iptable_filter,ip6table_mangle,ip_tables,xt_conntrack,ip6table_filter,ip6_tables
cpufreq_conservative    10080  0 
cpufreq_userspace       2631  0 
cpufreq_powersave        930  0 
snd_pcm_oss            48271  0 
snd_mixer_oss          17521  1 snd_pcm_oss
snd_seq                57777  0 
snd_seq_device          6678  1 snd_seq
acpi_cpufreq            7519  1 
mperf                   1271  1 acpi_cpufreq
dm_mod                 76266  0 
sr_mod                 15048  0 
cdrom                  38437  1 sr_mod
snd_hda_codec_analog    69796  1 
arc4                    1329  2 
ecb                     2015  2 
pcmcia                 54463  0 
iwl3945               142237  0 
thinkpad_acpi          70000  0 
snd_hda_intel          25622  2 
iTCO_wdt               10294  0 
iwlcore               152599  1 iwl3945
mac80211              266082  2 iwl3945,iwlcore
btusb                  15523  2 
nsc_ircc               15858  0 
sg                     28446  0 
iTCO_vendor_support     2554  1 iTCO_wdt
snd_hda_codec          95891  2 snd_hda_codec_analog,snd_hda_intel
yenta_socket           35551  0 
pcmcia_rsrc            11215  1 yenta_socket
i2c_i801                9512  0 
snd_hwdep               6198  1 snd_hda_codec
irda                  118657  1 nsc_ircc
bluetooth              94419  9 rfcomm,sco,bnep,l2cap,btusb
pcmcia_core            17581  3 pcmcia,yenta_socket,pcmcia_rsrc
joydev                  9578  0 
snd_pcm                88841  3 snd_pcm_oss,snd_hda_intel,snd_hda_codec
snd_timer              22055  2 snd_seq,snd_pcm
snd_page_alloc          8121  2 snd_hda_intel,snd_pcm
pcspkr                  1662  0 
e1000e                183393  0 
button                  5497  0 
tpm_tis                 9738  0 
tpm                    15389  1 tpm_tis
crc_ccitt               1419  1 irda
cfg80211              155017  3 iwl3945,iwlcore,mac80211
snd                    67246  15 snd_pcm_oss,snd_mixer_oss,snd_seq,snd_seq_device,snd_hda_codec_analog,thinkpad_acpi,snd_hda_intel,snd_hda_codec,snd_hwdep,snd_pcm,snd_timer
rfkill                 17926  4 thinkpad_acpi,bluetooth,cfg80211
soundcore               7270  1 snd
video                  14434  0 
battery                10066  0 
ac                      3227  0 
tpm_bios                6052  1 tpm
ext4                  373665  2 
jbd2                   78939  1 ext4
crc16                   1419  2 l2cap,ext4
radeon                942673  2 
ttm                    64252  1 radeon
drm_kms_helper         32687  1 radeon
drm                   191946  4 radeon,ttm,drm_kms_helper
i2c_algo_bit            5402  1 radeon
fan                     2575  0 
processor              36507  3 acpi_cpufreq
ata_generic             3015  0 
thermal                13154  0 
thermal_sys            14790  4 video,fan,processor,thermal

             total       used       free     shared    buffers     cached
Mem:       2025868    1051176     974692          0      40992     765548
-/+ buffers/cache:     244636    1781232
Swap:      2103292          0    2103292


/usr/lib/pm-utils/sleep.d/00logging hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/00powersave hibernate hibernate:

/usr/lib/pm-utils/sleep.d/00powersave hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/02rtcwake hibernate hibernate:
rtcwake alarm not enabled in /etc/pm/config.d/rtcwake.config, doing nothing...

/usr/lib/pm-utils/sleep.d/02rtcwake hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/06autofs hibernate hibernate:
Shutting down automount ..done

/usr/lib/pm-utils/sleep.d/06autofs hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/30s2disk-check hibernate hibernate:
INFO: checking for suspend-to-disk prerequisites...
  using userspace suspend method, temp. config file /var/lib/s2disk.conf
  setting resume device to /dev/sda1
  setting image size to 933519974
  adding these parameters from /etc/suspend.conf:

/usr/lib/pm-utils/sleep.d/30s2disk-check hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/45pcmcia hibernate hibernate:
ejecting PCMCIA cards...

/usr/lib/pm-utils/sleep.d/45pcmcia hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/49bluetooth hibernate hibernate:

/usr/lib/pm-utils/sleep.d/49bluetooth hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/50rcnetwork hibernate hibernate:

/usr/lib/pm-utils/sleep.d/50rcnetwork hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/55NetworkManager hibernate hibernate:
Having NetworkManager put all interaces to sleep...Failed.

/usr/lib/pm-utils/sleep.d/55NetworkManager hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/75modules hibernate hibernate:

/usr/lib/pm-utils/sleep.d/75modules hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/80acpi-fan hibernate hibernate:

/usr/lib/pm-utils/sleep.d/80acpi-fan hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/80videobios hibernate hibernate:

/usr/lib/pm-utils/sleep.d/80videobios hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/90clock hibernate hibernate:

/usr/lib/pm-utils/sleep.d/90clock hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/94cpufreq hibernate hibernate:

/usr/lib/pm-utils/sleep.d/94cpufreq hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/95led hibernate hibernate:

/usr/lib/pm-utils/sleep.d/95led hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/95packagekit hibernate hibernate:

/usr/lib/pm-utils/sleep.d/95packagekit hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/98video-quirk-db-handler hibernate hibernate:
Kernel modesetting video driver detected, not using quirks.

/usr/lib/pm-utils/sleep.d/98video-quirk-db-handler hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/99Zgrub hibernate hibernate:
INFO: running prepare-grub
  Skipping grub entry #1, because it has the noresume option
  running kernel is grub menu entry 0 (vmlinuz-2.6.37.6-0.7-desktop)
  preparing boot-loader: selecting entry 0, kernel /boot/2.6.37.6-0.7-desktop
  grub-once:   saving original /boot/grub/default
  running '/usr/sbin/grubonce 0'
Using entry #0: Desktop -- openSUSE 11.4 - 2.6.37.6-0.7
    time needed for sync: 0.1 seconds, time needed for grub: 0.0 seconds.

/usr/lib/pm-utils/sleep.d/99Zgrub hibernate hibernate: success.
Running hook /etc/pm/sleep.d/99at hibernate hibernate:

/etc/pm/sleep.d/99at hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/99info hibernate hibernate:

/usr/lib/pm-utils/sleep.d/99info hibernate hibernate: success.
Running hook /usr/lib/pm-utils/sleep.d/99video hibernate hibernate:

/usr/lib/pm-utils/sleep.d/99video hibernate hibernate: success.
Mon Oct 10 14:05:56 EDT 2011: performing hibernate
INFO: using built-in quirks database from HAL.
INFO: S2RAM_OPTS from HAL quirks: ' '.


To the extent that I understand any of it, there is nothing in the log having to do with resuming (so the process failed before it could write to the log?), since the last written time is from when I put the computer in hibernation.

This would seem to have something to do with having the KDE desktop installed, but the full desktop not just whatever is needed to run KDE applications. I did the latter for a while and hibernate worked okay.

Another thing that might be having an effect. I have an external hardrive connected via a USB port, which I leave connected when putting the computer in hibernation; I don’t know if this might be doing something. I did this when I had just Gnome installed and it worked fine.

I am really at a loss, I am not completely new to Linux, but I am not close to being even an ‘expert amateur’. Nothing about hibernation I have found on the forum, or other forums, quite matches what I am seeing, and I am now at a point that I am not sure where to look. I rely on this feature heavily - I can tolerate a failure once a month two out of each three times is a little much. Any help in diagnosing, and hopefully fixing, the problem would be most welcome!

On 2011-10-10 22:16, Brouwer2 wrote:

> and the caps lock
> light flashes.

That signals a kernel crash. A panic, I think.

> To the extent that I understand any of it, there is nothing in the log
> having to do with resuming (so the process failed before it could write
> to the log?), since the last written time is from when I put the
> computer in hibernation.

However, even things that happen before are logged later, on thawing,
because that is when log writes are handled.

> Another thing that might be having an effect. I have an external
> hardrive connected via a USB port, which I leave connected when putting
> the computer in hibernation; I don’t know if this might be doing
> something. I did this when I had just Gnome installed and it worked
> fine.

If the disk is still plugged when you resume, it should not be a problem.

> I am really at a loss, I am not completely new to Linux, but I am not
> close to being even an ‘expert amateur’. Nothing about hibernation I
> have found on the forum, or other forums, quite matches what I am
> seeing, and I am now at a point that I am not sure where to look. I rely
> on this feature heavily - I can tolerate a failure once a month two out
> of each three times is a little much. Any help in diagnosing, and
> hopefully fixing, the problem would be most welcome!

Understandable.

Try to hibernate in text mode (ctrl-alt-f1). The command is “pm-hibernate”.
It also may help disabling the splash display (/etc/suspend.conf: splash = n).


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)

On 10/10/2011 10:16 PM, Brouwer2 wrote:
> In Gnome, the computer goes into hibernation just fine. When resuming
> when the image is finished loading instead of returning to the desktop
> the screen goes blank, not even the backlight is on, and the caps lock
> light flashes.

caps lock flashing normally means “kernel panic” which is most often a
problem (in my experience) with RAM (maybe just tired hardware or a
software induced problem through incompatibility or faulty setup, or i
guess it could be the symptom of a BIOS in need of attention…)…

you might check to see if there is a BIOS update available…
and, you might want to boot from the openSUSE install disk and run the
RAM check, select “Memory Test” at the bottom of this list
http://tinyurl.com/455hbml and let it run overnight…important that you
allow it to run long enough to make several passes…

btw, these are just things to do while waiting for a real guru to
closely inspect all the output you provided…that output hurt me! when
my head fell to the desk i awoke with a sore nose.

have you been installing software from any repos with any of these terms
in their address: factory, playground, tumbleweed?


DD
Caveat
openSUSE®, the “German Automobiles” of operating systems

On 2011-10-11 15:23, DenverD wrote:
> caps lock flashing normally means “kernel panic” which is most often a
> problem (in my experience) with RAM (maybe just tired hardware or a
> software induced problem through incompatibility or faulty setup, or i
> guess it could be the symptom of a BIOS in need of attention…)…

Actually a kernel panic can be caused by anything, hw or sw. It means the
kernel got into a situation so difficult that the programmers consider
impossible to resolve, so they crash the kernel instead, and blink the leds
to tell you. If possible the kernel prints a message, but the situation can
be so bad that it doesn’t or is not viewable.

IIRC, one of the advantages of the new kernel-video drivers instead of xorg
drivers was to be able to print those errors in a crash.


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)

On 10/12/2011 01:23 AM, Carlos E. R. wrote:
> On 2011-10-11 15:23, DenverD wrote:
>> (maybe just tired hardware or a software induced problem …)…
>
> Actually a kernel panic can be caused by anything, hw or sw.

which is exactly the reason i mentioned both (hw and sw) :slight_smile:


DD
openSUSE®, the “German Automobiles” of operating systems

Thank you all for your responses. You have given me a few clues to work on. I didn’t know about the blinking lights signaling a kernal panic. Following up that idea I found the lines in Xorg.0.log

 12986.506] (EE) FATAL: RadeonHD presently does not work with kernel modesetting (KMS).
Please disable KMS in your kernel.

I rebooted with nomodeset, but next hibernation yielded another kernal panic (I also don’t have any trouble with graphics otherwise, so that does not seem to be it).

Oddly enough things seem to be working now (I’ve done about ten hibernates, including seven in a row and each one worked fine). I say ‘oddly’ because I am suspicious that what I did actually had an effect.

I followed up by looking at /etc/suspend.conf to turn off the splash. I changed /etc/suspend.conf: 'splash = ’ from n to y. Thing is that I’ve never had a splash screen during hibernation (before reinstalling, and using 11.2 and 11.3), but I always get one during resume, even with setting splash = n, I have to press Esc to see text. Another reason I am suspicious is that my /etc/suspend.conf has compress = n, but in text during resume one of the lines says that it is decrypting the image. This made me think that perhaps something else is controlling hibernate and resume, so I went through the file list in the ‘pm-utils’ and the ‘suspend’ packages to see what other files might be relevant. In the latter I found this file /usr/share/doc/packages/suspend/HOWTO, which had some interesting stuff about what each of the different options in /etc/suspend.conf does.

In my /etc/suspend.conf I have the following entry: 'max loglevel = ’ (no value entered). In the HOWTO I found this:

The resume tool can use the same configuration file that is used by the
s2disk tool, but it will ignore most of the above parameters. It will use the
value of “suspend loglevel” as the kernel console loglevel during resume.
Additionally it will use the value of “max loglevel” as the kernel console
loglevel to switch to in case the resume fails (this parameter is ignored by
the s2disk tool).

I figured it could not hurt to set a value for the ‘max loglevel’ entry. I set it to 3 (I figure the worst that could happen is that if resume does not work it takes the computer to a console). Since then I have not encountered either of the problems I described above, but primarily because the hibernate image seems to be encrypted even though the setting in /etc/suspend.conf for compression is ‘no’, I am not sure that this is the reason why things seem to be working now (though it is still too early to say that things really are working as they should).

Thanks also for the tip about possible RAM issues. My computer is just over five years old now, so hardware failure is certainly possible. The hard disk seems fine (did a test with Disk Utility a couple of weeks ago), but I did not know that there were tests for RAM (but being Linux I am not surprised :slight_smile: ). As for repositories, I have only the default repos and packman enabled.

On 2011-10-12 15:36, Brouwer2 wrote:

Glad it works, even if you don’t know why :slight_smile:

> primarily because the hibernate image seems to be encrypted even though
> the setting in /etc/suspend.conf for compression is ‘no’,

Compression is a different thing than encryption, I think it is a different
setting.

Maybe if you trigger the hibernation from the desktop there are some
settings being passed to it from the desktop. I almost always trigger it
from CLI.


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)

Compression is a different thing than encryption, I think it is a different
setting.

Indeed! I’m just not reading properly (really should never write anything before having some coffee:embarrassed:), and so my suspicions are not so well founded, which strengthens a little the supposition that the change to the ‘max loglevel’ might have been the thing.

On 2011-10-12 17:46, Brouwer2 wrote:
>
>> Compression is a different thing than encryption, I think it is a
>> different setting.
>
> Indeed! I’m just not reading properly (really should never write
> anything before having some coffee:embarrassed:), and so my suspicions
> are not so well founded, which strengthens a little the supposition that
> the change to the ‘max loglevel’ might have been the thing.

Sometimes I get the idea that observing the experiment changes the results.
This is true of particle physics, but it seems to happen to computers too :-p


Cheers / Saludos,

Carlos E. R.
(from 11.4 x86_64 “Celadon” at Telcontar)