Ath10k_pci 0000:01:00.0: SWBA overrun on vdev 0, skipped old beacon

I am running latest stable 19.07 (OpenWrt 19.07.2 r10947-65030d81f3 ) on Tplink Archer C7. My 2.4GHz wifi no longer is accepting the clients. The log file says,

[ 5542.163778] ath10k_pci 0000:01:00.0: SWBA overrun on vdev 0, skipped old beacon
[ 5542.171214] ath10k_pci 0000:01:00.0: SWBA overrun on vdev 0, skipped old beacon
[ 5542.178683] ath10k_pci 0000:01:00.0: SWBA overrun on vdev 0, skipped old beacon
[ 5542.186141] ath10k_pci 0000:01:00.0: SWBA overrun on vdev 0, skipped old beacon
[ 5542.193591] ath10k_pci 0000:01:00.0: SWBA overrun on vdev 0, skipped old beacon
[ 5542.201037] ath10k_pci 0000:01:00.0: SWBA overrun on vdev 0, skipped old beacon

Any idea what is going on?

Thanks

2 Likes

This problem has already bugged me for a long time since 18+. I made a watchdog script which logread's and waits for this specific error. In case the error occurs it either reboots or reloads the driver with rmmod and modprobe.
This way my wifi availability is perceived very stable.

Please can you post your script.

Yeah, will do this later

1 Like

The latest version of the (ath10k-ct 5 GHz) watchdog script can be obtained from GitHub: https://github.com/Catfriend1/openwrt-presence/tree/master/scripts/ath10k-ct-watchdog

The latest version of the 2.4 GHz WiFi "ath9k-watchdog" script is available from GitHub:

Requires the following packages:

opkg update
opkg install bash

/root/wrtwatchdog

#/bin/sh
#trap "" SIGHUP
#
# Author:		Catfriend1
#
# Info:			OpenWRT Watchdog Script
# Filename:		wrtwatchdog
# Usage:		This script gets called during embedded linux startup.
#
#				System -> Startup (scroll all the way down)
#
#				# Start wrtwatchdog
# 				bash /root/wrtwatchdog start
#				bash /root/wrtwatchdog debug
#
#				# Logging and Monitoring:
#				bash /root/wrtwatchdog showlog
#				bash /root/wrtwatchdog livelog
#
# Installation:	
# 
# opkg update
# opkg install bash
# chmod +x "/root/wrtwatchdog"
# chmod +x "/root/wrtwatchdog_main.sh"
# bash "/root/wrtwatchdog start"
#
#
# Variables:
#
SERVICE_MAIN_SRC="/root/wrtwatchdog_main.sh"
SERVICE_MAIN_TMP="/tmp/wrtwatchdog_main.sh"
# 
SERVICE_MAIN_LOG="/tmp/wrtwatchdog.log"
SERVICE_PID_FILE="/tmp/wrtwatchdog_main.sh.pid"
SHELL_INTERPRETER="bash"
# 
#
# Functions:
#
createInstance ()
{
	#
	# Usage: createInstance
	#
	
	#
	# Check prerequisites.
	#
	if [ ! -f "${SERVICE_MAIN_SRC}" ]; then
		echo "$0: Creating service instance FAILED. Install ${SERVICE_MAIN_SRC} first."
		return
	fi
	
	#
	# Update script copies in "/tmp".
	#
	if [ -f "${SERVICE_MAIN_TMP}" ]; then 
		rm -f "${SERVICE_MAIN_TMP}"
	fi
	cat "${SERVICE_MAIN_SRC}" > "${SERVICE_MAIN_TMP}"

	#
	# Set executable and security permissions.
	#
	chmod +rx "${SERVICE_MAIN_TMP}"
	
	
	#
	# Run service instance.
	# 
	if [ -f "/bin/${SHELL_INTERPRETER}" ]; then
		echo "$0: Creating new service instance ..."
		set -m
		/bin/${SHELL_INTERPRETER} "${SERVICE_MAIN_TMP}" "${DEBUG_MODE}" > /dev/null &
	else
		echo "$0: Creating service instance FAILED. Install ${SHELL_INTERPRETER} first."
	fi
	return
}

