Continuing "antenna_wifi.service restarts in Buster

Greetings!

While tracking down another issue I took a peek at the syslog.

Note the following messages that are completely filling my syslog making it virtually impossible to find anything else.

Feb 22 20:17:10 Charlie systemd[1]: antenna_wifi.service: Service RestartSec=10s expired, scheduling restart.
Feb 22 20:17:10 Charlie systemd[1]: antenna_wifi.service: Scheduled restart job, restart counter is at 122.
Feb 22 20:17:10 Charlie systemd[1]: Stopped R4R Antenna Wifi Indicator.
Feb 22 20:17:10 Charlie systemd[1]: Started R4R Antenna Wifi Indicator.
Feb 22 20:17:10 Charlie systemd[1]: antenna_wifi.service: Succeeded.
Feb 22 20:17:20 Charlie systemd[1]: antenna_wifi.service: Service RestartSec=10s expired, scheduling restart.
Feb 22 20:17:20 Charlie systemd[1]: antenna_wifi.service: Scheduled restart job, restart counter is at 123.
Feb 22 20:17:20 Charlie systemd[1]: Stopped R4R Antenna Wifi Indicator.
Feb 22 20:17:20 Charlie systemd[1]: Started R4R Antenna Wifi Indicator.
Feb 22 20:17:20 Charlie systemd[1]: antenna_wifi.service: Succeeded.
Feb 22 20:17:30 Charlie systemd[1]: antenna_wifi.service: Service RestartSec=10s expired, scheduling restart.
Feb 22 20:17:30 Charlie systemd[1]: antenna_wifi.service: Scheduled restart job, restart counter is at 124.
Feb 22 20:17:30 Charlie systemd[1]: Stopped R4R Antenna Wifi Indicator.
Feb 22 20:17:30 Charlie systemd[1]: Started R4R Antenna Wifi Indicator.
Feb 22 20:17:30 Charlie systemd[1]: antenna_wifi.service: Succeeded.

These messages go on and on and on and on and on. Every ten seconds. . . . filling my syslog to the point where it is useless for anything else.

Any help would be gratefully appreciated.

Only thing is to turn off the led, don’t need it do you?

My util: https://github.com/slowrunner/Carl/blob/master/wifi_led_off.sh

1 Like

I’m not sure if I am understanding correctly.
My question was about why it repeats so often and if it’s really necessary to flood the syslog with these messages.

Why is it necessary for that to run constantly?

Can’t it be run as a service that auto-restarts of killed - and only reports exceptional behavior?

P.S.
That link takes me to the Dexter home page.

Jimmy, ( who asks “Why is there air?”)

That is the way DI chose to implement the WiFi status indicator. Every 10s it checks the WiFi status and schedules the next execution. The syslog entry is not an output of the indicator code, it is the system reporting changes in system components.

99.9% of GoPiGo3 users do not even know the syslog exists, so does it really matter “why?”

In that post I show how to stop those “offending log entries”, and the link is to a bash script wifi_led_off.sh to do it. I’ll put the code here:

#!/bin/bash

# stop GoPiGo3 antenna_wifi.service
sudo systemctl stop antenna_wifi
# turn off wifi_led
python -c "import gopigo3;GPG=gopigo3.GoPiGo3();GPG.set_led(GPG.LED_WIFI,0,0,0)"

@cyclicalobsessive is right. Every 10 seconds we verify that the robot is still connected to wifi and keep the antenna on/off accordingly.
For Google Cloud Derby, we removed that, so it can totally be done in Raspbian or Raspbian for Robots (not for DexterOS)

sudo nano /etc/systemd/system/antenna_wifi.service

Remove these two lines:

Restart=always
RestartSec=10

You’ll get a yellow LED once the robot connect to wifi, but it will not be kept up to date. You can even turn it off if you want to save (a tiny amount) of battery power.