Autor Thema: System freeze when leaving stand by on battery (Solved)  (Gelesen 1047 mal)

0 Nutzer und 1 Gast betrachten dieses Thema.

Offline kgha

  • Vollprofi
  • *
  • Beiträge: 432
When I want to resume from stand by (suspend to disc) and hit a key the system freezes. I just get a blinking cursor on the fluxflux boot screen and the only way out is a cold start.

This only happens when running on battery power! With the AC adapter plugged in it works fine.

Annoying, since it's when you're on battery power you really need the stand by function (power saving)

Oh, and it's an eee900 pc...

EDIT: I wondered if CPU frequency could be the cause (lower frequency while on battery). So I used the config script and set CPU freqency to 900 MHz (static). Now I got an error message when trying to leave standby:

CPU 0: Machine Check Exception: 0000000000000004
CPU 0: Bank 1: 3200000000000125
Kernel Panic - not syncing: CPU context corrupt

EDIT 2: ...and if i set CPU frequency to 675 MHz (static) and run on AC standby still works! So CPU frequency is probably not the cause. Could it have something to do with voltage? Battery gives 7.4 V, adapter gives 12 V

EDIT 3: I tried booting from my SD card (with full install) with the same result, so it shouldn't be something wrong with the install or config.
« Letzte Änderung: 08.09.2009, 21:13:57 von kgha »
"Ubuntu": an African word, meaning "Slackware is soooo difficult"
------------------------------------------------------------------------------------------
„Ubuntu”: ein afrikanisches Wort, das bedeutet „Slackware ist soooo schwer”

Offline Manfred

  • Administrator
  • *
  • Beiträge: 1.077
    • NASS e.K.
Re: System freeze when leaving stand by on battery
« Antwort #1 am: 14.08.2009, 08:37:26 »
Hi Kgha,

...it's an eee900 pc...

As I own no eee900, I'm sorry we have to wait until flux has finished his holidays :(

Regards, Quax
Hole Deine Benutzer da ab, wo sie stehen,
nicht da, wo Du sie gerne stehen hättest...
---------------------------------------------------
Pick up the users where they really are
and not where you expect them to be...

Offline kgha

  • Vollprofi
  • *
  • Beiträge: 432
Re: System freeze when leaving stand by on battery
« Antwort #2 am: 14.08.2009, 11:35:11 »
Sounds great  :)

Some food for thought for flux when he returns, I hope he comes back from holidays full of energy ;D

After experimenting a bit my suspicions that low voltage can be the cause have been strengthened:

Suspending on AC, resuming on AC = OK
Suspending on AC, resuming on battery = Fail
Suspending on battery, resuming on battery = Fail
Suspending on battery, resuming on AC = OK

Fully loaded battery doesn't help (and I've tried two different batteries)

I have no problems starting from Power Off status on battery.

