Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Operational status support for DNS and NTP #510

Open
1 of 3 tasks
troglobit opened this issue Jul 2, 2024 · 1 comment
Open
1 of 3 tasks

Operational status support for DNS and NTP #510

troglobit opened this issue Jul 2, 2024 · 1 comment
Labels
enhancement New feature or request feature Feature request
Milestone

Comments

@troglobit
Copy link
Contributor

troglobit commented Jul 2, 2024

See comments to #249, regarding lacking operational status for DNS, NTP as well as regression tests

  • Add operational support for DNS server
  • Add operational support for NTP server
  • Add associated regression tests (1) for manual/regular DNS and NTP and (2) when used by DHCP

As part of the task, please explore/propose/sync what operational data is available and relevant.
For NTP there is likely a lot of info.
For DNS I suppose there is not so much. If DHCP is used to acquire DNS there is at least some dynamic data.

Consider to include domain "search" setting as part of this task. Alternatively, put that in a separate task as it has lower priority.

@jovatn
Copy link
Contributor

jovatn commented Sep 6, 2024

There is some support for DNS status, at least CLI "show dns" command shows current DNS servers assigned via DHCP.
But if a static DNS server is configured, that is not reflected by "show dns", see examples below.

First setting DNS via DHCP.

admin@infix-ad-00-00:/> configure
admin@infix-ad-00-00:/config/> set dhcp-client client-if e28
admin@infix-ad-00-00:/config/> leave
admin@infix-ad-00-00:/> show dns
# resolv.conf from e28.conf
nameserver 172.31.11.11 # e28
nameserver 172.31.11.12 # e28

admin@infix-ad-00-00:/> ping www.kth.se
PING www.kth.se (130.237.28.40) 56(84) bytes of data.
64 bytes from ns-vip-01.sys.kth.se (130.237.28.40): icmp_seq=1 ttl=240 time=2.34 ms
64 bytes from ns-vip-01.sys.kth.se (130.237.28.40): icmp_seq=2 ttl=240 time=2.24 ms
64 bytes from ns-vip-01.sys.kth.se (130.237.28.40): icmp_seq=3 ttl=240 time=2.27 ms
^C
--- www.kth.se ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 2003ms
rtt min/avg/max/mdev = 2.236/2.282/2.338/0.042 ms
admin@infix-ad-00-00:/>

Then adding a static DNS server. It used, but not reflected by "show dns".

admin@infix-ad-00-00:/> configure 
admin@infix-ad-00-00:/config/> set system dns-resolver server mydns udp-and-tcp address 8.8.8.8
admin@infix-ad-00-00:/config/> leave
admin@infix-ad-00-00:/> show dns
# resolv.conf from e28.conf
nameserver 172.31.11.11 # e28      <== 8.8.8.8 not stated, although used (see tcpdump below)
nameserver 172.31.11.12 # e28

admin@infix-ad-00-00:/> ping www.google.com
PING www.google.com (142.250.74.100) 56(84) bytes of data.
64 bytes from arn11s10-in-f4.1e100.net (142.250.74.100): icmp_seq=1 ttl=115 time=2.42 ms
64 bytes from arn11s10-in-f4.1e100.net (142.250.74.100): icmp_seq=2 ttl=115 time=2.42 ms
^C
--- www.google.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 2.419/2.420/2.422/0.001 ms
admin@infix-ad-00-00:/>

user@pc:~$ sudo tcpdump -n -i eth1 udp
tcpdump: verbose output suppressed, use -v[v]... for full protocol decode
listening on eth1, link-type EN10MB (Ethernet), snapshot length 262144 bytes
08:43:45.752192 IP 198.18.103.193.54379 > 8.8.8.8.53: 21923+ [1au] A? www.google.com. (43)
08:43:45.752243 IP 198.18.103.193.54379 > 8.8.8.8.53: 27087+ [1au] AAAA? www.google.com. (43)
08:43:45.754379 IP 8.8.8.8.53 > 198.18.103.193.54379: 27087 1/0/1 AAAA 2a00:1450:400f:805::2004 (71)
08:43:45.763555 IP 8.8.8.8.53 > 198.18.103.193.54379: 21923 1/0/1 A 142.250.74.68 (59)
08:43:45.766524 IP 198.18.103.193.50403 > 8.8.8.8.53: 64310+ [1au] PTR? 68.74.250.142.in-addr.arpa. (55)
08:43:45.768912 IP 8.8.8.8.53 > 198.18.103.193.50403: 64310 1/0/1 PTR arn09s23-in-f4.1e100.net. (93)
``

@troglobit troglobit added enhancement New feature or request feature Feature request labels Sep 6, 2024
troglobit added a commit that referenced this issue Sep 12, 2024
Before we add proper operational support for DNS and NTP, we can at
least improve on the built-in CLI commands.

Issue #510

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
troglobit added a commit that referenced this issue Sep 12, 2024
Before we add proper operational support for DNS and NTP, we can at
least improve on the built-in CLI commands.

Issue #510

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
troglobit added a commit that referenced this issue Sep 12, 2024
Before we add proper operational support for DNS and NTP, we can at
least improve on the built-in CLI commands.

Issue #510

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
troglobit added a commit that referenced this issue Sep 13, 2024
Before we add proper operational support for DNS and NTP, we can at
least improve on the built-in CLI commands.

Issue #510

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
troglobit added a commit that referenced this issue Sep 13, 2024
Before we add proper operational support for DNS and NTP, we can at
least improve on the built-in CLI commands.

Issue #510

Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
@troglobit troglobit added this to the FUTURE milestone Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request feature Feature request
Projects
Status: No status
Development

No branches or pull requests

2 participants