Pmset Manual

For Late 2013 until Mid 2015 iMacs (disabling hibernation) - sudo pmset -a hibernatemode 0 standby 0 autopoweroff 0 (for the models in late 2013, late 2014, mid 2015, alternatively, instead of standby 0, you can leave the standby at 1, and use for example standbydelayhigh 2592000 which equals to one month in seconds). Jan 20, 2017 Using pmset to change Power Management settings requires you to have elevated privileges, so must be prefaced by sudo. For example, to set a Mac so that it destroys its FileVault key when going to standy/hibernation mode, you should enter. Sudo pmset -a DestroyFVKeyOnStandby 1. Platform Requirements¶. Sentieon® Genomics software is designed to run on Linux and other POSIX-compatible platforms. For Linux systems, we recommended using the following Linux distributions or higher: RedHat/CentOS 6.5, Debian 7.7, OpenSUSE-13.2, or Ubuntu-14.04.

1.1. Description¶

Sentieon® Genomics software is a set of software tools that performanalysis of genomic data obtained from DNA sequencing.

1.2. Benefits and Value¶

The Sentieon® Genomics software enables rapid and accurate analysis ofnext-generation sequence data. The Sentieon® DNAseq pipelines enablegermline variant calling on hundreds of thousands of samplessimultaneously. The Sentieon® TNseq pipelines enable accurate calling ofsomatic variants in paired tumor-normal samples or in an unpaired tumorsamples. The Sentieon® Genomics software produces more accurate resultsthan other tools on third-party benchmarks with results obtained in onetenth the time of comparable pipelines.

1.3. Platform Requirements¶

Sentieon® Genomics software is designed to run on Linux and otherPOSIX-compatible platforms.

For Linux systems, we recommended using the following Linuxdistributions or higher: RedHat/CentOS 6.5, Debian 7.7, OpenSUSE-13.2,or Ubuntu-14.04. Sentieon® Genomics software has not been tested on olderreleases, and may not work.

For Apple OSX systems, OSX 10.9 (Mavericks) or higher is recommended.

Sentieon® Genomics software requires at least 16GB of memory, although werecommend using 64 GB of memory. The alignment step is typically themost memory consuming stage; you can check section Section 7.2.3 for ways tocontrol the memory used in alignment.

Sentieon® Genomics software processes file data at speeds around20-30MB/s per core using a state of the art server. In order to takeadvantage of the maximum speed that the software can provide, werecommend that you use high-speed SSD hard drives in your system,preferably two identical drives in a high speed RAID 0 striped volumeconfiguration. When using a RAID 0 configuration, it is advised to usethe drives to only store intermediate files, and move out any final resultsor important information out of those hard drives; this way, your server shouldhave additional storage space to store the results.

Sentieon® Genomics software requires that your system have either python2.6.x,python2.7.x, or python3.x. You can check the version of the default python in yoursystem by running:

If neither python2.6.x, python2.7.x, or python3.x is not the default python version in yoursystem, you will need to install it and set an environmental variable totell the software where the python binary is located

1.4. Installation procedure for a Linux Based system¶

In order to install the Sentieon® Genomics software in a Linux basedsystem, you need to follow these installation instructions:

  1. Obtain the software release package. The software release package isnamed sentieon-genomics-202010.03.tar.gz, where 202010.03 is therelease version.
  2. Obtain the license file from Sentieon®. The license file has extension .lic.The Sentieon® license control is based on a lightweight floating license serverprocess running on a node, and serving licenses though TCP. In a HPC cluster,the license server process is typically running in a special non-computing nodeon the cluster periphery that has unrestricted access to the outside world throughHTTPS, and serves the licenses to the rest of the nodes in the cluster by listeningto a specific TCP port that needs to be open within the cluster. The license serverneeds to have external https access to validate the license, while the computingclient nodes do not need to have access to the internet. You need to provideSentieon® with the hostname (FQDN or IP) and port where you plan on deploying thelicense server.
  3. Upload the software release package and license file to your server.
  4. Decompress the release package with the command below. This willcreate a folder named sentieon-genomics-202010.03.
  1. Copy the license file to the directory that stores the license files(LICENSE_DIR). If you are running a license server process, startthe license server.
  1. Set an environment variable in your system to indicate where thelicense is located (either LICSRVR_HOST:LICSRVR_PORT if you areusing a license server or LICENSE_DIR/LICENSE_FILE.lic if you areusing a license file)

    We recommend that you add this line to the shell scripts you use torun the Sentieon® software, or to your shell profile:

1.5. Installation procedure for an Apple OSX system¶

