Summary: suspecting battery drain and (maybe) powertop malfunction.
Ever since I updated to the 19.X series (currently 19.10) I've experienced a very sharp decay in the battery life that I cannot pinpoint (Probably unnatural battery drain on a Dell XPS 13). To have an idea, I used to get around 12-10h of mild using and currently have 2h30 top. I have activated the TLP and the powertop auto-tune flag, I use only intel drivers and have deactivated Bluetooth for the testing (Ubuntu 18.04 battery life). I have also carefully check that I'm not in fact running Nvidia drivers... Reducing the screen brightness to the minimum and restarting my machine, at 100% I can get around 10h of an expected lifetime (~8W reported from powertop). Seems good right? Well... To have an idea, I used to get an estimated time around ~9h of MILD use and ~14h for all the settings to the minimum. Currently, I have 2h30 top in mild use. Part of this is the shitty battery capacity, that after 1.5y is at already at 68%.
The funny part starts where I try to find the culprit and I can't... Below three different situations. Mild use + Skype (background), Mild use and Mild use with wifi off. Here are a couple of points:
- It is clear that keeping skype (or using any other app) spikes the consumption but 32W for half a CPU core???? This seems abusive.
- The total CPU usage should not account for the high battery drain.
- A big part of the usage comes from the backlight but I'm not sure if the reported values are correct
- I have read online multiple comments to discarge the powertop readings however, the total consumption seems to be compatible with the real lifetime.
Can you help me find the hidding culprit?
P.S. I consider "Mild use" to have Firefox open and another 3 programs in the background. Screen brightness to 45%.
######### Mild use + Skype ############
PowerTOP v2.9 Overview Idle stats Frequency stats Device stats Tunables
The battery reports a discharge rate of 33.1 W
The power consumed was 0.00 J
The estimated remaining time is 0 hours, 38 minutes
Summary: 14022,1 wakeups/second, 0,0 GPU ops/seconds, 0,0 VFS ops/sec and 158,1% CPU use
Power est. Usage Events/s Category Description
13.8 W 43,6% Device Display backlight
6.57 mW 8,5 pkts/s Device Network interface: wlp2s0 (ath10k_pci)
0 mW 453,8 ms/s 1416,3 Interrupt [9] acpi
0 mW 425,9 ms/s 2031,7 Process [PID 23358] /usr/share/skypeforlinux/skypeforlinux --ty
0 mW 179,4 ms/s 20,4 Process [PID 3605] /usr/sbin/cups-browsed
0 mW 106,9 ms/s 75,7 Process [PID 5477] /usr/bin/gnome-shell
0 mW 96,9 ms/s 472,7 Process [PID 177] [kswapd0]
0 mW 92,9 ms/s 64,1 Process [PID 2066] /usr/lib/x86_64-linux-gnu/webkit2gtk-4.0/Web
0 mW 74,2 ms/s 27,2 Process [PID 3604] /usr/sbin/cupsd -l
0 mW 21,4 ms/s 1018,3 Process [PID 18700] /usr/share/skypeforlinux/skypeforlinux --ty
0 mW 12,0 ms/s 176,7 Process [PID 32697] stremio
0 mW 11,9 ms/s 5,8 Process [PID 5250] /usr/lib/xorg/Xorg vt2 -displayfd 3 -auth /r
0 mW 9,7 ms/s 2092,9 Interrupt [138] nvme0q6
0 mW 5,8 ms/s 62,1 Process [PID 25408] powertop
0 mW 5,4 ms/s 1,9 Process [PID 7574] /usr/share/mailspring/resources/app.asar.unp
0 mW 5,4 ms/s 1529,9 Interrupt [139] nvme0q7
0 mW 5,3 ms/s 13,6 Process [PID 7469] Mailspring default
0 mW 4,6 ms/s 0,00 Interrupt [9] RCU(softirq)
0 mW 4,5 ms/s 52,4 Interrupt [7] sched(softirq)
top - 23:47:25 up 9 days, 11:44, 2 users, load average: 2,15, 2,46, 2,57
Tasks: 360 total, 1 running, 358 sleeping, 0 stopped, 1 zombie
%Cpu(s): 4,6 us, 7,4 sy, 0,0 ni, 85,2 id, 0,0 wa, 0,0 hi, 2,8 si, 0,0 st
MiB Mem : 15864,7 total, 1570,7 free, 10760,5 used, 3533,5 buff/cache
MiB Swap: 20480,0 total, 19608,4 free, 871,6 used. 3889,5 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
18661 joaosf 20 0 5349912 442928 130812 S 52,3 2,7 119:19.07 skypeforlinux
3605 root 20 0 187308 16336 9168 S 16,3 0,1 51:57.78 cups-browsed
2066 joaosf 20 0 101,7g 380852 50152 S 9,3 2,3 412:09.72 WebKitWebProces
3604 root 20 0 45636 24988 6648 S 7,0 0,2 21:56.28 cupsd
5477 joaosf 20 0 5219240 1,7g 213996 S 5,0 11,3 259:06.34 gnome-shell
5250 joaosf 20 0 668384 311116 237308 S 3,0 1,9 131:33.21 Xorg
291 root -51 0 0 0 0 S 1,7 0,0 11:09.92 irq/51-DLL07BE:
310 joaosf 20 0 1858892 279992 155256 S 1,7 1,7 29:04.56 QtWebEngineProc
32697 joaosf 20 0 3825848 206192 60948 S 1,7 1,3 19:01.27 stremio
25377 joaosf 20 0 886708 48504 35608 S 1,3 0,3 0:00.89 gnome-terminal-
8546 joaosf 20 0 3568652 303328 110644 S 1,0 1,9 51:06.63 Web Content
2921 joaosf 24 4 959032 97088 104 S 0,7 0,6 9:34.57 WolframKernel
11 root 20 0 0 0 0 I 0,3 0,0 4:29.10 rcu_sched
2490 joaosf 20 0 1177004 93892 676 S 0,3 0,6 12:11.55 WolframKernel
######### Mild use ############
The battery reports a discharge rate of 14.7 W
The power consumed was 275 J
The estimated remaining time is 1 hours, 25 minutes
Summary: 1834,2 wakeups/second, 0,0 GPU ops/seconds, 0,0 VFS ops/sec and 36,2% CPU use
Power est. Usage Events/s Category Description
7.83 W 43,6% Device Display backlight
128 mW 5,2 ms/s 397,1 Timer tick_sched_timer
63.8 mW 1,9 ms/s 198,2 Interrupt [17] i2c_designware.1
47.0 mW 1,0 ms/s 146,0 Interrupt [136] nvme0q4
25.7 mW 8,8 ms/s 77,3 Timer hrtimer_wakeup
23.3 mW 236,5 µs/s 72,5 Interrupt [135] nvme0q3
22.2 mW 1,6 ms/s 68,7 Process [PID 291] [irq/51-DLL07BE:]
22.1 mW 9,9 ms/s 65,7 Process [PID 177] [kswapd0]
22.0 mW 6,5 ms/s 66,4 Process [PID 32697] stremio
19.5 mW 49,3 ms/s 45,3 Process [PID 5477] /usr/bin/gnome-shell
16.3 mW 520,3 µs/s 50,6 Interrupt [138] nvme0q6
15.9 mW 0,7 ms/s 49,3 Process [PID 29948] /usr/lib/firefox/firefox -contentproc -chil
15.1 mW 55,0 ms/s 29,8 Process [PID 2066] /usr/lib/x86_64-linux-gnu/webkit2gtk-4.0/Web
12.7 mW 97,9 ms/s 9,0 Process [PID 3605] /usr/sbin/cups-browsed
11.7 mW 1,0 ms/s 36,1 Process [PID 2634] /usr/local/Wolfram/Mathematica/12.0/SystemFi
9.55 mW 0,7 ms/s 29,5 Process [PID 2927] /usr/local/Wolfram/Mathematica/12.0/SystemFi
9.25 mW 1,7 ms/s 28,3 Process [PID 5260] /usr/lib/xorg/Xorg vt2 -displayfd 3 -auth /r
8.39 mW 41,1 ms/s 13,3 Process [PID 3604] /usr/sbin/cupsd -l
8.18 mW 594,4 µs/s 25,3 Process [PID 2490] /usr/local/W
Tasks: 357 total, 1 running, 355 sleeping, 0 stopped, 1 zombie
%Cpu(s): 4,0 us, 1,3 sy, 0,0 ni, 94,2 id, 0,0 wa, 0,0 hi, 0,5 si, 0,0 st
MiB Mem : 15864,7 total, 2689,5 free, 10461,9 used, 2713,3 buff/cache
MiB Swap: 20480,0 total, 19587,1 free, 892,9 used. 4032,4 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
3605 root 20 0 187308 16116 8948 S 15,9 0,1 52:36.40 cups-browsed
2066 joaosf 20 0 101,7g 379700 49000 S 12,3 2,3 412:36.80 WebKitWebProces
3604 root 20 0 45636 24988 6648 S 7,3 0,2 22:13.21 cupsd
32697 joaosf 20 0 3825848 200392 55148 S 1,7 1,2 19:05.32 stremio
310 joaosf 20 0 1858892 278708 153972 S 1,3 1,7 29:07.25 QtWebEngineProc
5477 joaosf 20 0 5219092 1,7g 205208 S 1,0 11,2 259:27.21 gnome-shell
2924 joaosf 24 4 969916 105972 104 S 0,7 0,7 9:36.64 WolframKernel
3330 joaosf 20 0 851684 125892 19344 S 0,7 0,8 20:37.23 atom
8439 joaosf 20 0 4414144 560172 82436 S 0,7 3,4 121:22.28 firefox
8546 joaosf 20 0 3560036 286140 90876 S 0,7 1,8 51:08.26 Web Content
8662 joaosf 20 0 3647512 257052 106072 S 0,7 1,6 209:07.81 Web Content
17359 joaosf 20 0 1540156 57572 24468 S 0,7 0,4 0:29.75 nautilus
959 root 20 0 2528 80 24 S 0,3 0,0 0:14.03 acpid
2634 joaosf 20 0 2419132 259004 2412 S 0,3 1,6 16:14.58 WolframKernel
2918 joaosf 24 4 958996 97052 104 S 0,3 0,6 9:29.46 WolframKernel
2921 joaosf 24 4 959032 97088 104 S 0,3 0,6 9:35.05 WolframKernel
3382 joaosf 20 0 801660 172924 27956 S 0,3 1,1 2:18.30 atom
5250 joaosf 20 0 668156 310800 236992 S 0,3 1,9 131:40.39 Xorg
7469 joaosf 20 0 759928 171780 61492 S 0,3 1,1 1:35.38 Mailspring defa
25377 joaosf 20 0 886708 39084 26036 S 0,3 0,2 0:02.40 gnome-terminal-
26392 joaosf 20 0 12068 4056 3284 R 0,3 0,0 0:00.03 top
1 root 20 0 168400 7416 4196 S 0,0 0,0 7:05.72 systemd
2 root 20 0 0 0 0 S 0,0 0,0 0:00.12 kthreadd
######### Mild use - Wifi ############
The battery reports a discharge rate of 13.6 W
The power consumed was 306 J
The estimated remaining time is 0 hours, 38 minutes
Summary: 1792,5 wakeups/second, 0,0 GPU ops/seconds, 0,0 VFS ops/sec and 39,0% CPU use
Power est. Usage Events/s Category Description
10.1 W 43,6% Device Display backlight
96.6 mW 6,3 ms/s 497,9 Timer tick_sched_timer
23.7 mW 8,9 ms/s 122,0 Timer hrtimer_wakeup
23.4 mW 60,7 ms/s 120,4 Process [PID 8736] /usr/lib/firefox/firefox -contentproc -childID 6 -isF
19.9 mW 2,1 ms/s 102,8 Interrupt [17] i2c_designware.1
19.4 mW 5,8 ms/s 99,9 Process [PID 8451] /usr/lib/firefox/firefox -new-window
12.4 mW 1,8 ms/s 64,1 Process [PID 8507] /usr/lib/firefox/firefox -new-window
11.8 mW 16,3 ms/s 60,9 Process [PID 8439] /usr/lib/firefox/firefox -new-window
10.7 mW 6,6 ms/s 55,3 Process [PID 32697] stremio
6.56 mW 1,2 ms/s 33,8 Process [PID 2634] /usr/local/Wolfram/Mathematica/12.0/SystemFiles/Kerne
6.54 mW 1,5 ms/s 33,7 Process [PID 8784] /usr/lib/firefox/firefox -contentproc -childID 6 -isF
6.40 mW 2,2 ms/s 33,0 Process [PID 8508] /usr/lib/firefox/firefox -contentproc -parentBuildID
6.39 mW 28,7 ms/s 32,9 Process [PID 5477] /usr/bin/gnome-shell
5.79 mW 661,2 µs/s 29,8 Process [PID 29948] /usr/lib/firefox/firefox -contentproc -childID 3 -is
5.74 mW 667,2 µs/s 29,6 Process [PID 22742] /usr/lib/firefox/firefox -contentproc -childID 1 -is
5.03 mW 404,9 µs/s 25,9 Process [PID 2921] /usr/local/Wolfram/Mathematica/12.0/SystemFiles/Kerne
4.28 mW 663,5 µs/s 22,0 Process [PID 2490] /usr/local/Wolfram/Mathematica/12.0/SystemFiles/Kerne
4.26 mW 205,7 µs/s 21,9 Process [PID 11] [rcu_sched]
4.24 mW 688,1 µs/s 21,8 Process [PID 2924] /usr/local/Wolfram/M
Tasks: 366 total, 2 running, 363 sleeping, 0 stopped, 1 zombie
%Cpu(s): 9,1 us, 2,6 sy, 0,0 ni, 86,3 id, 0,0 wa, 0,0 hi, 2,0 si, 0,0 st
MiB Mem : 15864,7 total, 2496,7 free, 10495,4 used, 2872,6 buff/cache
MiB Swap: 20480,0 total, 19709,9 free, 770,1 used. 3895,3 avail Mem
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
3605 root 20 0 187308 16116 8948 S 22,8 0,1 53:10.83 cups-browsed
2066 joaosf 20 0 101,7g 379700 49000 R 16,9 2,3 413:07.81 WebKitWebProces
5477 joaosf 20 0 5219312 1,7g 206440 S 16,6 11,2 259:49.66 gnome-shell
3604 root 20 0 45636 24988 6648 S 11,6 0,2 22:30.04 cupsd
5250 joaosf 20 0 671908 314700 240892 S 6,6 1,9 131:49.39 Xorg
25377 joaosf 20 0 886708 39084 26036 S 3,0 0,2 0:02.83 gnome-terminal-
32697 joaosf 20 0 3825848 200392 55148 S 2,3 1,2 19:09.69 stremio
8439 joaosf 20 0 4416520 650656 85484 S 1,7 4,0 121:43.11 firefox
310 joaosf 20 0 1858892 278976 154360 S 1,3 1,7 29:10.04 QtWebEngineProc
6042 joaosf 20 0 9032 2836 2428 S 1,3 0,0 11:00.54 libinput-debug-
3330 joaosf 20 0 852708 126468 19692 S 1,0 0,8 20:38.90 atom
8546 joaosf 20 0 3560036 282488 90980 S 1,0 1,7 51:09.84 Web Content
8605 joaosf 20 0 3115348 412532 50196 S 1,0 2,5 9:06.44 WebExtensions
291 root -51 0 0 0 0 D 0,7 0,0 11:12.25 irq/51-DLL07BE:
809 systemd+ 20 0 21156 4540 3784 S 0,7 0,0 0:50.59 systemd-resolve
8736 joaosf 20 0 3382140 311712 132488 S 0,7 1,9 16:48.73 Web Content
386 root 20 0 21388 2528 1988 S 0,3 0,0 0:05.82 systemd-udevd
2030 joaosf 20 0 83,4g 136312 61880 S 0,3 0,8 16:58.04 epiphany
2490 joaosf 20 0 1177004 93888 672 S 0,3 0,6 12:12.80 WolframKernel
2634 joaosf 20 0 2419132 259004 2412 S 0,3 1,6 16:15.39 WolframKernel
2814 joaosf 20 0 4142416 231884 1884 S 0,3 1,4 8:24.82 java
2918 joaosf 24 4 958996 97052 104 S 0,3 0,6 9:29.91 WolframKernel
2921 joaosf 24 4 959032 97088 104 S 0,3 0,6 9:35.51 WolframKernel