Power Management Manjaro
Overview
The following shows how you can optimize your computer using Powertop to generate runing recommendations and apply those optimizations at boot using an rc-local service.
Powertop
Install powertop
sudo pacman -S powertop
Run powertop report (on battery power)
sudo powertop -r
After a few seconds, a file called powertop.html is created.
Open the powertop.html file in your browser and inspect the Tuning tab for tuning recommendations.
Configure rc-local service
Create rc.local file in
/etc
directory with the following content#!/bin/sh -e echo "Hello World" # Insert powertop optimization scripts here. exit 0
Create rc-local.service file in
/etc/systemd/system
directory with the following content# This file is part of systemd. # # systemd is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. [Unit] Description=/etc/rc.local Compatibility ConditionPathExists=/etc/rc.local [Service] Type=oneshot ExecStart=/etc/rc.local TimeoutSec=0 StandardOutput=tty RemainAfterExit=yes SysVStartPriority=99 [Install] WantedBy=multi-user.target
Enable and start rc-local service
sudo systemctl enable rc-local sudo systemctl start rc-local
Confirm that the service has successfully started
sudo systemctl status rc-local