Bug 178157 - Hibernate functionnality is made available when it cannot work
Hibernate functionnality is made available when it cannot work
Status: CLOSED DUPLICATE of bug 177851
Product: Fedora
Classification: Fedora
Component: gnome-power-manager (Show other bugs)
5
All Linux
medium Severity medium
: ---
: ---
Assigned To: John (J5) Palmieri
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-01-17 22:39 EST by Ricky Ng-Adam
Modified: 2013-03-13 00:49 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-02-08 11:11:51 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)
Dmesg output. (14.52 KB, text/plain)
2006-02-05 21:40 EST, Jim Cornette
no flags Details
Dmesg output (3.23 KB, text/plain)
2006-02-05 21:50 EST, Jim Cornette
no flags Details
dmidecode information outputted to file (12.08 KB, text/plain)
2006-02-05 21:55 EST, Jim Cornette
no flags Details
acpi message to root that seems related to hibernation problem. (8.45 KB, text/plain)
2006-02-07 23:33 EST, Jim Cornette
no flags Details

  None (edit)
Description Ricky Ng-Adam 2006-01-17 22:39:37 EST
Description of problem:

There is a (possibly not useful) AC cable icon on my gnome panel now.  When I
right-click on it I get as a first option "Hibernate".  I've tried it a few
times unsuccessfully (with no error message) before realizing that it couldn't
possibly work because I have no swap.

Version-Release number of selected component (if applicable):

gnome-power-manager-0.3.3-0.cvs.20060106

How reproducible:

always

Steps to Reproduce:
1. try to hibernate
2.
3.
  
Actual results:

locked dialog comes back after a few seconds

Expected results:

Either of these:

*No AC icon for a desktop
*No hibernate option when I have no swap
*The possibility or instructions to get swap
*A proper error message

Additional info:

PM: suspend-to-disk mode set to 'platform'
Stopping tasks:
================================================================================================|
Shrinking memory... done (18438 pages freed)
pnp: Device 00:0c disabled.
pnp: Device 00:0a disabled.
pnp: Device 00:09 disabled.
pnp: Device 00:08 disabled.
0000:00:10.0: tulip_stop_rxtx() failed
PM: snapshotting memory.
swsusp: Saving Highmem
swsusp: critical section:
swsusp: Need to copy 47895 pages
swsusp: pages needed: 47895 + 141 + 1024, free: 83155
swsusp: available memory: 83155 pages
alloc_pagedir(): nr_pages = 47895
swsusp: critical section/: done (47895 pages copied)
Intel machine check architecture supported.
Intel machine check reporting enabled on CPU#0.
swsusp: Restoring Highmem
Debug: sleeping function called from invalid context at mm/slab.c:2528
in_atomic():0, irqs_disabled():1
 [<c0152753>] kmem_cache_alloc+0x1b/0x79     [<c01e2459>]
acpi_os_acquire_object+0xb/0x3c
 [<c01f6f74>] acpi_ut_allocate_object_desc_dbg+0x13/0x49     [<c01f6fbd>]
acpi_ut_create_internal_object_dbg+0x13/0x68
 [<c01f34ad>] acpi_rs_set_srs_method_data+0x3d/0xb7     [<c0151697>]
cache_alloc_debugcheck_after+0xb8/0xea
 [<c01fa52f>] acpi_pci_link_set+0x3b/0x17c     [<c01fa5f7>]
acpi_pci_link_set+0x103/0x17c
 [<c01fa6a4>] irqrouter_resume+0x34/0x52     [<c0226eaf>] __sysdev_resume+0x11/0x53
 [<c0226fef>] sysdev_resume+0x16/0x47     [<c022af8a>] device_power_up+0x5/0xa
 [<c01343af>] swsusp_suspend+0x6b/0x85     [<c013533c>] pm_suspend_disk+0x4e/0xf6
 [<c01337b0>] enter_state+0x50/0x1a6     [<c013398e>] state_store+0x88/0x94
 [<c0133906>] state_store+0x0/0x94     [<c0187e4e>] subsys_attr_store+0x1e/0x22
 [<c0187f5d>] sysfs_write_file+0xa9/0xd2     [<c0187eb4>] sysfs_write_file+0x0/0xd2
 [<c0155343>] vfs_write+0xa1/0x140     [<c015584b>] sys_write+0x3c/0x63
 [<c0102ba9>] syscall_call+0x7/0xb    <7>PCI: Setting latency timer of device
