Chrony+GPSD (PPS+GPS) on Pi

apt-get update; apt-get -y dist-upgrade; apt -y autoremove; apt clean; apt autoclean

root@gps1:~# cat /etc/apt/sources.list
deb bullseye main contrib non-free rpi

apt clean; apt update; apt upgrade; apt dist-upgrade; apt autoremove


apt-get install snmpd
apt-get install lsof
Configure remote logging

ln -s /usr/share/zoneinfo/US/Central /etc/localtime

Set swap to 1G
vi /etc/dphys-swapfile
/etc/init.d/dphys-swapfile stop
/etc/init.d/dphys-swapfile start


dwc_otg.lpm_enable=0 console=tty1 root=PARTUUID=1d8091da-02 rootfstype=ext4 elevator=deadline net.ifnames=0 rootwait


#GPS Changes

echo “pps-gpio” >> /etc/modules

apt-get install pps-tools


vcgencmd measure_clock arm

apt-get install gpsd gpsd-clients



root@gps1:/etc/udev/rules.d# cat 09.gps.rules
KERNEL=="ttyAMA0", SYMLINK+="gps0"
KERNEL=="pps0", OWNER="root", GROUP="tty", MODE="0777", SYMLINK+="gpspps0"

systemctl enable gpsd


systemctl status gpsd
gpsmon /dev/gps0

ppstest /dev/pps0


systemctl disable systemd-resolved
systemctl stop systemd-resolved
systemctl status
systemctl disable dhcpcd.service
Configure /etc/network/interfaces

reboot (hope for the best)

apt-get install chrony


# Source Clock
refclock PPS /dev/pps0 lock NMEA refid PPS1 prefer
refclock SHM 0 offset 0.5 refid NMEA noselect

# Internal peers
peer iburst prefer

# Sanity Servers
server iburst
server iburst

# Act as an NTP server

# Only allow chronyc from the localhost

# Record the rate at which the system clock gains/losses time.
driftfile /var/lib/chrony/drift

# Allow the system clock to be stepped in the first three updates
# if its offset is larger than 1 second.
makestep 1.0 3

# Notify on error correction > 0.5 seconds
logchange 0.5

# Enable kernel synchronization of the real-time clock (RTC).

# Lock clock in to RAM

sched_priority 1

# Fudge Stratum if we cannot reach the internet
local stratum 10

# Get TAI-UTC offset and leap seconds from the system tz database.
leapsectz right/UTC
leapsecmode slew
maxslewrate 1000
smoothtime 400 0.001 leaponly

# Specify directory for log files.
logdir /var/log/chrony

# Select which information is logged.
log measurements statistics tracking

keyfile /etc/chrony/chrony.keys

systemctl enable chrony
systemctl status chrony
systemctl restart chrony
systemctl status chrony

watch “chronyc sources -v”

General OS Setup:
apt-get install libsasl2-modules postfix bsd-mailx deborphan
Create /root/.forward
/etc/postfix/ inet_interfaces = loopback-only

apt-get install bind9 dnsutils

Install custom /etc/fail2ban/jail.local

apt-get install clamav
#NotifyClamd /etc/clamav/clamd.conf

Hits: 11

5Ghz WiFi and Windows 10

I have been having issues with devices maintaining connections to my 5Ghz SSID on multiple devices. After the latest Android update, it seems my phone is able to maintain reliable 5Ghz connections but my Windows 10 laptop was still having issues. After some searching I decided to update the driver and see if it made a difference. Its still too early tell for sure, but it seems the new driver is doing better. The AP in question is a Synology RT2600ac with SmartConnect disabled, running 2 separate SSIDs for 2.4Ghz and 5Ghz. Support has been of absolutely no use. They repeatedly stated they didn’t see any disconnects in the logfile dumps.

Normally I would only stay connected, if I could connect at all, for a few minutes.

System Manufacturer:LENOVO
System Product Name:20L50017US
BIOS Date:05/22/2018
BIOS Version:N24ET39W (1.14 )
OS Build:17763.1.amd64fre.rs5_release.180914-1434

The driver version I was having an issue with:
Device: Intel(R) Dual Band Wireless-AC 8265
Current driver version:
Driver date: 6-29-2019

The latest version in testing:
Device: Intel(R) Dual Band Wireless-AC 8265
Current driver version:
Driver date: 8-26-2019

I ran “netsh wlan show wlanreport” to get some insight on what was going on.
BOLD items below are 5Ghz specific errors and warnings. The 2.4Ghz SSID has been working without issue.

Session Success/Failures
Status Count
Successes 2
Failures 10
Warnings 16

Disconnect Reasons
Reason Count
The driver disconnected while associating. 8
The network is disconnected by the driver. 7
The network is disconnected because the user wants to establish a new connection. 4
The network is disconnected by the user. 2

The error I was repeatedly getting while trying to connect to the 5Ghz SSID is:
Failure Reason:The driver disconnected while associating.

The red Xs in the image below are all dropped connections to 5Ghz.

Hits: 349