Skip to main content
fix typo
Source Link
mpboden
  • 1.7k
  • 1
  • 5
  • 21
$ resolvectl
Global
       Protocols: -LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
resolv.conf mode: stub
     DNS Servers:

Link 2 (enp0s10)
Current Scopes: DNS
     Protocols: +DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
   DNS Servers: 192.168.1.1
    DNS Domain: localdomain

Link 3 (tun0)
Current Scopes: none
     Protocols: +DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 10.12.216.2
       DNS Servers: 10.12.216.2
        DNS Domain: ~. 
        
Link 4 (wlp5s0)
Current Scopes: none
     Protocols: 1DefaultRoute-DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported    
$ resolvectl
Global
       Protocols: -LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
resolv.conf mode: stub
     DNS Servers:

Link 2 (enp0s10)
Current Scopes: DNS
     Protocols: +DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
   DNS Servers: 192.168.1.1
    DNS Domain: localdomain

Link 3 (tun0)
Current Scopes: none
     Protocols: +DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 10.12.216.2
       DNS Servers: 10.12.216.2
        DNS Domain: ~. 
        
Link 4 (wlp5s0)
Current Scopes: none
     Protocols: 1DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported    
$ resolvectl
Global
       Protocols: -LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
resolv.conf mode: stub
     DNS Servers:

Link 2 (enp0s10)
Current Scopes: DNS
     Protocols: +DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
   DNS Servers: 192.168.1.1
    DNS Domain: localdomain

Link 3 (tun0)
Current Scopes: none
     Protocols: +DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 10.12.216.2
       DNS Servers: 10.12.216.2
        DNS Domain: ~. 
        
Link 4 (wlp5s0)
Current Scopes: none
     Protocols: -DefaultRoute +LLMNR -mDNS +DNSOverTLS DNSSEC=no/unsupported    
Fix spelling mistakes
Source Link
mpboden
  • 1.7k
  • 1
  • 5
  • 21

D-Bus is an interprocess communication system that allows messages to be sent to various services. In this case, you want to communicate with systemd-resolved to change DNS settings on individual links instead of just gloaballyglobally with the /etc/systemd/resolved.conf file. There are several ways to communicate with the D-Bus, from a low-level D-Bus API to higher-level bindings. But this can get a bit complicated, so we'll take advantage of a helper script for your openvpn setup to keep things as easy as possible. Within this script, the command, busctl, is used to communicate with the D-Bus and change settings on individual links. This is more informational than useful at this point, because you won't be interacting with busctl directly. That's not to say that you can't or won't in the future, though.

I'd also like to mention that an advantage of editing indidualindividual links instead of defining global DNS settings is that it'll allow more flexibility in the future for situations like Split DNS. I won't go into full detail here, but an explanation of Split DNS as well as routing domains and search domains can be found at these links:

D-Bus is an interprocess communication system that allows messages to be sent to various services. In this case, you want to communicate with systemd-resolved to change DNS settings on individual links instead of just gloabally with the /etc/systemd/resolved.conf file. There are several ways to communicate with the D-Bus, from a low-level D-Bus API to higher-level bindings. But this can get a bit complicated, so we'll take advantage of a helper script for your openvpn setup to keep things as easy as possible. Within this script, the command, busctl, is used to communicate with the D-Bus and change settings on individual links. This is more informational than useful at this point, because you won't be interacting with busctl directly. That's not to say that you can't or won't in the future, though.

I'd also like to mention that an advantage of editing indidual links instead of defining global DNS settings is that it'll allow more flexibility in the future for situations like Split DNS. I won't go into full detail here, but an explanation of Split DNS as well as routing domains and search domains can be found at these links:

D-Bus is an interprocess communication system that allows messages to be sent to various services. In this case, you want to communicate with systemd-resolved to change DNS settings on individual links instead of just globally with the /etc/systemd/resolved.conf file. There are several ways to communicate with the D-Bus, from a low-level D-Bus API to higher-level bindings. But this can get a bit complicated, so we'll take advantage of a helper script for your openvpn setup to keep things as easy as possible. Within this script, the command, busctl, is used to communicate with the D-Bus and change settings on individual links. This is more informational than useful at this point, because you won't be interacting with busctl directly. That's not to say that you can't or won't in the future, though.

I'd also like to mention that an advantage of editing individual links instead of defining global DNS settings is that it'll allow more flexibility in the future for situations like Split DNS. I won't go into full detail here, but an explanation of Split DNS as well as routing domains and search domains can be found at these links:

fix spelling mistake
Source Link
mpboden
  • 1.7k
  • 1
  • 5
  • 21

And don't foregetforget to delete or comment out dhcp-option DNS 10.12.216.2 that's currently in your .ovpn file.

After the changes, your .ovpn file should look like the follwingfollowing:

And don't foreget to delete or comment out dhcp-option DNS 10.12.216.2 that's currently in your .ovpn file.

After the changes, your .ovpn file should look like the follwing:

And don't forget to delete or comment out dhcp-option DNS 10.12.216.2 that's currently in your .ovpn file.

After the changes, your .ovpn file should look like the following:

Source Link
mpboden
  • 1.7k
  • 1
  • 5
  • 21
Loading