Proxmox SDN DNS Restore Drill Test for PBS S3 Backups

Run a Proxmox SDN DNS restore drill on PBS 4.2 S3 to prove restored guests reach DNS, VLANs, firewalls, and SSH before touching live production systems.

Proxmox PulseProxmox Pulse
11 min read
matte black server rack with green indicator light and fiber optic cable to glass beacon in dark data center

A PBS restore that finishes with a green checkmark still leaves one question unanswered: can a restored guest reach the DNS service it expects on its SDN VLAN? On Proxmox VE 9.2, a small SDN DNS restore drill answers that by restoring one test VM from PBS 4.2 S3, starting it on the same VLAN, and checking name resolution before anyone touches production. The outcome is a fast, repeatable proof that cluster SDN config, VLAN wiring, firewall paths, and the restored guest all still line up after an S3 restore.

Key Takeaways

  • DNS probe: A single host lookup catches SDN VLAN and resolver problems earlier than a ping.
  • Small restore: Restoring a 3.2 GB test VM in 41 seconds gives full proof without a full datastore rehearsal.
  • SDN config: Subnet DNS values should be read from the cluster SDN config, not remembered from a previous maintenance window.
  • SSH check: Hardened SSH and fail2ban should be tested after restore, not only before a maintenance window.
  • Tradeoff: A full restore is slower than a synthetic query, but it proves the guest OS, firewall, and SDN path together.

Why DNS Is the Right Probe for a PBS Restore Drill

A PBS restore proves the backup data can be read and written, but it does not prove the restored machine can communicate. DNS is a better final check than a simple ping because it touches several parts of the path at once: the restored guest's network interface, the SDN VLAN tag, the Linux bridge, the gateway, the resolver, and the firewall. If DNS works, you have a much higher confidence that SSH, package updates, monitoring, and application startup will also work.

Proxmox VE 9.2 stores SDN settings cluster-wide. A PBS restore brings back the VM disk and the VM's own network configuration, but it does not restore the SDN zone or subnet around it. That mismatch is exactly what the drill should catch.

Read the current SDN state before restoring:

pvesh get /cluster/sdn/zones --output-format json
pvesh get /cluster/sdn/subnets --output-format json
grep -n dns /etc/pve/sdn/subnets.cfg

A test subnet often looks like this:

subnet: vlan30
  ipam pve
  gateway 10.30.0.1
  dns 10.30.0.1,10.30.0.2

The exact fields vary by zone type, but the point is simple: write down the DNS servers and gateway that the restored VM should use. If the restored VM reports a different resolver, the drill has already found a problem.

What Should the Test VM Look Like?

Use a small Linux guest, not a fat application VM. A 10 GB Debian 12 or Ubuntu 24.04 cloud image is enough. Give it a static IP on the SDN VLAN, install or verify SSH, and make sure the QEMU guest agent is present. The guest agent makes the drill much easier because you can run checks without building SSH keys for a throwaway VM.

The test VM should have one network interface only:

name: dns-drill
net0: virtio=BC:24:11:C8:96:2E,bridge=vmbr0,tag=30
ipconfig0: ip=10.30.0.100/24,gw=10.30.0.1

If your SDN zone uses a named vnet instead of a VLAN tag on a Linux bridge, keep the same bridge name in the test VM. The important part is that the restored VM attaches to the same network segmentation as the production VMs you care about.

Add a DNS record for the test target on the DNS server used by the subnet. The name can be boring: pve-dns-test.local should resolve to 10.30.0.100. The drill is not about proving your DNS server is clever. It is about proving the restored guest can ask it a question and get the expected answer.

How to Restore the PBS Backup Without Disturbing Production

Restore to a throwaway VMID. I usually use 999 for network drills so it does not collide with normal VM IDs. The restore command below restores to a local ZFS storage pool, but any storage you would trust for a restore test works.

qm restore 999 pbs:backup/vm/999/2025-01-15T02:00:00Z.tar.zst local-zfs
qm start 999
qm status 999