findProcess ()
{
	# 
	# Usage: findProcess <ps result line>
	#
	# Purpose: Searches for previously set environment variable "LOOK_FOR_PROCESS".
	#
	# We got a line from ps similar to:
	# [ ]9396 nobody   13952 S    /usr/bin/httpd
	# 
	TEMP_RESULT=$(echo -n "$1" | grep -v grep | grep "$LOOK_FOR_PROCESS")
		
	
	#
	# Check if we found process specified in "LOOK_FOR_PROCESS".
	#
	if test "$TEMP_RESULT"; then
		#
		# Exclude our own PID from results.
		#
		MY_PID=$$
		GOT_PID=$(echo -n "$1" | sed 's/ \+/|/g' | sed 's/^|//' | cut -d '|' -f 1)
		if [ "$MY_PID" != "$GOT_PID" ]; then
			if [ "$NEED_SEPARATOR_ONCE" -eq "0" ]; then
				NEED_SEPARATOR_ONCE=1
			else
				echo -n " "
			fi
			echo -n "$GOT_PID"
		fi
	fi
	
	return
}
#
terminateOldInstances ()
{
	# 
	# Usage: terminateOldInstances <name_of_instance>
	# 
	
	# 
	# Detect and kill any previously running instances of this service.
	# 
	NEED_SEPARATOR_ONCE=0
	LOOK_FOR_PROCESS="$1"
	PS_LIST="$(ps w)"
	PROC_KILL_LIST=$(echo -e "$PS_LIST" | while read file; do findProcess "${file}"; done)
	if test "$PROC_KILL_LIST"; then
		echo "$0: Terminating old \"$LOOK_FOR_PROCESS\" instance(s) #$PROC_KILL_LIST ..."
		kill $PROC_KILL_LIST
	fi
	
	return
}




#
# ! Not supported on BusyBox routers.
#. /lib/lsb/init-functions
#


#
# Service instance control main.
#
DEBUG_MODE=""

case "$1" in
'debug')
		# Set DEBUG_MODE to ON.
		DEBUG_MODE="debug"
		;;
esac


case "$1" in
'start' | 'reset' | 'restart' | 'debug')
		sh $0 stop
		#
		# Hauptprogramm des Dienstes in neuer Instanz ausfuehren.
		createInstance
		#
		exit 0
		;;
'stop')
		if [ -f "${SERVICE_PID_FILE}" ]; then
			kill -INT "$(cat "${SERVICE_PID_FILE}")"
			rm "${SERVICE_PID_FILE}"
		fi
		#
		# Speicher von laufenden Instanzen befreien.
		terminateOldInstances "${SHELL_INTERPRETER} ${SERVICE_MAIN_TMP}"
		#
		exit 0
		;;
'showlog')
		# Zeige Log des Dienstes.
		tail -n 60 "${SERVICE_MAIN_LOG}"
		exit 0
		;;
'livelog')
		# Zeige Log des Dienstes.
		clear
		tail -f "${SERVICE_MAIN_LOG}"
		exit 0
		;;
'diag')
		ps w | egrep "watchdog|tail|logread" | grep -v "grep" | grep -v "livelog" | grep -v "diag"
		exit 0
		;;
'clean')
		exit 0
		;;		
esac
echo "Usage: $0 {start|debug|stop|reset|restart|showlog|livelog|clean}"
exit 0

/root/wrtwatchdog_main.sh

#/bin/bash
trap "" SIGHUP
#
trap "trap - SIGTERM && kill -- -$$" SIGINT SIGTERM EXIT
# 
# set +m
#
# Info:				OpenWRT Watchdog Service Main Loop
# Prerequisites:
#
#	* BASH		(required for arrays)
#
# Filename:			wrtwatchdog_main.sh
# Usage:			This script gets instanced by "wrtwatchdog".
#
# Author:			Catfriend1
#
# Prerequisites:
# 
# 	wrtwatchdog								main service wrapper
# 	wrtwatchdog_main.sh						main service program
# 
# For testing purposes only:
# 	killall logread; killall tail; sh wrtwatchdog stop; bash wrtwatchdog_main.sh debug
# 	kill -INT "$(cat "/tmp/wrtwatchdog_main.sh.pid")"
#
# Script Configuration.
#
PATH=/usr/bin:/usr/sbin:/sbin:/bin
CURRENT_SCRIPT_PATH="$(cd "$(dirname "$0")"; pwd)"
PID_FILE=/tmp/"$(basename "$0")".pid
LOGFILE="/tmp/wrtwatchdog.log"
LOG_MAX_LINES="1000"
DEBUG_MODE="0"
#
# Variables: RUNTIME.
#
MY_SERVICE_NAME="$(basename "$0")"
# 
# -----------------------
# --- Function Import ---
# -----------------------
# 
# 
# -----------------------------------------------------
# -------------- START OF FUNCTION BLOCK --------------
# -----------------------------------------------------
logAdd ()
{
	TMP_DATETIME="$(date '+%Y-%m-%d [%H-%M-%S]')"
	TMP_LOGSTREAM="$(tail -n ${LOG_MAX_LINES} ${LOGFILE} 2>/dev/null)"
	echo "${TMP_LOGSTREAM}" > "$LOGFILE"
	if [ "$1" == "-q" ]; then
		#
		# Quiet mode.
		#
		echo "${TMP_DATETIME} ${@:2}" >> "${LOGFILE}"
	else
		#
		# Loud mode.
		#
		echo "${TMP_DATETIME} $*" | tee -a "${LOGFILE}"
	fi
	return
}


