Monday 8 October 2012

Setting all Apple Macs to use network time servers

So I wanted to change all the Macs here to use our specific network time servers so that their time is never out and so cause login issues. I did it by first finding the command line arguments, then making a shell script, then making a pkg file which the OS X task server sent to all the machines when they are powered on.

Here's the step by step guide:

  1. finding the command line arguments:
    1. sudo systemsetup -setnetworktimeserver your.time.server.ac.uk
    2. sudo systemsetup -setusingnetworktime on
  2. making a shell script
    1. make a new plain text document using "TextEdit"
    2. make the first line:
      1. #!/bin/bash
    3. paste the two lines from 1.1 and 1.2
    4. save as (untick "add .txt file extension) and put .sh at the end
    5. make it executable
      1. in terminal type:
        1. chmod 744 nameOfShellScript.sh
  3. make a .pkg file which runs this script
    1. I use Iceberg. Here are the screenshots:


    2. When done, go to Build > build
    3. navigate to the project folder in Finder and inside the "Build" folder you'll find the .pkg file.
  4. test it on a computer
  5. Send to all machine
    1. I use Apple Remote Desktop Task Server for this
      1. select the computers in a list
      2. click "Install Packages"
      3. select the package
      4. select "run this task from: The Task Server on your.task.server.ac.uk"
      5. sorted
    2. sorted
  6. sorted

No comments:

Post a Comment