(Semi) Auto Installer Instructions

Rather than have to run several dozen commands to install and configure ntp, run this script.


This script is only Semi-Automatic since you'll be needed to confirm some installs and change some config files. If the install fails, either check the log or try running the install manually by following Manual Installation Instructions. If this also fails, check Troubleshooting, Debugging, and More! for help.


You can find a video of the following process here: https://youtu.be/Zn6aIcaM4XM

  1. Create a directory of your choice and place it somewhere where you won't move the files inside since they'll be needed at each boot of the system. Copy ntpAuto.sh, the auto-installer, and ntpConfigBoot.sh, the script to run every boot, into that directory.

  2. Open a terminal and run the following commands to properly start the script:

    sudo -i
    chmod 777 ntpAuto.sh
  3. At this point, the script will run and begin installing the needed software. This may take some time so feel free to do something else while everything installs, however please note you may be prompted to allow certain packages to install so stay close and check from time to time.

  4. Once the installs are done, the configuration process will begin. This will require you to change a few config files. The first file will be the minnow-pps-gpio.c file. When this opens, scroll down slightly and change the “PPS_GPIO” pin number to the proper number for you board. With the GPS lure this number is 340.

  5. Save and exit the file using [Ctrl] + [O], [ENTER], and [CTRL]+[X].

  6. The next file to edit will be the modules file. In this file simply scroll to the bottom and add “pps-gpio”

  7. Save and exit again. The PPS settings will now be set up.

  8. The next file to open will be ntp.conf. In this file edit the lines at the bottom to match:

    server mode 18 minpoll 4 maxpoll 4 iburst prefer
    fudge flag1 1 flag2 0 flag3 0  time2 0.0 stratum 1
    server minpoll 1 maxpoll 1 #ATOM (PPS)
    fudge refid PPS # enable PPS API
  9. Save and exit ntp.conf. Next, the usr.sbin.ntpd file will open. Scroll to the bottom and add “capability ipc_owner“ if it is not already present, and save the file.

  10. Finally rc.local will open. Scroll down to the exit line and press enter to make a new line above it. On this line enter <FILEPATH TO THE AUTOSCRIPT FOLDER>/ntpConfigBoot.sh. For example, this might be /home/ubuntu/Desktop/Autoscript/ntpConfigBoot.sh if you extracted to your desktop. This is the important file that needs to be kept. If you ever move this file, be sure to update the rc.local file to match as this script autoconfigures the system on startup and is needed to work.

  11. After a reboot, the clock should now be installed and begin honing in on the time. You can run the ntp.sh script (located in the zip file) to automatically check every 15 seconds for the clock values.


If you would like to broadcast this time to your local network, please check Broadcasting the Time.