You are not logged in.

#1 2020-08-27 16:34:52

Gtlsgamr
Member
Registered: 2020-08-27
Posts: 8

[SOLVED] High power usage by network device.

EDIT: (previous title: Backlight power usage shown in thousands of percentage by powertop)
This was not the issue and the backlight numbers were misleading. The powerhog was actually my network device and using tlp settings seems to have solved the issue;

Hi,
I've been using arch for the past 6 months without any issues on my Lenovo Ideapad 310. Recently I bought a new laptop and installed arch on it. The issue I'm facing is that the backlight uses enormous amounts of power. Powertop shows that backlight uses 25700% of power. I am not really sure what is eating up my battery THAT much, but it barely runs for half an hour just on battery with brightness at 50%. I have added powertop debug log for clarification.

The battery reports a discharge rate of 26.0 W
The energy consumed was 0.00 J
The estimated remaining time is 0 hours, 52 minutes

Summary: 145.3 wakeups/second,  0.0 GPU ops/seconds, 0.0 VFS ops/sec and 4.4% CPU use

Power est.              Usage       Events/s    Category       Description
  23.4 W      1.9 pkts/s                Device         Network interface: wlo1 (rtw_pci)
  5.68 W     8720%                      Device         Display backlight
  131 mW     10.1 ms/s       2.0        Process        [PID 28124] volume
 79.4 mW      6.1 ms/s       1.0        Process        [PID 28101] powertop -t 60
 57.5 mW      4.4 ms/s       2.0        Process        [PID 28119] dwmblocks
 32.7 mW      2.5 ms/s       3.9        Process        [PID 28122] sh
 28.6 mW      2.2 ms/s      0.00        Process        [PID 28123] sh
 23.1 mW      1.8 ms/s       2.0        Process        [PID 28123] dwmblocks
 19.8 mW      1.5 ms/s       2.0        Process        [PID 28119] sh
 19.5 mW      1.4 ms/s       5.9        Process        [PID 28124] pamixer
 18.3 mW      1.4 ms/s       3.9        Process        [PID 1242] /usr/bin/pulseaudio --daemoni
 17.7 mW      1.3 ms/s       2.9        Process        [PID 26211] st
 16.9 mW      1.2 ms/s       5.9        Process        [PID 1171] /usr/lib/Xorg -nolisten tcp :
 12.3 mW      0.9 ms/s       2.0        Process        [PID 28121] sh
 10.9 mW      0.8 ms/s       1.0        Process        [PID 28123] volume
 10.1 mW      0.8 ms/s       2.0        Interrupt      [9] RCU(softirq)
 9.46 mW    699.7 µs/s       2.9        Process        [PID 28117] acpi
 9.01 mW    664.6 µs/s       2.9        Process        [PID 28120] sh
 8.97 mW    366.2 µs/s      28.5        Timer          tick_sched_timer
 8.69 mW    662.6 µs/s       1.0        Process        [PID 28116] sh
 8.53 mW    513.9 µs/s      12.8        Process        [PID 438] [irq/82-rtwpci]
 6.16 mW    455.3 µs/s       2.0        Process        [PID 28118] awk
 6.09 mW    449.5 µs/s       2.0        Process        [PID 28125] volume
 5.68 mW    429.5 µs/s       1.0        Process        [PID 20470] /usr/lib/brave-bin/brave --t
 4.99 mW    330.3 µs/s       4.9        Interrupt      [7] sched(softirq)
 4.18 mW    164.9 µs/s      13.7        Process        [PID 11] [rcu_preempt]
 3.45 mW    244.6 µs/s       2.0        Interrupt      [6] tasklet(softirq)
 3.02 mW    211.7 µs/s       2.0        Interrupt      [1] timer(softirq)
 2.92 mW    135.2 µs/s       7.9        kWork          ieee80211_iface_work
 2.84 mW    220.3 µs/s      0.00        Process        [PID 1196] dwmblocks
 2.74 mW    212.5 µs/s      0.00        Process        [PID 12209] [kworker/6:2]
 2.64 mW    102.6 µs/s       8.8        kWork          psi_avgs_work
 2.30 mW    155.5 µs/s       2.0        Interrupt      [9] acpi
 2.28 mW    177.0 µs/s      0.00        Timer          delayed_work_timer_fn
 1.98 mW    153.5 µs/s      0.00        kWork          rtw_watch_dog_work