In order to install the Sentieon® Genomics software in a Mac OSX basedsystem, you need to follow these installation instructions:

  1. Obtain the software release package. The software release package isnamed mac-sentieon-genomics-202010.03.tar.gz, where 202010.03 is therelease version.
  2. Obtain the license file. The license file has extension .lic.
  3. Upload the software release package and license file to yourcomputer.
  4. Decompress the release package with the command below. This willcreate a folder named mac-sentieon-genomics-202010.03.
  1. Copy the license file to the directory that stores the license files(LICENSE_DIR).
  2. Set the environment variable in your system to indicate where thelicense is located (LICENSE_DIR/LICENSE_FILE.lic). We recommendthat you add these lines to you shell profile ~/.bash_profile:

1.5.1. Using the software on an Apple OSX system¶

When using Sentieon® Genomics software on a laptop using Apple OSX werecommend that you disable the energy saving capabilities of yourcomputer, or temporarily change them while running commands.

To disable the energy saving capabilities of your computer:

  1. Open the system preferences.
  2. Select Energy Saver.
  3. Make sure you check the option to “Prevent computer from sleepingautomatically when display is off”, as shown inFig. 1.1.

Alternatively, you can temporarily disable the energy savingcapabilities of your computer by running the command from a Terminal:

1.6. Useful environmental variables when using the software¶

When using Sentieon® Genomics software there are certain environmental variablesthat may be useful or are required:

  1. SENTIEON_LICENSE: tells the software where the license is located. This variableis required.
  1. SENTIEON_PYTHON: tells the software the location of the python binary. This variableis useful when python2.6.x, python2.7.x, or python3.x is not the default python version in your system.
  1. SENTIEON_TMPDIR: tells the software where to store the intermediate temporary files. Thisvariable is recommended and should point to a fast storage location to prevent the softwarefrom being I/O limited; this is specially important when using a slow NFS storage for input/output.When using this variable, the software will create a unique temporary subfolder in SENTIEON_TMPDIRfor each command, which will reduce contention if multiple commands output to the same folder.
  1. Environmental settings to use jemalloc memory allocation: use the settings bellow to have thesoftware use jemalloc instead of the standard OS memory allocation library. This is recommended in systemswith large memory, or large number of CPUs (more than 32 vCPU). In the code below SENTIEON_INSTALL_DIRpoints to the location of the Sentieon® software package.

1.7. Keywords¶

Bioinformatics, DNA sequencing, Genomics.

On Apple computers, pmset is a command line utility to manipulate power management settings under the Darwin and macOSoperating systems. It can assign sleep settings, schedule sleep and wake times, and display power information.

History[edit]

The pmset utility first appeared in Darwin 6.0.1 and Mac OS X 10.2 'Jaguar'. It has been updated periodically since its introduction, and is still available as of Darwin 19.4 and macOS 10.15 'Catalina'.

Behavior[edit]

The utility sets or lists power management settings. Some of the functionality provided by the utility is available through the GUI interface of the Energy Saver preference pane. However, pmset allows for greater flexibility and access to several options not available in the GUI.

The utility can set different power management settings depending on usage scenario. Different settings can be applied for when the machine is running off a charger, battery, UPS, or all three. The appropriate flags are as follows:

  • -c (charger), adjust settings used while connected to a charger
  • -b (battery), adjust settings used when running off a battery
  • -u (UPS), adjust settings used when running off a UPS
  • -a (all, default) adjust settings for all scenarios
Pmset

Additional arguments be supplied when assigning any power management settings. Power management arguments are discussed in greater detail below. When invoking the command, only specified arguments modify power management options. Any arguments already set will be unmodified by pmset unless those arguments are specifically included.

The utility can schedule wake, sleep, power on or power off events. Events can be recurring based on arbitrary weekday and time combinations, or scheduled for future dates and times. The syntax for scheduling an event is as follows:

Manual
pmset [repeat, schedule] [sleep, wake, poweron, shutdown, wakeorpoweron] [<MTWRFSU> <date/time>]

Previously stored events will be overwritten upon running this command. To schedule multiple events they must be entered in one command string. For example, to set a shutdown event every day of the week at 23:59 and a wake or power on event every day of the week at 7:00 enter the following:

sudo pmset repeat shutdown MTWRFSU 23:59:00 wakeorpoweron MTWRFSU 7:00:00

The get flag displays information about the current power management configuration, or a log of recent activity. If no additional arguments are supplied the flag will only display current settings. Additional get arguments are discussed in greater detail below. The get flag is as follows:

  • -g get, list current power management settings

To view the currently scheduled events type:

pmset -g sched

