You are not logged in.
Pages: 1
Hi all,
I'm a little confused on my usage of laptop-mode-tools. There is a lot of documentation out there but a lot of it seems to be rather outdated, so I have a couple of (hopefully quite simple) questions:
1) The new Intel p-state drivers mean that I shouldn't use CPU scaling in laptop-mode-tools, correct? I have an Ivy Bridge CPU. My output for 'cpupower frequency-info' is as follows:
analyzing CPU 0:
driver: intel_pstate
CPUs which run at the same hardware frequency: 0
CPUs which need to have their frequency coordinated by software: 0
maximum transition latency: 0.97 ms.
hardware limits: 1.20 GHz - 3.10 GHz
available cpufreq governors: performance, powersave
current policy: frequency should be within 1.20 GHz and 3.10 GHz.
The governor "powersave" may decide which speed to use
within this range.
current CPU frequency is 2.15 GHz (asserted by call to hardware).
boost state support:
Supported: no
Active: no
25500 MHz max turbo 4 active cores
25500 MHz max turbo 3 active cores
25500 MHz max turbo 2 active cores
25500 MHz max turbo 1 active cores2) How do I know if laptop-mode-tools is actually running? On the creator's website he suggests running 'cat /proc/sys/vm/laptop_mode', and if the output is 0, LM isn't running. I'm getting zero, is this method still relevant? If so, how to I start it? I've enabled the module at boot in the usual way (systemctl).
3) Is laptop-mode-tools still really necessary or does the kernel do most of this by itself now? I'm getting a fair bit less battery life on Arch than on my Win7 install (~4-5 hours vs. ~7-8 hours) despite having disabled my discrete GPU. Are there any tools that have replaced laptop-mode-tools to an extent that I should look into?
Apologies if these queries seem overly simple but I just wanted to ensure my information was up-to-date.
Thanks!
Offline
to 2) /proc/sys/vm/laptop_mode is the kernel implementation of the power saving tool laptop_mode_tools was initially based on (to manipulate hard disk spin down and wake up behavior). a nonzero value in that file does not necessarily mean that laptop_mode_tools is running.
Instead check for the service via systemctl:
systemctl list-units | grep laptop-mode(and if it isn't already, enable/start it)
to 3) LMT is still very relevant. Make sure you check all the options, because there are loads of them.
to 1) I've been out of touch for a while but i think it is still considered best-practice to use the ondemand governor.
no place like /home
github
Offline
to 1) I've been out of touch for a while but i think it is still considered best-practice to use the ondemand governor.
Powersave & performance is where it's at. Newer Intel CPUs don't even support ondemand anymore (like OP's, look at the post again).
Last edited by socials (2013-11-16 09:44:29)
Offline
Take a look at TLP https://wiki.archlinux.org/index.php/TLP
I recommend it over Laptop-mode-tools and I get the same battery life as on Windows with my Thinkpad X1C.
Offline
Take a look at TLP https://wiki.archlinux.org/index.php/TLP
I recommend it over Laptop-mode-tools and I get the same battery life as on Windows with my Thinkpad X1C.
I've tried laptop-mode-tools, TLP, powerdown and I honestly can't say I notice any difference between them. They all do the exact same things anyway. Only thing I can say is that TLP and powerdown are easier to configure.
Last edited by socials (2013-11-17 19:22:54)
Offline
I don't use any of this at all. I just have everything set to be powersaving all the time (powertop reports all "good"). I tried using these tools for a while, but since my machine is fairly powerful (IVB i5-3210m) for my basic needs, I couldn't ever really tell much of a difference between the plugged vs unplugged state. It may be good if you have some heavier performance requirements, but to me, it seems like the average user does not need such things.
Offline
I don't use any of this at all. I just have everything set to be powersaving all the time (powertop reports all "good"). I tried using these tools for a while, but since my machine is fairly powerful (IVB i5-3210m) for my basic needs, I couldn't ever really tell much of a difference between the plugged vs unplugged state. It may be good if you have some heavier performance requirements, but to me, it seems like the average user does not need such things.
Yes, but you won't get full performance doing that.
I just feel that gimping your computer like that in favor for power saving seems wrong. Even if I don't use those resources, I'd like to know that they are available for me when I need them. That's why I've set up that if running on AC, everything is in high-performance mode. While running on battery, everything is toned down so I could get maximum battery life.
Offline
Nor does a 0 in that file mean the service is not active. It does mean laptop_mode is not enabled but, depending on your config, that could just mean you are currently running on AC.
I just realised why I'm still getting errors about this: You should disable the cpufreq.conf handling for laptop-mode-tools since you have a cpu which uses the pstate stuff (and so doesn't support the cpufreq module laptop-mode-tools expects).
To get the most out of laptop-mode-tools, you have to work through the configuration consistently and decide where you want to compromise. You can also use powertop to identify stuff that still isn't optimised although I've never got around to figuring out how to enable the tweaks it recommends permanently.
One easy way to tell if it is working is to set different brightness levels for AC and battery in the config and then pull the AC and see if the brightness is adjusted correctly. That won't tell you if everything works as it should, but it will tell you laptop-mode-tools is active (provided you have disabled brightness adjustment in any DE you use).
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
To get the most out of laptop-mode-tools, you have to work through the configuration consistently and decide where you want to compromise. You can also use powertop to identify stuff that still isn't optimised although I've never got around to figuring out how to enable the tweaks it recommends permanently.
Use powertop's html output to get some simple commands to make thing power efficient. By using the clues it gives as to what files need to be changed, you can use udev rules, modprobe.d, sysctl.d, and possibly tmpfiles.d to make these things set themselves on boot. Of course, if you are using laptop-mode-tools, most of this stuff should be set/unset when you plug/unplug. If it doesn't cover everything, you could probably use acpid (which should already be in use to indicate plug/unplug) to change these unhandled parameters as necessary.
Offline
Thanks. Yes. I really did mean I hadn't got around to figuring it out rather than that I didn't know how to figure it out. At least, I realise I might fail to figure it out when I try but I do know that's how to try. (I think probably because you told me to do it that way and I just haven't got around to taking your advice yet
.)
Last edited by cfr (2013-11-18 01:57:02)
CLI Paste | How To Ask Questions
Arch Linux | x86_64 | GPT | EFI boot | refind | stub loader | systemd | LVM2 on LUKS
Lenovo x270 | Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz | Intel Wireless 8265/8275 | US keyboard w/ Euro | 512G NVMe INTEL SSDPEKKF512G7L
Offline
Pages: 1