12

resolvectl is no longer part of the bionic systemd package:

bionic search for resolvectl

cosmic search for resolvectl

I'm curious why it was removed and what we should be using as an alternative?

ericx
  • 253
  • 1
  • 3
  • 12

2 Answers2

19

resolvectl was never part of the systemd package in Bionic. Per the systemd changelog, systemd-resolve was renamed to resolvectl in systemd 239, but Bionic has systemd 237. Thus in Bionic it is systemd-resolve.

royarisse
  • 125
fkraiem
  • 12,555
  • 4
  • 35
  • 40
1

The syntax is a bit different from systemd-resolve (please check man resolvectl)

# Reset interface dns settings
sudo resolvectl revert your_interface

Sets your_dns_ip on a your_interface

sudo resolvectl dns your_interface your_dns_ip

Sets your_domain_name on a your_interface

sudo resolvectl domain your_interface your_domain_name

Check

sudo resolvectl dns sudo resolvectl domain

Pablo Bianchi
  • 15,657