The utility is also able to configure hibernation and safe sleep options, and change Energy Saver profiles.

Power management settings[edit]

The pmset utility recognizes the following arguments. Arguments can be passed in serial form in any order. Any bad syntax or unrecognized argument will cause the entire command to fail, resulting in an error message and brief help screen. Power management settings can only be changed by a privileged user.

Man
  • displaysleep – display sleep timer in minutes, 0 to disable display sleep
  • disksleep – disk spin-down timer in minutes, 0 to disable disk sleep
  • sleep – system sleep timer in minutes, 0 to disable sleep
  • womp wake on 'magic' Ethernet packet, 1 to enable or 0 to disable
  • hibernatemode change hibernation mode, 0 for RAM powered while sleeping; 1 for RAM contents written to disk and system totally unpowered; 3 for RAM both powered and written to disk; 5 is the same as mode 1, but for use with secure virtual memory; 7 is the same as mode 3, but for use with secure virtual memory; 25 for hibernation in Mac OS X 10.7, with RAM contents written to disk and system totally unpowered
  • hibernatefile change hibernation image file location; image may only be located on the root volume
  • ring wake on modem ring, 1 to enable or 0 to disable
  • autorestart automatic restart after loss of power, 1 to enable or 0 to disable
  • dps dynamically change processor speed based on load, 1 to enable or 0 to disable
  • reduce permanently reduce processor speed, 1 to enable or 0 to disable
  • powerbutton put the machine to sleep when the power button pressed instead of shutting it down, 1 to enable or 0 to disable
  • powernap lets machine stay up to date even while they’re sleeping, 1 to enable or 0 to disable
  • lidwake (laptop only) wake the machine when the laptop lid is opened, 1 to enable or 0 to disable
  • acwake (laptop only) wake the machine when the power source is changed, such as when AC power is removed and the machine switches to battery power, 1 to enable or 0 to disable
  • lessbright (laptop only) slightly turn down display brightness when switching to a specified power source, 1 to enable or 0 to disable
  • halfdim display sleep will use an intermediate half-brightness state between full brightness and fully off, 1 to enable or 0 to disable
  • sms (supported laptops only) use Sudden Motion Sensor to park disk heads on sudden changes in G force, 1 to enable or 0 to disable
  • haltlevel (UPS only) UPS charge in percentage, shut down the machine when UPS reaches a specified charge level
  • haltafter (UPS only) UPS charge in minutes, shut down machine after drawing on UPS for specified number of minutes
  • haltremain (UPS only) UPS charge in minutes, shut down machine when specified time remains on UPS
  • ttyskeepawake prevent idle system sleep when any tty (such as a remote login session) is active; a tty is inactive only when its idle time exceeds the system sleep timer, 1 to enable or 0 to disable
  • autopoweroff (AC power) Where supported, enabled per default as an implementation of Lot 6 to the European Energy-related Products Directive. After sleeping for autopoweroffdelay minutes, the system will write a hibernation image and go into a lower power chipset sleep. Wakeups from this state will take longer than wakeups from regular sleep. The system will not auto power off if any external devices are connected, if the system is on battery power, or if the system is bound to a network and wake for network access is enabled.
  • autopoweroffdelay (AC power) delay before entering autopoweroff mode. (Value = integer, in seconds)
  • standbydelaylow Delay before writing the hibernation image to disk and powering off memory for Standby. standbydelaylow is used when the remaining battery capacity is low. (Value = integer, in seconds)
  • standbydelayhigh Delay before writing the hibernation image to disk and powering off memory for Standby. standbydelayhigh is used when the remaining battery capacity is high. (Value = integer, in seconds)
  • networkoversleep This setting affects how macOS networking presents shared network services during system sleep. This setting is not used by all platforms; changing its value is unsupported.
  • destroyfvkeyonstandby Destroy File Vault Key when going to standby mode. By default File vault keys are retained even when system goes to standby. If the keys are destroyed, user will be prompted to enter the password while coming out of standby mode. (value: 1 - Destroy, 0 - Retain). Since it is essential that the system fully powered down, you also need to set `hibernatemode` to 25 (suspend to disk).

Settings may be adjusted independently for circumstances where the machine is attached to a charger, when running off a battery (in the case of a laptop), or when running off a UPS (if available). Settings can also be adjusted for all four scenarios simultaneously; this is the default option, for when no usage flag is specified. Power management options can be specified for different profiles by appending -c (charger), -b (battery), -u (UPS) or -a (all) flags. The following example will set the machine to sleep after 10 minutes and sleep the display after five minutes, but only when powered by the battery.

pmset -b sleep 10 displaysleep 5