0000:00:01.0 to 64
ACPI: PCI Interrupt 0000:00:05.0[A] -> Link [LNKB] -> GSI 10 (level, low) -> IRQ 10
ACPI: PCI Interrupt 0000:00:10.0[A] -> Link [LNKD] -> GSI 5 (level, low) -> IRQ 5
ACPI: PCI Interrupt 0000:00:11.1[A] -> Link [LNKA] -> GSI 11 (level, low) -> IRQ 11
PCI: Via IRQ fixup for 0000:00:11.1, from 0 to 11
ACPI: PCI Interrupt 0000:00:11.2[D] -> Link [LNKD] -> GSI 5 (level, low) -> IRQ 5
ACPI: PCI Interrupt 0000:00:11.3[D] -> Link [LNKD] -> GSI 5 (level, low) -> IRQ 5
ACPI: PCI Interrupt 0000:00:11.4[D] -> Link [LNKD] -> GSI 5 (level, low) -> IRQ 5
ACPI: PCI Interrupt 0000:01:00.0[A] -> Link [LNKA] -> GSI 11 (level, low) -> IRQ 11
pnp: Device 00:08 activated.
pnp: Device 00:09 activated.
pnp: Device 00:0a activated.
pnp: Device 00:0b does not supported activation.
pnp: Device 00:0c activated.
PM: writing image.
swsusp: Cannot find swap device, try swapon -a.
Restarting tasks... done
agpgart: Found an AGP 2.0 compliant device at 0000:00:00.0.
agpgart: Putting AGP V2 device at 0000:00:00.0 into 1x mode
agpgart: Putting AGP V2 device at 0000:01:00.0 into 1x mode
[drm] Loading R200 Microcode
0000:00:10.0: tulip_stop_rxtx() failed
eth0: Setting full-duplex based on MII#1 link partner capability of 45e1.
Comment 1 Richard Hughes 2006-01-18 04:27:05 EST
The HAL script hal-system-power-hibernate probably should check for this, and
fail gracefully by cancelling the hibernate and sending an error that g-p-m
could catch. Is there a way on the command line to check if a computer has swap
enabled?
Thanks.
Comment 2 Jim Cornette 2006-02-04 23:26:07 EST
I just tried the hibernate function and the system just took a really short nap.
It resumed with this output to dmesg.
Stopping tasks:
============================================================================================|
Shrinking memory... done (0 pages freed)
pnp: Device 00:0a disabled.
pnp: Device 00:09 disabled.
eth0: remaining active for wake-on-lan
PM: snapshotting memory.
swsusp: Saving Highmem
swsusp: critical section:
swsusp: Need to copy 66321 pages
swsusp: pages needed: 66321 + 195 + 1024, free: 97245
swsusp: available memory: 97245 pages
alloc_pagedir(): nr_pages = 66321
swsusp: critical section/: done (66321 pages copied)
Intel machine check architecture supported.
Intel machine check reporting enabled on CPU#0.
swsusp: Restoring Highmem
Debug: sleeping function called from invalid context at mm/slab.c:2646
in_atomic():0, irqs_disabled():1
 [<c01e1e19>] acpi_os_acquire_object+0xb/0x3c     [<c0151926>]
kmem_cache_alloc+0x20/0x7c
 [<c01e1e19>] acpi_os_acquire_object+0xb/0x3c     [<c01f6fd9>]
acpi_ut_allocate_object_desc_dbg+0x10/0x3e
 [<c01f701a>] acpi_ut_create_internal_object_dbg+0x13/0x68     [<c01f332d>]
acpi_rs_set_srs_method_data+0x3d/0xb7
 [<c0150917>] cache_alloc_debugcheck_after+0xb8/0xea     [<c01fa66e>]
acpi_pci_link_set+0x3b/0x169
 [<c01fa723>] acpi_pci_link_set+0xf0/0x169     [<c01fa7d0>]
irqrouter_resume+0x34/0x52
 [<c0226f67>] __sysdev_resume+0x11/0x53     [<c02270a7>] sysdev_resume+0x16/0x47
 [<c022b056>] device_power_up+0x5/0xa     [<c01331b7>] swsusp_suspend+0x6b/0x85
 [<c013411a>] pm_suspend_disk+0x4e/0xf8     [<c01325c4>] enter_state+0x50/0x1ba
 [<c01327b6>] state_store+0x88/0x94     [<c013272e>] state_store+0x0/0x94
 [<c0187822>] subsys_attr_store+0x1e/0x22     [<c0187931>]
