prplos/.gitlab/scripts
Petr Štetiar 77046c9b10
ci: cdrouter: fix hostname resolutions by flushing DNS relay cache
We're unable to run CDRouter test for CPE's TR-069 functionality due to
the following error during the test init phase:

 FAIL: Did not receive TR-069 Inform RPC from CPE after 120 seconds » no-wan-tr069-inform

Analyzing the logs, issue arise whenever CPE manages to get  a first WAN
address from testbed server instead of CDRouter. With additional unbound traces we can see what happens:

As WAN is up, DNS query for controller.cdroutertest.com  is forwarded to
configured  upstream DSN server (8.8.8.8  and 1.1.1.1)

1.1.1.1 will reply with a SOA  as cdroutertest.com is registered:

 cdroutertest.com.	3600 IN	SOA	ns1.linode.com. support.qacafe.com. 2021000016 14400 14400 1209600 86400

As TTLS is set to 3600 seconds, unbound will cache this as a negative answer for 1 hour.

Latter upstream of CPE is switched to CDRouter, obuspa tries to resolve
controller.cdroutertest.com, but it gets the cached answer as its TTL is
not expired, and no WAN DSN query is done.

So lets fix it by flushing the DNS relay cache during the DUT init
phase, once the network is switched to the CDRouter.

Fixes: PCF-1215
Suggested-by: Vincent Harle <vincent.harle@softathome.com>
Signed-off-by: Petr Štetiar <petr.stetiar@prplfoundation.org>
(cherry picked from commit 53f718bde87b0e1773244da021daf2eeeac8a62a)
2025-07-31 15:18:54 +00:00
..
build.d ci: build: enable exception tracing on arm64 targets 2025-07-31 10:36:01 +00:00
dut-init ci: cdrouter: fix hostname resolutions by flushing DNS relay cache 2025-07-31 15:18:54 +00:00
cdrouter-pretty-failures.awk
prpl-jira.py
README.md
requirements.txt
testbed-cdrouter.py ci: scripts: reformat with black 2025-07-31 10:34:23 +00:00
testbed-device.py ci: testbed-device.py: MXL25641-HDK-6: add VLAN bridge port 2025-07-31 10:36:13 +00:00

Content

This directory contains files used mainly during testing on the GitLab CI.

requirements.txt

This requirements.txt file is used for specifying what Python packages are required to run the scripts in this directory. Usually used with pip install -f requirements.txt command.

prpl-jira.py

This helper Python script creates new or updates existing Jira ticket when something goes wrong during GitLab CI testing process. Currently only supports reporting of build test failures.

Needs Python version 3.6+ due to use of f-strings feature.

testbed-device.py

This helper Python scripts allows managing of device under test (DUT) via labgrid framework.