Skip to main content
Solved

General system maintenance script?

  • February 10, 2016
  • 7 replies
  • 33 views

georgecm12
Forum|alt.badge.img+12

Does anyone have a script that they use to run maintenance tasks on a system, such as a computer lab machine, that is used by multiple users and/or left on for extended periods of time?

I don't have any specific things in mind at this time. I'm trying to rid my world of Deep Freeze, and I'm trying to come up with things that I'd need to "clean up" on a system that Deep Freeze currently does for me (by restarting after each logout).

Our lab administrator is somewhat reticent to give up Deep Freeze, as (admittedly) this year has produced some of the lowest number of incidents from lab/classrooms. I'm trying to cover my bases by making sure the systems maintain themselves without the need for Deep Freeze.

Best answer by msnowdon

I have a Computer Maintenance policy in self-service. It's already built in to Policy Options. You can see from the image what it can do. I don't have it run automatically because the file permissions repair can take a while.

7 replies

bpavlov
Forum|alt.badge.img+18
  • Esteemed Contributor
  • February 10, 2016

what issues does deep freeze resolve? do your lab users have admin access on these computers?


Forum|alt.badge.img+15
  • Contributor
  • February 10, 2016

Not much you need to fix unless you users are jerks. And then I cant predict what they would do. The only maintenance I can think of on a lab is deleting old user home directories when the HD gets full. There's a few scripts around that run a couple times a day. If the HD is x% full, then delete the oldest home directory, and repeat.


Forum|alt.badge.img+16
  • Valued Contributor
  • February 10, 2016

Plus scheduled restarts to remove any rogue processes and logged in users and ensure updates apply correctly.


Forum|alt.badge.img+10
  • Contributor
  • Answer
  • February 11, 2016

I have a Computer Maintenance policy in self-service. It's already built in to Policy Options. You can see from the image what it can do. I don't have it run automatically because the file permissions repair can take a while.


Forum|alt.badge.img+12
  • Contributor
  • February 11, 2016

@msnowdon I like that idea a lot, now that permissions repair has been removed from Disk Utility in 10.11. It's not the fix it used to be, but I still like having it around.


georgecm12
Forum|alt.badge.img+12
  • Author
  • Valued Contributor
  • February 11, 2016

Yeah, that's a total "duh" moment. I forgot about the Maintenance policy in JSS. Those are pretty much the kinds of things I was thinking about. Thanks, @msnowdon!


donmontalvo
Forum|alt.badge.img+36
  • Hall of Fame
  • March 10, 2016

Hopefully flushing user caches is followed by a log out, and flushing system caches is followed by a reboot.