The following command will assign slightly different power management settings for circumstances where the machine is powered by the charger. Here, the machine is set to sleep after 30 minutes and the display is set to never sleep, but only when set by the charger. Issuing both commands will not interfere with each other.

pmset -c sleep 30 displaysleep 0

Arguments can be entered in serial form to set or modify several power management parameters with one command. The following command will set the machine to never sleep (sleep 0), enable the Sudden Motion Sensor (sms 1), set the display to sleep after 20 minutes (displaysleep 20), disable processor speed reduction (reduce 0), enable intermediate display dimness (halfdim 1), enable the machine to wake when the lid is opened (lidwake 1), prevent the system from sleeping when a tty session (such as SSH) is active (ttyskeepawake 1), disable waking the machine when the AC adapter is inserted (acwake 0), disable an automatic restart after power is removed and restored (autorestart 0), enable dynamic change of processor speed based on system load (dps 1), enable wake on modem ring (ring 1), enable wake on receipt of 'magic' Ethernet packet (womp 1), and disable hard disk sleep (disksleep 0):

pmset sleep 0 sms 1 displaysleep 20 reduce 0 halfdim 1 lidwake 1 ttyskeepawake 1 acwake 0 autorestart 0 dps 1 ring 1 womp 1 disksleep 0

Because the above example did not include a usage flag, the settings specified will apply to all usage scenarios. Subsequent commands that do specify a usage flag will only affect settings for that usage scenario. For instance, pmset -b sleep 10 will cause the machine to sleep after 10 minutes, but only when the battery is attached. All other settings will apply when the battery is attached, and all settings in the above example will apply when a charger or UPS is attached.

At least as of Darwin 9.4 and OS X 10.5.4 'Leopard', all changes made through pmset are saved in a persistent preferences file at /Library/Preferences/SystemConfiguration/com.apple.PowerManagement.plist. This file can be modified manually using the defaults command, but those changes will not be taken up immediately by the power management system. Manual edits of com.apple.PowerManagement.plist also stand the risk of being overwritten. The command pmset touch will reread existing settings from disk and apply them to the system.

With autopoweroff enabled the machine will got into hibernate mode even if hibernatemode is 0. The value of autopoweroffdelay may be in seconds despite the man page (for Mavericks, Nov 9, 2012) documenting it as minutes.

Schedule Settings[edit]

The pmset command is able to schedule system sleep, shutdown, wakeup or power on events. The schedule argument is for setting up one-time power events, and repeat is for setting up daily or weekly events. Scheduling of events can only be done by a privileged user.

The schedule argument recognizes the following additional arguments:

Pmset Manual Download

  • type; one of sleep, wake, poweron, shutdown or wakeorpoweron
  • date and time (schedule only); in the format 'MM/dd/yy HH:mm:ss'; must be in 24-hour format, must be in quotes
  • time (repeat only); in the format HH:mm:ss; must be in 24 format, but does not have to be in quotes
  • weekdays; a subset of MTWRFSU such as M or MTWRF are valid, as are strings weekdays, weekends, and everyday
  • owner; a string describing the person or program who is scheduling the power event (optional)

The utility can be very unforgiving of improper syntax. Any errors in syntax will cause the command to fail and will display a brief help message. The syntax for a scheduled event is as follows:

Pmset mac
pmset schedule [sleep, wake, poweron, shutdown, wakeorpoweron] 'MM/dd/yy HH:mm:ss'

Only one type of event (sleep, wake, et cetera) can be specified, and the date chosen must be in the future. The utility expects to be able to store this information in the PMU, and so may not work reliably on non-Apple hardware. The date and time string must be enclosed in quotation marks.

The syntax for a repeating event is as follows:

pmset repeat [sleep, wake, poweron, shutdown, wakeorpoweron] [MTWRFSU, weekdays, weekends, everyday] HH:mm:ss

Scheduled wake, sleep and power events are stored in a persistent preferences file in /Library/Preferences/SystemConfiguration/com.apple.AutoWake.plist. This file can be manually edited using the defaults command, but any changes so made stand a serious risk of being overwritten. Also, such edits will not be immediately taken up by the system.

List options[edit]

Pmset Mac

