You do seem to be quite close to a working Ziti service and I agree it looks like DNS isn’t set up on your Ubuntu 20.* host. Are you running a stock DNS configuration or is it customized, if you happen to know?
I believe you are running ziti-edge-tunnel
on the Ubuntu host as a tunneler/proxy. If it’s running then it should have created a tun0
device and started listening for DNS queries. You might have to choose a Ziti service address with at least one stop character .
to ensure the OS recognizes it as a domain name so it can send the query to the Ziti nameserver.
Is Ziti’s tun interface UP?
$ ip link sh up tun0
19: tun0: <POINTOPOINT,MULTICAST,NOARP,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UNKNOWN mode DEFAULT group default qlen 500 link/none
What is Ziti’s nameserver IP?
$ resolvectl --interface=tun0 dns
Link 19 (tun0): 100.64.0.2
Is Ziti DNS answering?
$ nslookup my-app-red 100.64.0.2
Server: 100.64.0.2
Address: 100.64.0.2#53
Non-authoritative answer:
Name: my-app-red
Address: 100.64.0.3
Is my Ziti service working? If my-app-red were an SSH server:
$ ncat 100.64.0.3 22 </dev/null
SSH-2.0-OpenSSH_7.4
Is systemd-resolved configured to try all queries on the Ziti nameserver?
# Ziti resolver has wildcard routing domain
$ resolvectl --interface=tun0 domain
Link 24 (tun0): ~.
Is Linux configured to use systemd-resolved?
# this symlink is one of the ways systemd-resolved can be enabled
$ ls -l /etc/resolv.conf
lrwxrwxrwx 1 root root 37 Mar 1 2021 /etc/resolv.conf -> /run/systemd/resolve/stub-resolv.conf
Re: “stock” vs “custom” DNS
I’m peeking to see how Ubuntu 20 (20.04 Focal?) stock DNS is set up. I’m pretty sure it’s using NetworkManager, but unsure if systemd-resolved or dnsmasq are enabled.
Ultimately, you have to configure Linux to try the Ziti nameserver first then fall back to a recursive/global/next nameserver.
Here’s how a fresh Ubuntu 20.04 (Vagrant box) was set up.
vagrant@ubuntu2004:~$ ll /etc/resolv.conf
lrwxrwxrwx 1 root root 39 Mar 29 22:19 /etc/resolv.conf -> ../run/systemd/resolve/stub-resolv.conf
vagrant@ubuntu2004:~$ grep nameserver /etc/resolv.conf
nameserver 127.0.0.53
vagrant@ubuntu2004:~$ sudo ss -lnup|grep 127.0.0.53
UNCONN 0 0 127.0.0.53%lo:53 0.0.0.0:* users:(("systemd-resolve",pid=505,fd=12))
vagrant@ubuntu2004:~$ resolvectl --interface=tun0 dns
Link 3 (tun0): 100.64.0.2
# no wildcard, but it works anyway?
vagrant@ubuntu2004:~$ resolvectl --interface=tun0 domain
Link 3 (tun0):
vagrant@ubuntu2004:~$ nslookup httpbin.miniziti
Server: 127.0.0.53
Address: 127.0.0.53#53
Non-authoritative answer:
Name: httpbin.miniziti
Address: 100.64.0.3
vagrant@ubuntu2004:~$ curl http://httpbin.miniziti/ip
{"origin":"ziti-edge-router connId=2147483652, logical=ziti-sdk[router=tls://miniziti-router.192.168.49.2.sslip.io:443]"}