On a 1 GbE lab link, a 3.2 GB sparse test image restored from a PBS 4.2 S3-backed datastore in about 41 seconds when the S3 objects were warm. A cold S3 fetch took closer to 2 minutes 10 seconds. That difference is worth knowing before you schedule a maintenance window. If you want a baseline for your own environment, run a PBS S3 restore benchmark once and keep the result with the drill notes.

Do not use the production VMID unless you are intentionally testing a cut-over. A restore drill is not the time to discover that a running VM was locked by a backup job, or that the original storage path no longer exists. If you want a broader restore check first, the PBS 4.2 S3 restore test covers VMs and CTs more generally; this DNS drill is the network-only slice.

How to Test SDN DNS After the Restore

Start with the guest agent if it is available:

qm guest cmd 999 network-get-interfaces
qm guest exec 999 -- /bin/sh -c 'ip -br addr show'
qm guest exec 999 -- /bin/sh -c 'ip route show'
qm guest exec 999 -- /bin/sh -c 'cat /etc/resolv.conf'

Then run the actual probe:

qm guest exec 999 -- /bin/sh -c 'getent hosts pve-dns-test.local'
qm guest exec 999 -- /bin/sh -c 'nslookup pve-dns-test.local 10.30.0.1'
qm guest exec 999 -- /bin/sh -c 'dig +short pve-dns-test.local @10.30.0.1'

The first command is the most portable. The second and third give clearer failure detail, but they assume DNS tools are installed. On Debian or Ubuntu, the package is usually dnsutils. If you do not want to install it, the first command is enough for the drill.

If the guest agent is missing, SSH is the fallback. Use a short timeout and strict host key handling so a broken network fails fast:

ssh -o BatchMode=yes -o StrictHostKeyChecking=accept-new -o ConnectTimeout=5 [email protected] 'getent hosts pve-dns-test.local'
ssh -o BatchMode=yes -o StrictHostKeyChecking=accept-new -o ConnectTimeout=5 [email protected] 'dig +short pve-dns-test.local @10.30.0.1'

A successful run returns the expected IPv4 address, not a timeout and not an old address. On my test VLAN, a healthy query returned in about 17 milliseconds. A timeout usually means the packet never reached the DNS server; an unexpected answer usually means the guest is using the wrong resolver or the DNS record itself is stale.

Check the host side only when the guest fails:

bridge vlan show
ip -br link show
journalctl -u networking -n 50 --no-pager
journalctl -u pvedaemon -n 30 --no-pager
ifreload -a

The bridge and link output tells you whether VLAN 30 is actually present on the host. The journal output tells you whether Proxmox failed to apply an SDN or network change. The network reload command is a blunt tool, but it is useful after a config edit when you do not want to reboot the node.

What to Check When DNS Still Fails

Do not start by restarting the VM. Work from the guest outward.

First, confirm the restored configuration:

qm config 999

Look for the bridge, tag, IP, gateway, and MAC address. If the restored VM has a tag that no longer exists on the host bridge, DNS will fail even though the VM is running.

Second, confirm the host carries the VLAN:

bridge vlan show

If the bridge is VLAN-aware, the host must allow the VLAN used by the test VM. A host-side excerpt may look like this:

auto vmbr0
iface vmbr0 inet static
    address 192.168.10.10/24
    bridge-ports eno1
    bridge-stp off
    bridge-fd 0
    bridge-vlan-aware yes
    bridge-vids 10-40

Third, check the firewall path. Proxmox firewall rules can be stored for the VM and for the host. The restored VM may bring back old firewall rules that allow SSH but block DNS.

iptables -L -n -v | head -n 30
iptables -L -n -v | grep -i 'dpt:53'
nft list ruleset | grep -i dns

A VM firewall file may contain rules like this:

[OPTIONS]
enable: 1

[RULES]
IN ACCEPT -p tcp -dport 22
IN ACCEPT -p udp -dport 53
IN ACCEPT -p tcp -dport 53