The list flag, -g, displays information about the current power configuration. The flag alone, with no additional arguments, will display current power management settings. Additional arguments will display more specific information. The get functions of pmset do not require privileged access. The utility recognizes the following arguments (an up-to-date list can be retrieved with the undocumented pmset -g getters command, though it does not show all *log variants):

  • live like -g with no option, displays the settings currently in use
  • custom will display custom settings for all power sources, although these settings may not currently be in use
  • cap capabilities, display which power management features the machine supports
  • sched schedule, display scheduled startup, wake, shutdown and sleep events
  • ups will display UPS emergency thresholds
  • ac or adapter will display details about an attached AC power adapter. Only supported for MacBook and MacBook Pro.
  • ps or batt power source, display status of connected batteries and UPSs
  • accps will display details of power sources for accessories
  • pslog display an ongoing log of power source state
  • rawlog display an ongoing log of power source state as read directly from battery
  • rawbatt display battery state
  • therm shows thermal conditions (not on all platforms)
  • thermlog show an ongoing log of thermal notifications (not on all platforms)
  • assertions displays the summary of current power assertions (10.6 and later)
  • assertionslog displays an ongoing log of power assertions (10.6 and later)
  • sysload displays the system load advisory (10.6 and later)
  • useractivity show current user activity status
  • useractivitylog show an ongoing log of user activity events
  • log show a history log of events
  • history show a timeline of events for debugging
  • historydetailed show driver-level timings for the UUID of a history event
  • hidnull show status of
  • userclients display a list of processes accepting/sending events
  • uuid display the currently active sleep/wake UUID
  • rtc display raw RTC data
  • getters display a list of valid options for -g
  • powerstate display the current power state of all device drivers
  • stats display the sleep/wake statistics
  • systemstate display the current power state and the system's power capabilities
  • everything display everything

Only one get argument can be passed to pmset -g. For instance, to display scheduled events, type pmset -g sched. The utility will not return an error if more than one get argument is provided, but all other than the first will be ignored.

Pmset Manual

The sleep and displaysleep can show an imposed value of 0 (disabled) together with a list of process IDs that impose this value. These are processes such as backup programs which need the machine to stay awake, for example until the backup is finished.

Pmset Manual -

Sample usage[edit]

The following examples demonstrate the output of the pmset command on an Apple PowerBook G4 running Mac OS X 10.5.4 'Leopard'.

The following example will put the relevant computer to sleep immediately:

Pmset Manual Pdf

The following example will apply only to laptops when powered by the battery. It will set the machine to sleep after 5 minutes of inactivity, put the display to sleep after 2 minutes, and spin down the hard disk after 3 minutes. Only privileged users can issue this command. If the command is issued successfully and is without syntax errors, pmset will exit silently with an exit code of 0. To verify that the system took the new configuration, issue the command pmset -g.

The following example will apply only to machines being powered by a UPS. It will set the machine to perform an emergency shutdown when 5 percent battery remains on the UPS, or 5 minutes estimated draw time remains, whichever comes first. Only privileged users can issue this command. If the command is issued successfully and is without syntax errors, pmset will exit silently with an exit code of 0. To verify that the system took the new configuration, issue the command pmset -g.

The following example will apply for all usage scenarios. It will set the machine to wake on receipt of a 'magic' Ethernet packet, wake if the modem detects a ring, and prevent the system from sleeping if a tty session is active. Only privileged users can issue this command. If the command is issued successfully and is without syntax errors, pmset will exit silently with an exit code of 0. To verify that the system took the new configuration, issue the command pmset -g.

The following example sets a one-time scheduled power event. The machine will be set to shut down 01/10/2009 at 10:00 PM (10 January 2009 – Note the US centric MM/DD/YYY time syntax). Only privileged users can issue this command. If the command is issued successfully and is without syntax errors, pmset will exit silently with an exit code of 0. To verify that the system took the new configuration, issue the command pmset -g sched.

The following example sets a repeating power event. The machine will wake or power on every weekday at 8:00 AM. Only privileged users can issue this command. If the command is issued successfully and is without syntax errors, pmset will exit silently with an exit code of 0. To verify that the system took the new configuration, issue the command pmset -g sched.

Here, example output from pmset -g. At the time, the machine was being powered by the charger, while simultaneously charging the battery. The command prints the current configuration.

Here, example output from pmset -g sched. In this example, the machine has already been configured for a repeating event to start or wake up every weekday at 8:00 AM. The command prints the repeating event; note that the next such occurrence appears as a scheduled power event.

Here, example output from pmset -g. At the time, the machine was being backed up. The output shows the PID for the backup program.

See also[edit]

References[edit]

  • pmset(1) manual page at Apple Developer Connection
  • Power Management and Scheduling via Command Line at uMac, University of Utah
  • standbydelayhigh and standbydelay low at Apple Discussions

External links[edit]

  • pmset source code at Apple Developer Connection)
Retrieved from 'https://en.wikipedia.org/w/index.php?title=Pmset&oldid=998440704'