How do I enable ntpd to serve ntp clients (using High Sierra)?

Solution 1:

You have to configure ntp.conf and ntp-restrict.conf to run a local time server:

  1. Kill ntpd
  2. Add

    server 127.0.0.1 prefer
    fudge 127.0.0.1
    

    at the end of /etc/ntp.conf.

  3. Add

    restrict <network_address> mask <net_mask> nomodify notrap
    

    after the localhost restriction block in /etc/ntp-restrict.conf. Replace <network_address> with your local network address (e.g. 192.168.2.0) and <net_mask>with your mask (e.g. 255.255.255.0)

  4. Reload org.ntp.ntpd-legacy (I had no problem to load the system daemon - SIP disabled though):

    sudo launchctl unload -w /System/Library/LaunchDaemons/org.ntp.ntpd-legacy.plist
    sudo launchctl load -w /System/Library/LaunchDaemons/org.ntp.ntpd-legacy.plist
    
  5. Check your time server locally:

    ntpdate -vdq 127.0.0.1
    

    Usually the server is not suitable on the first attempt because the stratum is to high (i.e. 16 = unsynchronized)! Wait some time and try again. Here it took about 10 minutes to bring the stratum down to 2 from 16.

  6. Connect your Mac to the private network and try to sync your Raspberry Pi clients.