Last edited by Gtlsgamr (2020-08-28 12:59:23)

Offline

#2 2020-08-27 20:08:31

fistrosan
Member
Registered: 2020-04-01
Posts: 171

Re: [SOLVED] High power usage by network device.

I would not trust much those percentages.

Can you post the output of cat /sys/class/power_supply/BAT0/energy_full & cat /sys/class/power_supply/BAT0/power_now while running on battery under normal usage ?

Having said that, it seems to me (assuming powertop is right) that your real problem is your network. It is responsible for more than 90 % of your power usage (23.4 W out of 26.0 W)

Edit: I am thinking that perhaps you should post the output of the commands above while the network in ON and while it is OFF so we can figure out if that the main reason your battery is being depleted so fast. This is quite an old-fashion method. You could also install tlp and monitor the power usage under different loads using tlp-stat -b.

Last edited by fistrosan (2020-08-27 20:52:00)

Offline

#3 2020-08-28 10:06:16

Gtlsgamr
Member
Registered: 2020-08-27
Posts: 8

Re: [SOLVED] High power usage by network device.

Hey, so the outputs are here with:
WIFI ON

[~] cat /sys/class/power_supply/BAT0/energy_full
49156000
[~] cat /sys/class/power_supply/BAT0/power_now
30492000

WIFI OFF

[~] cat /sys/class/power_supply/BAT0/energy_full
49156000
[~] cat /sys/class/power_supply/BAT0/power_now
28921000

You are right, it looks like its the wifi thats eating up the power. But even then I dont think wifi should use that much power.

Offline

#4 2020-08-28 10:14:15

fistrosan
Member
Registered: 2020-04-01
Posts: 171

Re: [SOLVED] High power usage by network device.

But the difference is not that much. Can you repeat the same exercise but with: a) WIFI OFF + Display 100 %; b) WIFI OFF  + Display 50 % ?

Also, your battery does not seem to be a very high capacity one. The output of cat /sys/class/power_supply/BAT0/energy_full in my Lenovo X1 is 69870000 (40% higher than yours).

Is yours a brand new laptop ? If it is old (or of the battery is in bad condition) there is probably a big difference between the output of your: cat /sys/class/power_supply/BAT0/energy_full and the output of cat /sys/class/power_supply/BAT0/energy_full_design

If energy_full_design is twice or more than energy_full then it probably means your battery is in bad shape.

Last edited by fistrosan (2020-08-28 10:22:28)

Offline

#5 2020-08-28 10:39:09

Gtlsgamr
Member
Registered: 2020-08-27
Posts: 8

Re: [SOLVED] High power usage by network device.

Its a new laptop and the battery is supposed to be not very large anyway, but it seems very low for some reason.
Here is WIFI OFF + display 100 %

--- TLP 1.3.1 --------------------------------------------

+++ Battery Features: Charge Thresholds and Recalibrate
natacpi    = inactive (laptop not supported)
tpacpi-bat = inactive (laptop not supported)
tp-smapi   = inactive (laptop not supported)

+++ Battery Status: BAT0
/sys/class/power_supply/BAT0/manufacturer                   = Hewlett-Packard
/sys/class/power_supply/BAT0/model_name                     = Primary
/sys/class/power_supply/BAT0/cycle_count                    =    442
/sys/class/power_supply/BAT0/energy_full_design             =  49156 [mWh]
/sys/class/power_supply/BAT0/energy_full                    =  49156 [mWh]
/sys/class/power_supply/BAT0/energy_now                     =  24024 [mWh]
/sys/class/power_supply/BAT0/power_now                      =  33645 [mW]
/sys/class/power_supply/BAT0/status                         = Discharging