logreader() {
	#
	# Called by:	MAIN
	#
	logAdd -q "[INFO] BEGIN logreader_loop"
	/sbin/logread -f | while read line; do
		if $(echo -n "${line}" | grep -q "kernel.*ath10k_pci.*failed to send pdev bss chan info request"); then
			logAdd -q "[ERROR] ath10k_pci 5G WiFi card failed. Restarting driver ..."
			rmmod ath10k_pci
			sleep 2
			modprobe ath10k_pci
			sleep 5
			logAdd -q "[INFO] Restarting wifi after driver restart ..."
			wifi up
		fi
	done
}
# ---------------------------------------------------
# -------------- END OF FUNCTION BLOCK --------------
# ---------------------------------------------------
#
#
#
#
#
#
#
#
# Check commmand line parameters.
#
case "$1" in 
'debug')
	# Turn DEBUG_MODE on.
	DEBUG_MODE="1"
	# Continue script execution.
	;;
esac
#
# Service Startup.
#
if [ "${DEBUG_MODE}" == "0" ]; then
	logAdd "${MY_SERVICE_NAME} wurde neu gestartet."
	sleep 10
else
	# Log message.
	logAdd "${MY_SERVICE_NAME} wurde im DEBUG_MODE neu gestartet."
fi
#
# Service Main.
#
# Store script PID.
echo "$$" > "${PID_FILE}"
#
# Fork three permanently running background processes.
logreader &
#
# Wait for kill -INT from service stub.
wait
#
# We should never reach here.
#
logAdd "${MY_SERVICE_NAME}: End of script reached."
exit 0

Autorun setup:

  • Edit /etc/rc.local
# Put your custom commands here that should be executed once
# the system init finished. By default this file does nothing.

/bin/bash /root/wrtwatchdog start

exit 0
8 Likes

Same problem on my TP-Link TL-WPA8630 v1 running OpenWrt 22.03-SNAPSHOT r19208-30614c6cfa.

[531641.623454] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon
[531641.879430] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon
[531642.135461] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon

Problem on TP-Link TL-WPA8630 v1 does still exist on OpenWrt 22.03.2.

[26708.093761] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26708.349768] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26708.605766] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26708.861776] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26709.117771] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26709.373805] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26709.629810] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26774.655845] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26774.912032] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26775.167863] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [26775.423883] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27374.737344] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27374.993355] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27375.249374] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27375.505382] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27908.001423] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27908.257433] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27908.513449] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27908.769442] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [27909.025449] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28441.265137] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28441.521139] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28441.777149] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28442.033162] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28508.083079] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28508.339084] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28574.645037] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28574.901053] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [28575.157059] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29041.346293] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29041.602302] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29041.858304] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29042.114315] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29042.370332] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29042.626402] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29042.882327] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29043.138319] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [29043.394327] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [30908.153373] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281043.770126] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281044.026148] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281044.282149] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281044.538163] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281110.331605] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281110.587616] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281110.843632] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon [281111.099641] ath10k_pci 0000:00:00.0: SWBA overrun on vdev 0, skipped old beacon

I have this error on Archer C7 v2 since 22.03.2,

Cause high ping spike on 5Ghz radio until I do rmmod ath10k_pci; sleep 1; modprobe ath10k_pci; sleep 2; wifi up
Today I switched to non-ct but low signals are unstable (around -75 dBm)

1 Like

Try ldpc off, see other thread

Which thread please?
LDCP ist the abbreviation of Low-Density Parity Check and is some kind of Forward-errorcorrection. Is there a Bug in the Driver with LDCP or why does turning it off help?

Hello

I already put ldcp off on 2.4ghz
Ldcp exists on 5ghz ?

I have more stability with non-Ct firmware and Ct kernel module but still not good as excepted

I don't have this issue with second C7 (fake C5 with C7 ROM) but this second C7 have half clients than this C7 (12 instead of 25)

Strange thing : 2.4ghz is very stable, not dying with your watchdog
Die after only 6 day
Your watchdog loop but no crash of 2.4ghz
A reboot of iface and problem solved

2023-05-20T12:39:21+00:00 AP68-1 ath9k-watchdog: [INFO] === SERVICE START ===
2023-05-20T12:39:21+00:00 AP68-1 ath9k-watchdog: [INFO] Waiting to discover 2.4 GHz radio interface ...
2023-05-20T12:39:21+00:00 AP68-1 ath9k-watchdog: [INFO] Setup iw_event_scan_trigger on interface [wlan1]
2023-05-26T00:00:36+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:03:43+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:09:13+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:09:56+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:10:37+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:11:24+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:11:48+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:12:10+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:12:50+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...
2023-05-26T00:14:12+00:00 AP68-1 ath9k-watchdog: wlan1 scan ...

I tried kernel mod non Ct but ath9k go down after a huge ram usage of ath10k

I switched to ct full htt and more stability now
No crash for 7 days

I scrape at 2sec interval the ram and I have less spike on ath10k
I am thinking to switch to smallbuffers module cuz when I iperf3, the ram go over 80% with non ct and ct simple, and 70% with full htt

2 Likes