From 4aadfb8b765dfe1fab7e3e97ab7772001120453a Mon Sep 17 00:00:00 2001 From: "Maxime Alves LIRMM@home" Date: Mon, 13 Sep 2021 22:55:42 +0200 Subject: [PATCH] [edit] add script to use libvirt dnsmasq's dns --- content/new_vm.rst | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/content/new_vm.rst b/content/new_vm.rst index 5b226d6..18aa9f2 100644 --- a/content/new_vm.rst +++ b/content/new_vm.rst @@ -2,7 +2,7 @@ new virtual machine ################### :date: 2019-11-10 00:00 -:modified: 2019-11-10 00:00 +:modified: 2021-09-13 00:00 :tags: infra :category: documentation :slug: create_vm @@ -383,6 +383,19 @@ DHCP static leases should now execute the following script. "" \ --live --config + + # if you wish to use dnsmasq's dns service, execute also the following + + virsh net-update default add dns-host \ + " \ + ${1} \ + " \ + --live --config + + # you may have to reload the iptables rules if libvirt messes with them + # and if you don't want to restart the machine + + cat /etc/network/iptables|iptables-restore You can now re-start the machine.