I’ve updated one of my feeders to run the latest PI OS, and the sequence of startup often has piaware failing to start on the PiZeroW. If I remember to log into the machine and start the service, it starts just fine.
Jan 31 12:16:59 WimPiZeroW systemd[1]: Started piaware.service - FlightAware ADS-B uploader.
Jan 31 12:17:16 WimPiZeroW piaware[468]: software failed to determine MAC address of the device. cannot proceed without it.
Jan 31 12:17:16 WimPiZeroW systemd[1]: piaware.service: Main process exited, code=exited, status=6/NOTCONFIGURED
Jan 31 12:17:16 WimPiZeroW systemd[1]: piaware.service: Failed with result 'exit-code'.
Jan 31 12:17:16 WimPiZeroW systemd[1]: piaware.service: Consumed 2.069s CPU time.
I’ve noticed that the systemd unit file explicitly won’t restart piaware based on return code 6, described as missing MAC.
# piaware uploader service for systemd
# install in /etc/systemd/system
[Unit]
Description=FlightAware ADS-B uploader
Documentation=https://flightaware.com/adsb/piaware/
Wants=network-online.target
After=dump1090-fa.service network-online.target time-sync.target
[Service]
User=piaware
RuntimeDirectory=piaware
ExecStart=/usr/bin/piaware -p %t/piaware/piaware.pid -plainlog -statusfile %t/piaware/status.json
ExecReload=/bin/kill -HUP $MAINPID
Type=simple
Restart=on-failure
RestartSec=30
# exit code 4 means login failed
# exit code 6 means startup failed (bad args or missing MAC)
RestartPreventExitStatus=4 6
WatchdogSec=120
WatchdogSignal=SIGKILL
NotifyAccess=all
[Install]
WantedBy=default.target
Will removing the 6 from the RestartPreventExitStatus line likely fix my problems, and what are the implications doing so?
If I do that I’ll probably also increase the RestartSec value from 30 to 60.