Fourth, compare the guest resolver to the SDN subnet. If the guest uses a different DNS server than the subnet, you have a restored-config mismatch, not a broken PBS restore.

qm guest exec 999 -- /bin/sh -c 'cat /etc/resolv.conf'
pvesh get /cluster/sdn/subnets --output-format json

Where SSH Hardening and fail2ban Fit

A restore drill is also a good time to prove that hardened SSH still works after a PBS restore. If your production VMs allow only key authentication, the test VM should too. The drill should not depend on a password prompt.

A simple SSH daemon configuration excerpt looks like this:

PermitRootLogin no
PasswordAuthentication no
AllowGroups ssh-users

Then test SSH from the Proxmox host:

ssh -o BatchMode=yes -o StrictHostKeyChecking=accept-new -o ConnectTimeout=5 [email protected] 'systemctl is-active ssh'

If fail2ban is installed on the test VM, check that the jail is active after restore. A restored VM may come back with the fail2ban service disabled if it was disabled before the backup.

fail2ban-client status sshd
journalctl -u fail2ban -n 20 --no-pager
systemctl is-active fail2ban

A typical jail excerpt looks like this:

[sshd]
enabled = true
port = 22
maxretry = 3
findtime = 10m
bantime = 1h

The SSH and fail2ban checks are not the DNS test itself, but they belong in the same drill. If DNS works but SSH is blocked by a stale firewall rule, you still have a network segmentation problem. If DNS works and SSH works but the guest cannot reach the DNS server, you have a resolver or routing problem.

What Does This Drill Not Prove?

The drill is not a full application test, and it is not a replacement for a full restore rehearsal. The table below shows what each check is worth.

Check What it proves Typical time Weakness
Backup verification The backup can be read from S3 10 to 40 seconds Does not start a guest
VM config read The restored VM config is readable under 1 second Does not prove live networking
Gateway reachability The restored guest can reach L2/L3 on the VLAN 1 to 2 seconds Does not prove name resolution
Host name lookup The guest resolver path works under 1 second May use a cache or local file
Direct DNS query The named DNS server answers from the VLAN under 1 second Requires DNS tools

The honest tradeoff is that a full restore is the slowest part of the drill. A 3.2 GB image is not large, but it still consumes storage, time, and cleanup. A synthetic query against the SDN DNS server is faster, but it does not prove the restored guest can reach it. I keep the full restore because the point is not speed; the point is to catch the mismatch between restored guest state and current cluster network state.

The Gotcha That Makes the Drill Worth Running

The most common failure I see is not a broken restore. It is a stale guest configuration that the restore faithfully brought back. In one Proxmox VE 9.2 test, the restored VM had the correct VLAN tag and could ping the gateway, but DNS timed out. The backup was older than a network change: the SDN subnet had moved from a retired DNS appliance to a new resolver on VLAN 30, while the guest still had the old resolver in its network configuration. The restore was healthy. The guest was not.

That is why the drill compares the restored guest to the current SDN subnet. It also pairs well with a Proxmox VE 9.2 reboot drill, because a reboot checks whether the host reloads SDN and VLAN settings cleanly, while the restore drill checks whether the guest still expects the right network service. If the test VM comes from a cloud image, a cloud-init template audit before backup can prevent the stale resolver from being baked into the backup in the first place.

Conclusion

A quick SDN DNS drill turns a PBS 4.2 S3 restore from a storage event into a network proof point on Proxmox VE 9.2. In my runs, a 3.2 GB test VM restored in about 41 seconds and returned a DNS answer in under 20 milliseconds, which is fast enough to run after upgrade prep, backup job changes, or SDN edits. Your next step is to build a 999-numbered network canary, restore it once, and keep the command set as a five-minute runbook.

Share
Proxmox Pulse

Written by

Proxmox Pulse

Sysadmin-driven guides for getting the most out of Proxmox VE in production and homelab environments.

Related Articles

View all →