Skip to main content
Question

Lab power policy

  • October 7, 2022
  • 6 replies
  • 14 views

tdenton
Forum|alt.badge.img+11

Hi All

We currently have the wrong power setting in our labs. I want the machines to always be on which I think I have working with a config profile.

However our machines are set lock at 20 minutes. This now doesn't happen as the machine never sleeps.

Can two exist together.

Any thoughts welcome.

 

 

 

 

 

 

6 replies

tdenton
Forum|alt.badge.img+11
  • Author
  • Valued Contributor
  • October 8, 2022

Just to add to this, have discovered the machine does lock eventually if left ideal. Seems to ignore the 20 minutes lock policy though 


PaulHazelden
Forum|alt.badge.img+12
  • Jamf Heroes
  • October 10, 2022

I use pmset in a script to get what I want
https://ss64.com/osx/pmset.html
Will show you all the settings available.
Although a confi profile should be able to give you all of the same functionality.


tdenton
Forum|alt.badge.img+11
  • Author
  • Valued Contributor
  • November 21, 2022

I use pmset in a script to get what I want
https://ss64.com/osx/pmset.html
Will show you all the settings available.
Although a confi profile should be able to give you all of the same functionality.


Are you able to share what you are using.

Are using this in shared labs?


PaulHazelden
Forum|alt.badge.img+12
  • Jamf Heroes
  • November 22, 2022

# Set display and system sleep times

/usr/sbin/systemsetup -setcomputersleep Never

/usr/sbin/systemsetup -setdisplaysleep 30

/usr/sbin/systemsetup -setharddisksleep Never

# Start and shutdown

#  Turn it off and back on again, to remove anything left in there

pmset repeat cancel

sleep 5

pmset repeat shutdown MTWRFS 21:00:00 wakeorpoweron MTWRFS 08:00:00

pmset -a darkwakes 0 womp 1 autorestart 1 sleep 0 disksleep 0 hibernatemode 0 displaysleep 30 powernap 0

 

/usr/sbin/systemsetup -setwakeonnetworkaccess on

/usr/sbin/systemsetup -setrestartpowerfailure on

/usr/sbin/systemsetup -setallowpowerbuttontosleepcomputer off


tdenton
Forum|alt.badge.img+11
  • Author
  • Valued Contributor
  • November 22, 2022

# Set display and system sleep times

/usr/sbin/systemsetup -setcomputersleep Never

/usr/sbin/systemsetup -setdisplaysleep 30

/usr/sbin/systemsetup -setharddisksleep Never

# Start and shutdown

#  Turn it off and back on again, to remove anything left in there

pmset repeat cancel

sleep 5

pmset repeat shutdown MTWRFS 21:00:00 wakeorpoweron MTWRFS 08:00:00

pmset -a darkwakes 0 womp 1 autorestart 1 sleep 0 disksleep 0 hibernatemode 0 displaysleep 30 powernap 0

 

/usr/sbin/systemsetup -setwakeonnetworkaccess on

/usr/sbin/systemsetup -setrestartpowerfailure on

/usr/sbin/systemsetup -setallowpowerbuttontosleepcomputer off


thanks i assume this would work on both intel and Apple silcon.


PaulHazelden
Forum|alt.badge.img+12
  • Jamf Heroes
  • November 22, 2022

Yes I have this running on M1 and Intel