EDIT: More experimenting that hopefully can be helpful when flux tries to find an explanation : I booted from my USB Live install (the same that I have used for my full install, it's the 20090720 iso).
When I run on battery, resuming from suspend does not cause a freeze but a complete reboot.
On AC i have no problems with suspend/resume.

EDIT2: Progress! Well, kind of...

There are two 'suspend' shell scripts on my SSD: /etc/acpi/suspend (the one that fails) and another one named /etc/acpi/actions/suspend.sh

When I tried to run the latter I got the following error message in the terminal:

root@ff-sl: /home/kgha # bash /etc/acpi/actions/suspend.sh
/etc/acpi/actions/suspend.sh: line 7: /etc/default/eeepc-acpi-scripts: No such file or directory
which: no  in (/usr/local/sbin:/usr/local/bin:/sbin:/usr/sbin:/bin:/usr/bin)

But the pc went into suspend state and I could resume when running on battery!

Maybe flux can edit this script or use it as a starting point for a new one so that it works without error messages?
« Letzte Änderung: 15.08.2009, 16:34:05 von kgha »
"Ubuntu": an African word, meaning "Slackware is soooo difficult"
------------------------------------------------------------------------------------------
„Ubuntu”: ein afrikanisches Wort, das bedeutet „Slackware ist soooo schwer”

Offline kgha

  • Vollprofi
  • *
  • Beiträge: 432
Re: System freeze when leaving stand by on battery
« Antwort #3 am: 17.08.2009, 12:05:55 »
Continued experimenting:

At the office, running on AC, noticed that after suspend/resume I cannot reconnect to the wifi. The wicd log contains the following:
Attempting to authenticate...
2009/08/17 11:32:32 :: Ignoring template line: '        ca_cert="$_CA_CERT"
2009/08/17 11:32:32 :: '
2009/08/17 11:33:08 :: wpa_supplicant authentication may have failed.
2009/08/17 11:33:08 :: Running DHCP
2009/08/17 11:34:08 :: Broadcasting DHCP_DISCOVER
2009/08/17 11:34:08 ::
2009/08/17 11:34:08 :: timed out waiting for a valid DHCP server response
2009/08/17 11:34:08 ::
2009/08/17 11:34:08 :: DHCP connection failed
After rebooting connecting runs as normal, giving the following entry in the wicd.log file:
Attempting to authenticate...
2009/08/17 11:25:13 :: Ignoring template line: '        ca_cert="$_CA_CERT"
2009/08/17 11:25:13 :: '
2009/08/17 11:25:17 :: Running DHCP
2009/08/17 11:25:18 :: Broadcasting DHCP_DISCOVER
2009/08/17 11:25:18 ::
2009/08/17 11:25:18 :: dhcpIPaddrLeaseTime=86400 in DHCP server response.
...and so on.

However, if I first turn off the wifi card and then turn it on again I can connect.

And once again I tried the other suspend script: /etc/acpi/actions/suspend.sh and then I had no problems reconnecting after resume.
« Letzte Änderung: 18.08.2009, 16:40:30 von kgha »
"Ubuntu": an African word, meaning "Slackware is soooo difficult"
------------------------------------------------------------------------------------------
„Ubuntu”: ein afrikanisches Wort, das bedeutet „Slackware ist soooo schwer”

Offline kgha

  • Vollprofi
  • *
  • Beiträge: 432
Re:System freeze when leaving stand by on battery (Solved???)
« Antwort #4 am: 25.08.2009, 22:08:23 »
Update:

For a few days I've used my eee on battery at conferences, and in order to save battery I've run the /etc/acpi/actions/suspend.sh script from terminal as root and it has worked flawlessly.

So tonight I decided to try the following:

I renamed /etc/acpi/suspend to /etc/acpi/suspend.bak

I copied /etc/acpi/actions/suspend.sh to the folder /etc/acpi/ and deleted the suffix .sh

Now i can go into suspend mode via Fn+F1 or via the 'abmelden' script and resume without any trouble.

I would appreciate flux's comments on this when he can find the time - no hurry since everything seems to work! Maybe there are better solutions?
"Ubuntu": an African word, meaning "Slackware is soooo difficult"
------------------------------------------------------------------------------------------
„Ubuntu”: ein afrikanisches Wort, das bedeutet „Slackware ist soooo schwer”

Offline flux

  • Administrator
  • *
  • Beiträge: 1.891
Re:System freeze when leaving stand by on battery (Solved???)
« Antwort #5 am: 08.09.2009, 20:14:53 »
You have more possibilities ...

Suspend-to-RAM: you can use as root
/usr/bin/pmsuspend # or
/etc/acpi/actions/suspend.sh # or
/etc/acpi/suspend

Suspend-to-Disk: you can use the script /etc/acpi/suspend, if you change the line
echo -n mem > /sys/power/stateto
echo -n disk > /sys/power/stateand add a
resume=/dev/<swappartition>to the append-line of grub's configuration.

flux.
"Et semel emissum volat irrevocabile verbum."
Und einmal entsandt fliegt unwiderruflich das Wort.
(Horaz)

Offline kgha

  • Vollprofi
  • *
  • Beiträge: 432
Re:System freeze when leaving stand by on battery (Solved)
« Antwort #6 am: 08.09.2009, 21:19:37 »
Thank you, I consider the problem solved, then  :) and my home-made solution copying and renaming /etc/acpi/actions/suspend.sh to etc/acpi/suspend seems to work fine.

So far I haven't missed a suspend-to-disk function, but it's good to know that it can be done easily.
"Ubuntu": an African word, meaning "Slackware is soooo difficult"
------------------------------------------------------------------------------------------
„Ubuntu”: ein afrikanisches Wort, das bedeutet „Slackware ist soooo schwer”