pmset.1   [plain text]


.\"
.\" Copyright (c) 2002 Apple Computer, Inc.  All rights reserved.
.\"
.Dd August 19, 2002
.Dt PMSET 1
.Os Darwin
.Sh NAME
.Nm pmset
.Nd modify power management settings
.Sh SYNOPSIS
.Nm
.Op Fl a | b | c | u
.Op displaysleep Ar minutes
.Op disksleep Ar minutes
.Op sleep Ar minutes
.Op womp Ar 1/0
.Op ring Ar 1/0
.Op autorestart Ar 1/0
.Op dps Ar 1/0
.Op reduce Ar 1/0
.Op powerbutton Ar 1/0
.Op lidwake Ar 1/0
.Op acwake Ar 1/0
.Op lessbright Ar 1/0
.Op halfdim Ar 1/0
.Op sms Ar 1/0
.Op boot
.Nm
.Fl u
.Op haltlevel Ar percent
.Op haltafter Ar minutes
.Op haltremain Ar minutes
.Nm
.Fl g
.Op disk | live | cap | sched | ups | ps | pslog
.Nm
schedule
.Op cancel 
type date+time
.Op owner
.Nm
repeat cancel
.Nm
repeat type weekdays time
.\.Nm
.\.Op Fl a b c u
.\.Op dim
.\.Op spindown
.\.Op sleep
.\.Op womp
.\.Op ring
.\.Op autorestart
.\.Op acwake
.\.Op dps
.\.Op reduce
.Sh DESCRIPTION
.Nm
changes and reads power management settings such as idle sleep timing, wake on administrative access, automatic restart on power loss, etc.
.Sh SETTING
The
.Fl a,
.Fl b,
.Fl c,
.Fl u
flags determine whether the settings apply to battery (-b), charger (wall power) (-c), UPS (-u) or all (-a).
.Pp
Use a minutes argument of 0 to set the idle time to never.
.Pp
.Nm
must be run as root.
.Pp
The boot argument tells power management that system bootup is complete. Loginwindow handles this on a normal Mac OS X system.
.Sh GETTING
The
.Fl g
flag outputs the settings currently in use (same as
.Fl g
live
).
.br
.Fl g
disk
will display settings on disk.
.br
.Fl g
cap
will display which power management features the machine supports.
.br
.Fl g
sched 
will display scheduled startup/wake and shutdown/sleep events.
.br
.Fl g
ups
will display UPS emergency thresholds.
.br
.Fl g
ps
will display status of batteries and UPSs.
.br
.Fl g
pslog
will display an ongoing log of power source state.
.Sh ARGUMENTS
displaysleep - display sleep timer; replaces 'dim' argument in 10.4 (value in minutes)
.br
disksleep - disk spindown timer; replaces 'spindown' argument in 10.4 (value in minutes)
.br
sleep - system sleep timer (value in minutes)
.br
womp - wake on ethernet magic packet (value = 0/1)
.br
ring - wake on modem ring (value = 0/1)
.br
autorestart - automatic restart on power loss (value = 0/1)
.br
dps - dynamically change processor speed based on load (value = 0/1)
.br
reduce - reduce processor speed (value = 0/1)
.br
powerbutton - sleep the machine when power button is pressed (value = 0/1)
.br
lidwake - wake the machine when the laptop lid(or clamshell) is opened (value = 0/1)
.br
acwake - wake the machine when power source (AC/battery) is changed (value = 0/1)
.br
lessbright - slightly turn down display brightness when switching to this power source (value = 0/1)
.br
halfdim - display sleep will use an intermediate half-brightness state between full brightness and fully off  (value = 0/1)
.br
sms - use Sudden Motion Sensor to park disk heads on sudden changes in G force (value = 0/1)
.Sh UPS SPECIFIC ARGUMENTS
.br
UPS-specific arguments are only valid following the 
.Fl u 
option. UPS settings also have an on/off value. Use a -1 argument instead of percent 
or minutes to turn any of these settings off. If multiple halt conditions are specified,
the system will halt on the first condition that occurs in a low power situation.
.Pp
haltlevel - when draining UPS battery, battery level at which to trigger an emergency shutdown (value in %)
.br
haltafter - when draining UPS battery, trigger emergency shutdown after this long running on UPS power (value in minutes)
.br
haltremain - when draining UPS battery, trigger emergency shutdown when this much time remaining on UPS power is estimated (value in minutes)
.Sh SCHEDULED EVENT ARGUMENTS
.br
pmset allows you to schedule system sleep, shutdown, wakeup and/or power on. "schedule"
is for setting up one-time power events, and "repeat" is for setting up daily/weekly 
power on and power off events. Note that you may only have one pair of repeating events
scheduled - a "power on" event and a "power off" event.
.Pp
type - one of sleep, wake, poweron, shutdown, wakeorpoweron
.br
date/time - MM/dd/yy HH:mm:ss (in 24 hour format)
.br
time - HH:mm:ss
.br
weekdays - a subset of MTWRFSU ("M" and "MTWRF" are valid strings)
.br
owner - a string describing the person or program who is scheduling this one-time power event (optional)
.Sh OTHER ARGUMENTS
boot - tell the kernel that system boot is complete (normally LoginWindow does this). May be useful to Darwin users.
.br
force - tells PM to immediately activate these settings. Does not write them to disk, and the settings may easily be overwritten. Useful in circumstances where PM's configd plugin happens not to be running.
.br
dim - deprecated in 10.4 in favor of 'displaysleep'. 'dim' will continue to work.
.br
spindown - deprecated in 10.4 in favor of 'disksleep'. 'spindown' will continue to work.
.Sh EXAMPLES
.Nm
.Fl b
displaysleep 5
.Pp
.Nm
.Fl a
displaysleep 10 disksleep 10 sleep 30 womp 1
.Pp
.Nm
.Fl u
haltlevel 40
.Pp
.Nm
.Fl g
.Pp
.Nm
.Fl g
batt
.Pp
.Sh Files
All changes made through
.Nm
are saved in a persistent preferences file (per-system, not per-user) at
.Pa /Library/Preferences/SystemConfiguration/com.apple.PowerManagement.plist
.Pp
Scheduled power on/off events are stored separately in
.Pa /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist
.Pp
.Nm
modifies the same file that System Preferences Energy Saver modifies.