This script does basic dns check and also preferred order.
Lab example:
[Expert@CP-GW:0]# ./cp_dns_advisor.sh
=== Check Point Gaia DNS Advisor ===
Testing: repeats=3 timeout=2s domains=(checkpoint.com microsoft.com example.com)
Include public resolvers: 0
Apply changes: 0
Detected domain context:
Domain name : <not set>
DNS suffix : <not set>
Candidate DNS servers:
- 8.8.8.8
- 8.8.4.4
- 1.1.1.1
Testing 8.8.8.8 ...
Testing 8.8.4.4 ...
Testing 1.1.1.1 ...
=== Recommendations (lower score is better) ===
Score Server UDP_avg(ms) UDP_ok/fail TCP_avg(ms) TCP_ok/fail Private
----- -------------- ---------- ---------- ---------- ---------- -------
57 1.1.1.1 6 9/0 5 3/0 no
64 8.8.4.4 7 9/0 5 3/0 no
67 8.8.8.8 7 9/0 6 3/0 no
Suggested DNS order:
Primary : 1.1.1.1
Secondary: 8.8.4.4
Tertiary : 8.8.8.8
Read-only mode. Re-run with --apply to set DNS in clish and save config.
[Expert@CP-GW:0]#
Best,
Andy