xref: /freebsd/usr.sbin/powerd/powerd.8 (revision 98b486dc7ae5cb865fb38621a1ac7dca7fefa515)
15883360bSNate Lawson.\" Copyright (c) 2005 Nate Lawson
25883360bSNate Lawson.\" All rights reserved.
35883360bSNate Lawson.\"
45883360bSNate Lawson.\" Redistribution and use in source and binary forms, with or without
55883360bSNate Lawson.\" modification, are permitted provided that the following conditions
65883360bSNate Lawson.\" are met:
75883360bSNate Lawson.\" 1. Redistributions of source code must retain the above copyright
85883360bSNate Lawson.\"    notice, this list of conditions and the following disclaimer.
95883360bSNate Lawson.\" 2. Redistributions in binary form must reproduce the above copyright
105883360bSNate Lawson.\"    notice, this list of conditions and the following disclaimer in the
115883360bSNate Lawson.\"    documentation and/or other materials provided with the distribution.
125883360bSNate Lawson.\"
135883360bSNate Lawson.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
145883360bSNate Lawson.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
155883360bSNate Lawson.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
165883360bSNate Lawson.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
175883360bSNate Lawson.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
185883360bSNate Lawson.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
195883360bSNate Lawson.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
205883360bSNate Lawson.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
215883360bSNate Lawson.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
225883360bSNate Lawson.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
235883360bSNate Lawson.\" SUCH DAMAGE.
245883360bSNate Lawson.\"
255883360bSNate Lawson.\" $FreeBSD$
265883360bSNate Lawson.\"
27*98b486dcSMateusz Piotrowski.Dd March 3, 2020
285883360bSNate Lawson.Dt POWERD 8
295883360bSNate Lawson.Os
305883360bSNate Lawson.Sh NAME
315883360bSNate Lawson.Nm powerd
3283c94dadSRuslan Ermilov.Nd "system power control utility"
335883360bSNate Lawson.Sh SYNOPSIS
345883360bSNate Lawson.Nm
3583c94dadSRuslan Ermilov.Op Fl a Ar mode
3683c94dadSRuslan Ermilov.Op Fl b Ar mode
3783c94dadSRuslan Ermilov.Op Fl i Ar percent
38cf2280acSRebecca Cran.Op Fl M Ar freq
39*98b486dcSMateusz Piotrowski.Op Fl m Ar freq
40d9138286SColin Percival.Op Fl N
4183c94dadSRuslan Ermilov.Op Fl n Ar mode
4284148fd1SPawel Jakub Dawidek.Op Fl P Ar pidfile
43*98b486dcSMateusz Piotrowski.Op Fl p Ar ival
4483c94dadSRuslan Ermilov.Op Fl r Ar percent
455c81ba5aSAndriy Voskoboinyk.Op Fl s Ar source
465883360bSNate Lawson.Op Fl v
475883360bSNate Lawson.Sh DESCRIPTION
485883360bSNate LawsonThe
495883360bSNate Lawson.Nm
505883360bSNate Lawsonutility monitors the system state and sets various power control options
515883360bSNate Lawsonaccordingly.
5227f90bebSWarren BlockIt offers power-saving modes that can be
5327f90bebSWarren Blockindividually selected for operation on AC power or batteries.
54*98b486dcSMateusz Piotrowski.Bl -tag -width "hiadaptive"
55*98b486dcSMateusz Piotrowski.It Cm maximum
5627f90bebSWarren BlockChoose the highest performance values.
5727f90bebSWarren BlockMay be abbreviated as
58*98b486dcSMateusz Piotrowski.Cm max .
59*98b486dcSMateusz Piotrowski.It Cm minimum
6027f90bebSWarren BlockChoose the lowest performance values to get the most power savings.
6127f90bebSWarren BlockMay be abbreviated as
62*98b486dcSMateusz Piotrowski.Cm min .
63*98b486dcSMateusz Piotrowski.It Cm adaptive
6427f90bebSWarren BlockAttempt to strike a balance by degrading performance when the system
6527f90bebSWarren Blockappears idle and increasing it when the system is busy.
665883360bSNate LawsonIt offers a good balance between a small performance loss for greatly
675883360bSNate Lawsonincreased power savings.
6827f90bebSWarren BlockMay be abbreviated as
69*98b486dcSMateusz Piotrowski.Cm adp .
70*98b486dcSMateusz Piotrowski.It Cm hiadaptive
7127f90bebSWarren BlockLike
72*98b486dcSMateusz Piotrowski.Cm adaptive
7327f90bebSWarren Blockmode, but tuned for systems where performance and interactivity are
7427f90bebSWarren Blockmore important than power consumption.
7527f90bebSWarren BlockIt increases frequency faster, reduces frequency less aggressively, and
76484b7a09SGavin Atkinsonwill maintain full frequency for longer.
7727f90bebSWarren BlockMay be abbreviated as
78*98b486dcSMateusz Piotrowski.Cm hadp .
7927f90bebSWarren Block.El
805883360bSNate Lawson.Pp
8127f90bebSWarren BlockThe default mode is
82*98b486dcSMateusz Piotrowski.Cm adaptive
8327f90bebSWarren Blockfor battery power and
84*98b486dcSMateusz Piotrowski.Cm hiadaptive
8527f90bebSWarren Blockfor the rest.
8627f90bebSWarren Block.Pp
875883360bSNate Lawson.Nm
8827f90bebSWarren Blockrecognizes these runtime options:
89*98b486dcSMateusz Piotrowski.Bl -tag -width "-r percent"
905883360bSNate Lawson.It Fl a Ar mode
915883360bSNate LawsonSelects the
925883360bSNate Lawson.Ar mode
935883360bSNate Lawsonto use while on AC power.
945883360bSNate Lawson.It Fl b Ar mode
955883360bSNate LawsonSelects the
965883360bSNate Lawson.Ar mode
975883360bSNate Lawsonto use while on battery power.
985883360bSNate Lawson.It Fl i Ar percent
99dbd31977SAlexander MotinSpecifies the CPU load percent level when adaptive
1005883360bSNate Lawsonmode should begin to degrade performance to save power.
101dbd31977SAlexander MotinThe default is 50% or lower.
102cf2280acSRebecca Cran.It Fl M Ar freq
103cf2280acSRebecca CranSpecifies the maximum frequency to throttle up to.
104*98b486dcSMateusz Piotrowski.It Fl m Ar freq
105*98b486dcSMateusz PiotrowskiSpecifies the minimum frequency to throttle down to.
106d9138286SColin Percival.It Fl N
107d9138286SColin PercivalTreat "nice" time as idle for the purpose of load calculation;
108*98b486dcSMateusz Piotrowskii.e., do not increase the CPU frequency if the CPU is only busy
109d9138286SColin Percivalwith "nice" processes.
1105883360bSNate Lawson.It Fl n Ar mode
1115883360bSNate LawsonSelects the
1125883360bSNate Lawson.Ar mode
1135883360bSNate Lawsonto use normally when the AC line state is unknown.
114*98b486dcSMateusz Piotrowski.It Fl P Ar pidfile
115*98b486dcSMateusz PiotrowskiSpecifies an alternative file in which the process ID should be stored.
1165883360bSNate Lawson.It Fl p Ar ival
1175883360bSNate LawsonSpecifies a different polling interval (in milliseconds) for AC line state
1185883360bSNate Lawsonand system idle levels.
119dbd31977SAlexander MotinThe default is 250 ms.
1205883360bSNate Lawson.It Fl r Ar percent
121dbd31977SAlexander MotinSpecifies the CPU load percent level where adaptive
1225883360bSNate Lawsonmode should consider the CPU running and increase performance.
1235d8e279eSTom RhodesThe default is 75% or higher.
1245c81ba5aSAndriy Voskoboinyk.It Fl s Ar source
1255c81ba5aSAndriy VoskoboinykEnforces method for AC line state refresh; by default, it is chosen
1265c81ba5aSAndriy Voskoboinykautomatically.
1275c81ba5aSAndriy VoskoboinykThe set of valid methods is
1285c81ba5aSAndriy Voskoboinyk.Cm sysctl , devd
1295c81ba5aSAndriy Voskoboinykand
1305c81ba5aSAndriy Voskoboinyk.Cm apm
1315c81ba5aSAndriy Voskoboinyk(i386 only).
1325883360bSNate Lawson.It Fl v
1335883360bSNate LawsonVerbose mode.
1345883360bSNate LawsonMessages about power changes will be printed to stdout and
1355883360bSNate Lawson.Nm
1365883360bSNate Lawsonwill operate in the foreground.
1375883360bSNate Lawson.El
138*98b486dcSMateusz Piotrowski.Sh FILES
139*98b486dcSMateusz Piotrowski.Bl -tag -width "/var/run/powerd.pid"
140*98b486dcSMateusz Piotrowski.It Pa /var/run/powerd.pid
141*98b486dcSMateusz PiotrowskiThe default PID file.
142*98b486dcSMateusz Piotrowski.El
1435883360bSNate Lawson.Sh SEE ALSO
1445883360bSNate Lawson.Xr acpi 4 ,
1455883360bSNate Lawson.Xr apm 4 ,
1465883360bSNate Lawson.Xr cpufreq 4
1475883360bSNate Lawson.Sh HISTORY
1485883360bSNate LawsonThe
1495883360bSNate Lawson.Nm
1505883360bSNate Lawsonutility first appeared in
15119797b22SJoel Dahl.Fx 6.0 .
1525883360bSNate Lawson.Sh AUTHORS
15383c94dadSRuslan Ermilov.An -nosplit
1545883360bSNate Lawson.An Colin Percival
1555883360bSNate Lawsonfirst wrote
15683c94dadSRuslan Ermilov.Nm estctrl ,
1575883360bSNate Lawsonthe utility that
1585883360bSNate Lawson.Nm
1595883360bSNate Lawsonis based on.
1605883360bSNate Lawson.An Nate Lawson
1615883360bSNate Lawsonthen updated it for
1625883360bSNate Lawson.Xr cpufreq 4 ,
1637f2f0628SChristian Bruefferadded features, and wrote this manual page.
1645883360bSNate Lawson.Sh BUGS
1655883360bSNate LawsonThe
1665883360bSNate Lawson.Nm
1675883360bSNate Lawsonutility should also power down idle disks and other components besides the CPU.
1685883360bSNate Lawson.Pp
1695883360bSNate LawsonIf
1705883360bSNate Lawson.Nm
17183c94dadSRuslan Ermilovis used with
17283c94dadSRuslan Ermilov.Pa power_profile ,
17383c94dadSRuslan Ermilovthey may override each other.
1745883360bSNate Lawson.Pp
17583c94dadSRuslan ErmilovThe
1765883360bSNate Lawson.Nm
17783c94dadSRuslan Ermilovutility
1785883360bSNate Lawsonshould probably use the
1795883360bSNate Lawson.Xr devctl 4
1805883360bSNate Lawsoninterface instead of polling for AC line state.
181