sysfs_write_file+0xa9/0xd2
 [<c0187888>] sysfs_write_file+0x0/0xd2     [<c0154397>] vfs_write+0xa1/0x140
 [<c015489f>] sys_write+0x3c/0x63     [<c0102ba9>] syscall_call+0x7/0xb
ACPI: PCI Interrupt 0000:00:02.0[A] -> Link [LNKU] -> GSI 10 (level, low) -> IRQ 10
ACPI: PCI Interrupt 0000:00:06.0[A] -> Link [LNKH] -> GSI 5 (level, low) -> IRQ 5
ACPI: PCI Interrupt 0000:00:08.0[A] -> Link [LNKG] -> GSI 3 (level, low) -> IRQ 3
ACPI: PCI Interrupt 0000:00:0a.0[A] -> Link [LNKF] -> GSI 11 (level, low) -> IRQ 11
Yenta O2: res at 0x94/0xD4: 00/ea
Yenta O2: enabling read prefetch/write burst
ACPI: PCI Interrupt 0000:00:0c.0[A] -> Link [LNKC] -> GSI 10 (level, low) -> IRQ 10
ACPI: PCI Interrupt 0000:00:10.0[A]: no GSI
ACPI: PCI Interrupt 0000:00:12.0[A] -> Link [LNKB] -> GSI 11 (level, low) -> IRQ 11
eth0: DSPCFG accepted after 0 usec.
eth0: Setting full-duplex based on negotiated link capability.
ACPI: PCI Interrupt 0000:01:05.0[A] -> Link [LNKC] -> GSI 10 (level, low) -> IRQ 10
pnp: Device 00:05 does not supported activation.
pnp: Device 00:06 does not supported activation.
pnp: Evaluate _CRS failed
pnp: Failed to activate device 00:09.
pnp: Device 00:0a activated.
PM: writing image.
swsusp: Cannot find swap device, try swapon -a.
Restarting tasks... done
agpgart: Found an AGP 2.0 compliant device at 0000:00:00.0.
agpgart: Putting AGP V2 device at 0000:00:00.0 into 4x mode
agpgart: Putting AGP V2 device at 0000:01:05.0 into 4x mode
audit(:0): major=252 name_count=0: freeing multiple contexts (1)
audit(:0): major=113 name_count=0: freeing multiple contexts (2)
audit(:0): major=252 name_count=0: freeing multiple contexts (1)
audit(:0): major=113 name_count=0: freeing multiple contexts (2)
Comment 3 Richard Hughes 2006-02-05 10:26:11 EST
Jim, that looks like a acpi kernel problem -- have you tried a rawhide/vanilla
kernel?
Comment 4 Jim Cornette 2006-02-05 21:37:14 EST
I just tried again with kernel-2.6.15-1.1909_FC5 from Rawhide. The action seemed
the same. The computer seems to attempt to go into hibernation and then decides
otherwise.
I'll attach dmesg to the report. 
Comment 5 Jim Cornette 2006-02-05 21:40:05 EST
Created attachment 124236 [details]
Dmesg output.

The last event should be the computer, HP Pavilion ze4300 trying to go into
hybernation but only taking a "brief nap"
Comment 6 Jim Cornette 2006-02-05 21:50:01 EST
Created attachment 124237 [details]
Dmesg output

Funny thing that dmesg and /var/log/dmesg are not the same output. I did not
realize this and copied terminal output to document attached.
Comment 7 Jim Cornette 2006-02-05 21:55:29 EST
Created attachment 124238 [details]
dmidecode information outputted to file

In case this is acpi related and the BIOS is at fault, here is the output from
dmidecode.
Comment 8 Richard Hughes 2006-02-06 06:40:53 EST
> swsusp: Cannot find swap device, try swapon -a.

Can you try enabling swap and then trying?
Comment 9 Jim Cornette 2006-02-07 23:33:00 EST
Created attachment 124351 [details]
acpi message to root that seems related to hibernation problem.

This message to system mail was generated probably when I tried to go into
hibernation. Test comment regarding swapon next.
Comment 10 Jim Cornette 2006-02-07 23:42:03 EST
I believe my swap partition is active when I try to go into hibernation mode.

