0

A few weeks ago, I decided to get adventurous and install different interfaces on my Lenovo T420 running Xubuntu. I decided to jettison Kubuntu after trying it out (just not my style) and kept Xubuntu and Ubuntu with Unity. After doing this, I noticed that a problem emerged: the battery charge indicators no longer worked that well when I docked my laptop into the Lenovo base station I bought for it. From what I can tell, it's still charging through the base, as it had before I did the work with the interface packages. When I use my power cord, it seems to notice changes in the charge level, but does so unreliably. If I take my battery out with the cord plugged in (not on the base), turn on the computer, and put the battery back in, the difference in charge begins to show up in the battery indicator icon in the system tray.

This occurs whether I use XFCE's battery indicator or the one in Unity. I found a similar topic on here dealing with this, but that was on Debian and a different version of XFCE.

I'll probably end up re-installing Xubuntu with the 15.10 or 16.04 release, and that should take care of the problem, but in the meantime, what can I do to fix this?

EDIT:

Adding this logging from running xfce4-power-manager --debug:

TRACE[xfpm-main.c:192] xfpm_start(): Starting the power manager
TRACE[xfpm-xfconf.c:631] xfpm_xfconf_init(): lock screen TRUE
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for general-notification
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for critical-power-level
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for show-brightness-popup
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for handle-brightness-keys
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for show-tray-icon
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for critical-power-action
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for hibernate-button-action
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for sleep-button-action
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for lid-action-on-ac
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for lid-action-on-battery
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for brightness-level-on-ac
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for brightness-level-on-battery
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for brightness-slider-min-level
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for dpms-sleep-mode
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for inactivity-on-ac
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for inactivity-on-battery
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for inactivity-sleep-mode-on-ac
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for inactivity-sleep-mode-on-battery
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for brightness-on-ac
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for brightness-on-battery
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for network-manager-sleep
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for logind-handle-power-key
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for logind-handle-suspend-key
TRACE[xfpm-xfconf.c:164] xfpm_xfconf_load(): Using default configuration for logind-handle-hibernate-key
TRACE[xfpm-polkit.c:314] xfpm_polkit_init_data(): Using unix session polkit subject
TRACE[xfpm-polkit.c:406] xfpm_polkit_check_auth_intern(): Action=org.freedesktop.login1.power-off is authorized=TRUE
TRACE[xfpm-polkit.c:406] xfpm_polkit_check_auth_intern(): Action=org.freedesktop.login1.reboot is authorized=TRUE
TRACE[xfpm-polkit.c:406] xfpm_polkit_check_auth_intern(): Action=org.freedesktop.login1.suspend is authorized=TRUE
TRACE[xfpm-polkit.c:406] xfpm_polkit_check_auth_intern(): Action=org.freedesktop.login1.hibernate is authorized=FALSE
TRACE[xfpm-power.c:957] xfpm_power_get_power_devices(): Power device detected at : /org/freedesktop/UPower/devices/line_power_AC
TRACE[xfpm-power.c:915] xfpm_power_add_device(): 'line-power' device added
TRACE[xfpm-power.c:957] xfpm_power_get_power_devices(): Power device detected at : /org/freedesktop/UPower/devices/battery_BAT0
TRACE[xfpm-power.c:915] xfpm_power_add_device(): 'battery' device added
TRACE[xfpm-power.c:925] xfpm_power_add_device(): Battery device type 'battery' detected at: /org/freedesktop/UPower/devices/battery_BAT0
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 124 : ((XfpmButtonKey) BUTTON_POWER_OFF)

(xfce4-power-manager:6283): xfce4-power-manager-WARNING **: could not map keysym 1008ffa8 to keycode

TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 213 : ((XfpmButtonKey) BUTTON_HIBERNATE)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 150 : ((XfpmButtonKey) BUTTON_SLEEP)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 233 : ((XfpmButtonKey) BUTTON_MON_BRIGHTNESS_UP)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 232 : ((XfpmButtonKey) BUTTON_MON_BRIGHTNESS_DOWN)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 244 : ((XfpmButtonKey) BUTTON_BATTERY)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 238 : ((XfpmButtonKey) BUTTON_KBD_BRIGHTNESS_UP)
TRACE[xfpm-button.c:183] xfpm_button_xevent_key(): Grabbed key 237 : ((XfpmButtonKey) BUTTON_KBD_BRIGHTNESS_DOWN)
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-power.c:213] xfpm_power_check_polkit_auth(): using logind suspend backend
TRACE[xfpm-polkit.c:406] xfpm_polkit_check_auth_intern(): Action=org.freedesktop.login1.suspend is authorized=TRUE
TRACE[xfpm-polkit.c:406] xfpm_polkit_check_auth_intern(): Action=org.freedesktop.login1.hibernate is authorized=FALSE
TRACE[xfpm-power.c:1448] xfpm_update_blank_time(): Timeout: 10
TRACE[xfpm-power.c:1448] xfpm_update_blank_time(): Timeout: 10
TRACE[xfpm-power.c:1448] xfpm_update_blank_time(): Timeout: 10
TRACE[xfpm-power.c:1448] xfpm_update_blank_time(): Timeout: 15
TRACE[xfpm-manager.c:556] xfpm_manager_inhibit_sleep_systemd(): Inhibiting systemd sleep: handle-power-key:handle-suspend-key:handle-hibernate-key:handle-lid-switch

(xfce4-power-manager:6283): xfce4-power-manager-WARNING **: Unable to set the kernel brightness switch parameter to 0.
TRACE[xfpm-backlight.c:259] xfpm_backlight_brightness_on_ac_settings_changed(): Alarm on ac timeout changed 9
TRACE[xfpm-backlight.c:280] xfpm_backlight_brightness_on_battery_settings_changed(): Alarm on battery timeout changed 120

(xfce4-power-manager:6283): xfce4-power-manager-WARNING **: Failed to get keyboard max brightness level : Method "GetMaxBrightness" with signature "" on interface "org.freedesktop.UPower.KbdBacklight" doesn't exist

TRACE[xfpm-polkit.c:251] xfpm_polkit_free_data(): Destroying Polkit data
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
TRACE[xfpm-battery.c:189] xfpm_battery_refresh_icon(): Battery state 1
TRACE[xfpm-battery.c:240] xfpm_battery_refresh_icon(): Battery icon xfpm-primary-060-charging
  • Why can't people understand the only differences between the *buntus besides the first letter is the desktop environment. See Converting Between the Ubuntus to see how easy it really is. To fix your problem, uninstall all desktops, with the purge command, then reboot, and install your chosen DE. There is no need to use a whole LiveCD/USB just to recover a desktop. If you need an answer I'll write one for you. – eyoung100 Jun 25 '15 at 4:22
  • @eyoung100 I do understand that as the only difference. Thus trying to install different ones to try things out. Something just got borked is all. Now, I tried the commands you recommended, and it's still a little wonky. It recognizes charge from the dock base, but not all of it. It only charged 8% in 9 hours, but can get to 100% on the charger cable with the same amount of use. Any other insights? – nerdenator Jun 26 '15 at 1:15
  • Use your BIOS to check your battery health – eyoung100 Jun 26 '15 at 3:14
  • Update: The battery is fine in BIOS. I reinstalled Xubuntu and I'm still seeing this problem. I was able to obtain some debugging information from the power manager, which has been added to the main post. – nerdenator Jul 12 '15 at 1:16
  • Does it work if you do a fresh install? – rogerdpack Oct 23 at 18:52
0

Looks like your UPower is broken.

Xfpm4 reacts to signals from UPower over dbus to adjust the icon. And that's it. If UPower doesn't communicate this in the right way, xfpm4 can't do much about this. Better ask your distributor to fix this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.