Charge                                                      =   48.9 [%]
Capacity                                                    =  100.0 [%]

and here it is at WIFI OFF + brightness 50%

--- TLP 1.3.1 --------------------------------------------

+++ Battery Features: Charge Thresholds and Recalibrate
natacpi    = inactive (laptop not supported)
tpacpi-bat = inactive (laptop not supported)
tp-smapi   = inactive (laptop not supported)

+++ Battery Status: BAT0
/sys/class/power_supply/BAT0/manufacturer                   = Hewlett-Packard
/sys/class/power_supply/BAT0/model_name                     = Primary
/sys/class/power_supply/BAT0/cycle_count                    =    442
/sys/class/power_supply/BAT0/energy_full_design             =  49156 [mWh]
/sys/class/power_supply/BAT0/energy_full                    =  49156 [mWh]
/sys/class/power_supply/BAT0/energy_now                     =  22915 [mWh]
/sys/class/power_supply/BAT0/power_now                      =  32259 [mW]
/sys/class/power_supply/BAT0/status                         = Discharging

Charge                                                      =   46.6 [%]
Capacity                                                    =  100.0 [%]

Offline

#6 2020-08-28 10:54:16

fistrosan
Member
Registered: 2020-04-01
Posts: 171

Re: [SOLVED] High power usage by network device.

Oh nice that you are using tlp-stat -b now. Much more useful information and much more trustworthy than powertop (imho).

So, as you can see WIFI off + Display 100 % your power consumption is 33645 mW. Your energy full is 49156 Wh, which means that like that you will have a 1.46 hours of battery left. With brightness at 50 % you go to 1.52 hours, the display is clearly NOT your problem. You could repeat with WIFI ON and see if your battery life drops significantly.

A few extra questions: 1) have you enabled tlp already ? systemctl start --now tlp ... 2) try to edit /etc/tlp.conf and set new parameters to decrease your power consumption while in battery (examples are: CPU_ENERGY_PERF_POLICY_ON_BAT="power", SCHED_POWERSAVE_ON_BAT="1", DISK_SPINDOWN_TIMEOUT_ON_BAT,  DISK_APM_LEVEL_ON_BAT, etc). Those will slow down the cpu, read/write operations, etc. while on battery. 3) What graphics card are you using in your new laptop ? If you have a dual set-up (eg. intel+nvidia) make sure you switch off nvidia and use only Intel while on battery. This can dramatically increase your battery life.

Offline

#7 2020-08-28 12:14:52

Gtlsgamr
Member
Registered: 2020-08-27
Posts: 8

Re: [SOLVED] High power usage by network device.

I have added those settings as of now. Regarding the dual setup, it's very tricky. I have AMD+Nvidia so I cant use bumblebee. I searched the wiki but couldn't find anything for that setup. Do you have any idea how to make that work?

Offline

#8 2020-08-28 12:45:36

fistrosan
Member
Registered: 2020-04-01
Posts: 171

Re: [SOLVED] High power usage by network device.

And what is your current power_now according to tlp-stat with the new setup and after enabling the service (reboot if needed) ? has it decreased ?

Anyhow, we are at 1.5 hours battery left with a relatively small battery (and under Linux!!) so I think that is not too unreasonable.

You should probably rename the title of the thread because it is clear your problem is not the backlight.

About GPUs: I myself use optimus-manager but I get the feeling that this is for intel+nvidia. Maybe it is a good idea to start a new thread on that subject so you can have a more targeted response by the gurus on the forum.

Offline

#9 2020-08-28 12:57:01

Gtlsgamr
Member
Registered: 2020-08-27
Posts: 8

Re: [SOLVED] High power usage by network device.

Yo! The power_now shows at 15 W now! It has halved! I am marking this as solved, if there is such a thing. I will change the title and I think I am gonna make a new thread about the GPU issue.

Offline

Board footer

Powered by FluxBB