swapon -s
Filename                                Type            Size    Used   
Priority/dev/hda5                               partition       819272  92      -1

If I run swapon -a - I get no response. If I run swapoff -a and do a swapon -s
nothing is outputted.
doing swapon -a again shows the same size partition but with zero used on the
partition.
My swap partition is /dev/hda5 which is contained in the /dev/hda4 partition as
listed below with fdisk -l and df. Is it possible that having swap as a far out
partition within and extended partiton is causing the problem?

   Device Boot      Start         End      Blocks   Id  System
/dev/hda1   *           1          13      104391   83  Linux
/dev/hda2              14        2124    16956607+  83  Linux
/dev/hda3            2125        3399    10241437+  83  Linux
/dev/hda4            3400        4864    11767612+   5  Extended
/dev/hda5            3400        3501      819283+  82  Linux swap / Solaris
/dev/hda6            3502        4864    10948266   83  Linux
[root@cornette-lt ~]# df
Filesystem           1K-blocks      Used Available Use% Mounted on
/dev/hda2             16425032   6287068   9290136  41% /
/dev/hda1               101086     12137     83730  13% /boot
/dev/shm                322380         0    322380   0% /dev/shm
/dev/hda3              9920624   4288672   5119884  46% /home
/dev/hda6             10605128    377240   9680476   4% /var
Comment 11 Jim Cornette 2006-02-07 23:46:29 EST
After testing hibernation, swap grew to the below. The -2 priority might be
because of turnig off swap and then turning back on swap.

swapon -s
Filename                                Type            Size    Used   
Priority/dev/hda5                               partition       819272  1032    -2

Free outputs the below:
free
             total       used       free     shared    buffers     cached
Mem:        644760     312660     332100          0      57800      68432
-/+ buffers/cache:     186428     458332
Swap:       819272       1032     818240
Comment 12 Deji Akingunola 2006-02-08 00:41:06 EST
I believe this is a known kernel bug; see bug #177851.
Comment 13 Jeremy Katz 2006-02-08 11:11:51 EST

*** This bug has been marked as a duplicate of 177851 ***
Comment 14 Ricky Ng-Adam 2006-02-09 08:25:36 EST
Wait a minute...  This bug as I originally reported isn't about the "kernel bug"
but about erroneously having the option to hibernate when it is not possible to
do it (no swap)! It is not because that when Jim Cornette activates the swap he
encounters a separate bug that this should be closed...
Comment 15 Jim Cornette 2006-02-09 12:57:36 EST
I have swap but when trying to bring the computer into hibernation, it is not
obvious to the processes which try to bring the computer into this mode, that
swap is active. If it is the kernel or something in the hibernate process other
thn the kernel is not clear to me.

If the bug report is to get rid of hibernate and suspend from the menu, I
disagree. The feature will start working and is in a good location.

I agree, my situation is closer to bug 177851. Gnome-power-manager is not the
problem or component.
Comment 16 Richard Hughes 2006-02-09 13:34:03 EST
Why don't we just add a check for swap for the pm-hibernate (i.e. bugzilla the
pm-utils package)?
Comment 17 Jim Cornette 2006-02-09 20:05:44 EST
This might be alright if the detection used by the script matched if swap was
present or not present.
 I get this error when running from a terminal and the system is back up.
/usr/sbin/pm-hibernate: line 24: echo: write error: No such device
Comment 18 Monty 2006-02-10 18:11:07 EST
This is not a duplicate of 177851. The machine in 177851 successfully copies
state to swap then aborts out for no obvious reason.  This bug is visibly being
caused because swsusp cannot find the swap partition, and that causes it to err
out immediately.  The same thing is happening on my Thinkpad T42p running latest
rawhide.

The machine does have swap.  The swap is on.  swsusp doesn't find it.

The 'no such device' error appears spurious as it occurs after hibernate is long
gone into the weeds.
Comment 19 Monty 2006-02-10 18:29:19 EST
Another note:

Partial retraction: This may actually be a dupe after all; it's hard to tell 
becasue the critical line:

swsusp: Cannot find swap device, try swapon -a.

is logged well out of order; watched on the console, it is the first error
thrown in the process.  In the above log (and checking my own messages output)
it is logged as one of the last errors, or well after the last error.  The fact
that it does not appear in the other report may not mean it didn't happen there too.

Note You need to log in before you can comment on or make changes to this bug.