"On battery" is not recognized

8,309

Solution 1

I discovered that /proc/acpi/battery/BAT1/info was erased somehow. So I found out that the battery-information will be reset when:

  1. Shutdown
  2. Take battery out
  3. Turn on
  4. Shutdown
  5. Plug in the battery
  6. Turn on

It works now :)

Solution 2

In my opinion not recognizing the battery really isn't a Ubuntu problem but a Linux kernel problem. I also have it with openSuse 11.4 and kernel 3.1.0-rc5-1-vanilla. I have found out that the battery is detected when one of the following happens:

  1. Disconnect and connect the external power supply ("AC")
  2. Open the lid of the notebook.
  3. and the most weird: do as described above.

The static properties of the battery where detected but not shown in the /sys subdirectories because the dynamic properties (current voltage, current, load, load state), especially battery_present, where not detected and hence the battery information is removed from /sys by the kernel.

With Windows 7 the battery was immediately recognized.

It would be nice to inform the kernel developers of this ... but bugzilla.kernel.org now has been down for some time ...

Share:
8,309
Lasse Espeholt
Author by

Lasse Espeholt

Updated on September 17, 2022

Comments

  • Lasse Espeholt
    Lasse Espeholt over 1 year

    I have just bought a lovely ThinkPad Edge 11 which have ~6 hours of surfing in Windows 7. But unfortunately, a clean Ubuntu 10.10 give me max 4 hours which is not satisfactorily. Therefore I have installed laptop-mode-tools and powertop.

    In the sequence of installing and using these tools something have gone wrong. Now, the laptop don't recognize when the power is plugged off so the screen etc. is not dimmed. It still makes a sound when power is plugged in and taken out but I suspect that this is not through Ubuntu. I have tried uninstall of the tools and, of cause, rebooting - but nothing helps. I'm not a pro with Linux so some expertise would be appreciated. Any ideas to how I can restore the settings or get it to recognize "on battery"?

    Update: I have tried reinstalling acpi-support, pm-utils and laptop-detect without luck.

  • Lasse Espeholt
    Lasse Espeholt over 13 years
    YES! Your answer was not correct, but it lead me to a answer on a forum. Thanks :)
  • jnut
    jnut over 13 years
    then could you post the link so in the future people who have the same problems are guided to the correct place please. maybe tick mine?
  • Lasse Espeholt
    Lasse Espeholt over 13 years
    I have posted an answer if you didn't notice :)
  • Nikana Reklawyks
    Nikana Reklawyks over 8 years
    Got any idea why this works ?
  • ccamara
    ccamara over 6 years
    Was skeptical about this solution, but since I was also desperate I tried it and, to my surprise, worked.