惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

S
Schneier on Security
The Hacker News
The Hacker News
S
Securelist
C
Cybersecurity and Infrastructure Security Agency CISA
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
C
CXSECURITY Database RSS Feed - CXSecurity.com
L
Lohrmann on Cybersecurity
P
Proofpoint News Feed
Project Zero
Project Zero
K
Kaspersky official blog
C
CERT Recently Published Vulnerability Notes
Scott Helme
Scott Helme
T
The Exploit Database - CXSecurity.com
T
Threat Research - Cisco Blogs
Spread Privacy
Spread Privacy
A
Arctic Wolf
量子位
云风的 BLOG
云风的 BLOG
H
Help Net Security
爱范儿
爱范儿
博客园 - 三生石上(FineUI控件)
美团技术团队
博客园_首页
AWS News Blog
AWS News Blog
人人都是产品经理
人人都是产品经理
Google DeepMind News
Google DeepMind News
G
GRAHAM CLULEY
P
Privacy & Cybersecurity Law Blog
Hugging Face - Blog
Hugging Face - Blog
P
Privacy International News Feed
N
Netflix TechBlog - Medium
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
大猫的无限游戏
大猫的无限游戏
罗磊的独立博客
T
Tenable Blog
B
Blog
P
Palo Alto Networks Blog
Latest news
Latest news
J
Java Code Geeks
The Cloudflare Blog
NISL@THU
NISL@THU
Blog — PlanetScale
Blog — PlanetScale
有赞技术团队
有赞技术团队
V
V2EX
Apple Machine Learning Research
Apple Machine Learning Research
Security Latest
Security Latest
The GitHub Blog
The GitHub Blog
L
LINUX DO - 热门话题
T
Threatpost
H
Hackread – Cybersecurity News, Data Breaches, AI and More

Proxmox Support Forum

[SOLVED] - Github Auth for Mirrors-Kernel Repo? [Automation] Mass migration tool for MS Win11/Server Proxmox GUI hang - not response is it possible to reject or quarantine spam based on conditions I set ? The PVENode task list in PVE9 is partially obscured due to the terminal font being too large. About 100% error reporting due to pveproxy.service hooks Kubernetes overlay networking breaks when upgrading from PVE 9.1 to PVE 9.2.3 Zentraler Speicher No space left on device Combine datastore and direct file archival to tape Kernel panic VFS: Unable to mount root fs on unknown-block (0,0) sobald ein 7.x Kernel verwendet wird. How to migrate disk of a VM from one ZFS to another Windows Server 2025 fails to boot after PVE 9.2 / Linux 7.0 Kernel upgrade Cannot Install Proxmox on T610 Poweredge with H700 PERC card sdn Config. gateway not reachable How to safely change domain/FQDN? Welche Filterquote erreicht ihr? NFS Share status unknown on 2 of 5 nodes Can't connect to PVE9 consoles [solved] Can't connect to PVE9 consoles [solved] [SOLVED] - Use secondary network for PVE commands Created cluster, one node storage gone BUG: proxmox mail gateway FROM = null bypass spam filtering Moving existing PBS from VMWare workstation to PVE cluster Does eBGP SDN fabric support external peering? Bug: PDM 1.1 not recognizing valid license status Proxmox GUI hang - not response PVE crashes unexpectedly Proxmox Backup Server 4.2 released! Advice ceph-osd crashes with kernel 6.17.2-1-pve on Dell system [META] Links on Proxmox Forum Website Hardwarer oder Software RAID Joining a cluster with already created guests VM PDM missing backup jobs from PVE / Log retention Remove VM.Monitor from all users/roles, PVE 9.2 Proxmox Freezing (new instalation) 9.2.2 - Intel 12700T No Web gui and random connection reset by peer [SOLVED] - i40e module for X710 Intel NIC Dutch Proxmox Day 2026 How pools use the space Corosync initiiert Reboot trotz Verfügbarkeit der Systeme Opt-in Linux 7.0 Kernel for Proxmox VE 9 available After PVE 8to9 upgrade, unable to check guest fs freeze status Problem with MegaRAID SAS3508 controller proxmox-kernel-7.0.2-6-pve failing network service Auto sync guest time after rollback of VM snapshot with RAM/state Broadcom BCM57504 (100G) bnxt_en TX timeout and NIC reset on Proxmox 8.1.5 — while BCM57414 (25G) works fine on same host QEMU 11.0 available on pve-test and pve-no-subscription as of now 350 MPM Solventless Lamination Machine for High-Speed Flexible Packaging Making sense of NVMe zfs and SMART errors [SOLVED] - PVE loses network connection after kernel upgrade to proxmox-kernel-7.0.0-3-pve [SOLVED] - Remove or reset cluster configuration. Proxmox 8.4.1 Fresh Install BCM57416 10G Ethernet Adapter Not Recognized PDM 1.1.1 unable to add AD realm with anonymous search [TUTORIAL] - Developer Workstation (Proxmox-VE 9) with cinnamon (LMDE7) SDN zone shows "pending" on peer nodes after node reboot (9.2.x) Cluster not quorate - extending auth key lifetime! Proxmox not rebooting properly (SOLVED) Proxmox 9 Stuck on loading initial ramdisk With new HA-Disarm Feature is there a Documentation for NUT Setup on Clusters? Proxmox 8.3 Installation Issue on ProLiant DL380 Gen9 Cluster networking setup LXC System images unavailable [SOLVED] - Fix: NVIDIA Drivers Failing after upgrade to Proxmox 9.2.2 (Kernel 7.0.2-6-pve) / NovaCore Conflict Install NUT directly on Proxmox VE and control guests from here driver usb for windows 7 System startup error and no network: Failed to start ifupdown2-pre.service - Helper to synchronize boot up for ifupdown. PBS backup space grow up constantly Proxmox Datacenter Manager 1.1 released! IPv4 not available in newly created VM Recommended Setup for Offsite Proxmox Backups? Hetzner Storage Box & Remote PBS Challenges duplicate, please delete this passthrought an USB device "by ID" to CT PDM Installer Freezes at 66% Tried PDM for the first time (version 1.1) - had issues PDM 1.1 automated install Suche Server-Provider für Proxmox connecting sdn to edge firewall SDN, IPAM & DHCP Migrating from read-only file system Ubuntu 26.04 installation fails for unknown reason Status Unbekannt nach Cluster Join Installing Proxmox Backup Server on Mac Mini (Late 2012) kernel 7.0 performance issue with zfs pools PVE becomes unreachable via ethernet but OS is running [SOLVED] - New 9.2 install - can't find 7.0.2-6-pve , not all the time [SOLVED] - Backup and dedupe a VM with LUKS Gibt es mit PVE 2.x ggf. Änderungen bei der RAM-Nutzung, bzw. deren Anzeige bei VMs? I need help for setting up backup solution Way more NAGware, very little functionality, bugs galore Root squashing virtiofsd with --uid-map Intel ixgbe Driver Update Fail Passkey Login (not 2FA) Roblox VM detection - can be overcome? [TUTORIAL] - ZFS-Autosnaptshot inkl. Rollback und Daten direkt recovern (Windows/Linux) How to stop PVE Kernel upgrade [SOLVED] - very long waiting to log in to lxc debian 11 ssh [TUTORIAL] - Configuring Fusion-Io (SanDisk) ioDrive, ioDrive2, ioScale and ioScale2 cards with Proxmox Increase maximum USB devices in vm.conf
Proxmox 9 cloud-init and Debian 13 (Trixie) fails to set DNS
invalid@exam · 2026-06-15 · via Proxmox Support Forum

Hello.

Debian 13 uses cloud-init version 25.1.4. This version uses a different structure to configure DNS servers.

Proxmox 9 cloud-init generate files from previous version that doesn't work to set DNS servers for Debian 13.

Hope Proxmox fix its file structure for cloud-init.

Thanks!

same here

pve host

Code:

$ pveversion
pve-manager/9.0.6/49c767b70aeb6648 (running kernel: 6.14.11-1-pve)

Code:

$ qm cloudinit dump 100 network
version: 1
config:
    - type: physical
      name: eth0
      mac_address: 'xx:xx:xx:xx:xx:xx'
      subnets:
      - type: static
        address: '192.168.1.150'
        netmask: '255.255.255.0'
        gateway: '192.168.1.1'
    - type: nameserver
      address:
      - '9.9.9.9'
      - '8.8.8.8'
      search:
      - 'xyz.local'

Debian 13 vm

Code:

$ lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 13 (trixie)
Release:        13
Codename:       trixie

Code:

$ cloud-init --version
/usr/bin/cloud-init 25.1.4

Code:

$ cat /etc/resolv.conf
# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
#     DO NOT EDIT THIS FILE BY HAND -- YOUR CHANGES WILL BE OVERWRITTEN

Code:

$ resolvconf --version
Debian resolvconf 1.94
Copyright:
  2003-2017 Thomas Hood <jdthood@gmail.com>
License: GPL-2+

Code:

$ cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

source /etc/network/interfaces.d/*

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug ens18
iface ens18 inet dhcp
# This is an autoconfigured IPv6 interface
iface ens18 inet6 auto

Code:

$ cat /etc/network/interfaces.d/50-cloud-init
# This file is generated from information provided by the datasource.  Changes
# to it will not persist across an instance reboot.  To disable cloud-init's
# network configuration capabilities, write a file
# /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:
# network: {config: disabled}
auto lo
iface lo inet loopback
    dns-nameservers 9.9.9.9 8.8.8.8
    dns-search xyz.local

auto eth0
iface eth0 inet static
    address 192.168.1.150/24
    gateway 192.168.1.1

Code:

$ ip addr show eth0
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether xx:xx:xx:xx:xx:xx brd ff:ff:ff:ff:ff:ff
    altname enp0s18
    altname enxbc241100ffbc
    altname ens18
    inet 192.168.1.150/24 brd 192.168.1.255 scope global eth0
       valid_lft forever preferred_lft forever
    inet6 fdf8:9a78:f086:e900:be24:11ff:fe00:ffbc/64 scope global dynamic mngtmpaddr proto kernel_ra
       valid_lft 7087sec preferred_lft 3487sec
    inet6 fe80::be24:11ff:fe00:ffbc/64 scope link proto kernel_ll
       valid_lft forever preferred_lft forever

Code:

$ cloud-init status --long
status: done
extended_status: done
boot_status_code: enabled-by-generator
last_update: Thu, 01 Jan 1970 00:00:25 +0000
detail: DataSourceNoCloud [seed=/dev/sr0]
errors: []
recoverable_errors: {}

I have had no problems using cloud-init in PVE9 to create a Debian 13 VM (server) based on the cloud image (https://cloud.debian.org/images/cloud/trixie/latest/debian-13-genericcloud-amd64.qcow2).
I should point out that I do not set any DNS settings, only user, password & NW/GW.

I suspect you weren't using a cloud image based on your output.
For example: In the created Debian Trixie VM, I get

Code:

root@Copy-of-VM-Debian-Trixie-CloudINIT-Template:~# resolvconf --version
systemd 257 (257.7-1)
+PAM +AUDIT +SELINUX +APPARMOR +IMA +IPE +SMACK +SECCOMP +GCRYPT -GNUTLS +OPENSSL +ACL +BLKID +CURL +ELFUTILS +FIDO2 +IDN2 -IDN +IPTC +KMOD +LIBCRYPTSETUP +LIBCRYPTSETUP_PLUGINS +LIBFDISK +PCRE2 +PWQUALITY +P11KIT +QRENCODE +TPM2 +BZIP2 +LZ4 +XZ +ZLIB +ZSTD +BPF_FRAMEWORK +BTF -XKBCOMMON -UTMP +SYSVINIT +LIBARCHIVE

However Proxmox is using an outdated version of Cloud-init, as if you set a User (possibly even if you don't) you will get a warning:

Code:

root@Copy-of-VM-Debian-Trixie-CloudINIT-Template:~# cloud-init status --long
status: done
extended_status: degraded done
boot_status_code: enabled-by-generator
last_update: Thu, 01 Jan 1970 00:00:08 +0000
detail: DataSourceNoCloud [seed=/dev/sr0]
errors: []
recoverable_errors:
DEPRECATED:
        - 'user' of type string is deprecated in 22.2 and scheduled to be removed in 27.2. Use 'users' list instead.
        - 'user' of type string is deprecated in 22.2 and scheduled to be removed in 27.2. Use 'users' list instead.

This has already been posted here.

I suspect you weren't using a cloud image based on your output.

Yep, that's what I suspect too.

Also, in the cloud image I'm using (https://cdimage.debian.org/cdimage/cloud/trixie/latest/debian-13-generic-amd64.raw) there's no /etc/network/interfaces.d/50-cloud-init file, but rather /etc/netplan/50-cloud-init.yaml, which looks like this in the VM:

YAML:

network:
  version: 2
  ethernets:
    eth0:
      match:
        macaddress: "xx:xx:xx:xx:xx:xx"
      addresses:
      - "192.168.220.116/24"
      nameservers:
        addresses:
        - 192.168.220.1
        search:
        - local.mydomain.tld
      set-name: "eth0"
      routes:
      - to: "default"
        via: "192.168.220.1"

And it seems to work:

Code:

root@trixie:/etc/cloud# resolvectl status
Global
         Protocols: +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
  resolv.conf mode: uplink

Link 2 (eth0)
    Current Scopes: DNS LLMNR/IPv4 LLMNR/IPv6
         Protocols: +DefaultRoute +LLMNR -mDNS -DNSOverTLS DNSSEC=no/unsupported
Current DNS Server: 192.168.220.1
       DNS Servers: 192.168.220.1
        DNS Domain: local.mydomain.tld
     Default Route: yes
root@trixie:/etc/cloud# resolvectl show-server-state 
Server: 192.168.220.1                        
                              Type: link
                         Interface: eth0
                   Interface Index: 2
            Verified feature level: UDP+EDNS0
            Possible feature level: UDP+EDNS0
                       DNSSEC Mode: no
                  DNSSEC Supported: yes
Maximum UDP fragment size received: 512
               Failed UDP attempts: 0
               Failed TCP attempts: 0
             Seen truncated packet: no
          Seen OPT RR getting lost: no
             Seen RRSIG RR missing: no
               Seen invalid packet: no
            Server dropped DO flag: no

So, for DNS configuration to apply correctly, the systemd-resolved package must be installed.

Yes, but as far as I understand it, that should already be pre-installed in the cloud images and then be used by Netplan by default. For me, at least, it worked out of the box without having to install the systemd-resolved package manually via virt-customize beforehand.

Last edited:

that should already be pre-installed in the cloud images

no it is not installed by default in debian cloud images

no it is not installed by default in debian cloud images

Then, it gets installed by default, at least with the Trixie RAW images, because it is installed in my Trixie test VM, and I definitely didn't install it via virt-customize or manually in the VM after it was up and running.

I create my test VMs via a script using qm create and qm importdisk, and the netweork setings are set like this:

Code:

qm set $VMID --nameserver 192.168.220.1
qm set $VMID --ipconfig0 ip=192.168.220.$VMID/24,gw=192.168.220.1

Im using the following Cloud Image: https://cdimage.debian.org/cdimage/cloud/trixie/latest/debian-13-generic-amd64.raw

Last edited:

The only difference possible, are you choosing to Update packages Yes within the cloud-init?

The only difference possible, are you choosing to Update packages Yes within the cloud-init?

yes, it is enabled by default

When I set --nameserver and --searchdomain to a VM, it will render to loopback interface in /etc/network/interfaces.d/50-cloud-init
I can capture these values into /etc/cloud/cloud.cfgto update resolv.conf

So it looks like

Code:

> more /etc/cloud/cloud.cfg
...
runcmd:
  - sh -c '
      grep -E "^\s+dns-nameservers\s" /etc/network/interfaces.d/50-cloud-init | sed -E "s/^\s*dns-(nameservers)/nameserver/g" > /etc/resolvconf/resolv.conf.d/base;
      grep -E "^\s+dns-search\s" /etc/network/interfaces.d/50-cloud-init | sed -E "s/^\s*dns-(search)/\1/g" >> /etc/resolvconf/resolv.conf.d/base;
      resolvconf -u;
      echo "DNS Updated via cloud-init cmd."
    '

Note: You have to install resolvconf first

Last edited:

Hi everyone.
I recently found this issue when setting my homelab and I created a small workaround.

It's a shell script that corrects the generated interfaces file by moving the DNS directives from the lo interface to the physical interface.
Also, it sets a systemd service that invokes the script at the right moment — after cloud-init-local.service writes the network file and before networking.service brings up the interfaces.

The script can also be invoked directly at package install time to fix already-running VMs without requiring a reboot.
I tried to do it as innocuous as possible.

Here's the repo. I hope you find it useful.

Best regards
Zeke

When I set --nameserver and --searchdomain to a VM, it will render to loopback interface in /etc/network/interfaces.d/50-cloud-init

This is the cause that also prevents systemd-resolved from working with cloud-init on Debian 13, at least when assuming ifupdown being used for VM network configuration (the default, and also used on our own images).

In the helper ifupdown script located at /etc/network/if-up.d/resolved, there's a special exemption for the lo interface, which prevents any dns-nameservers for that interface to become effective.

During my investigation, I noticed that /usr/share/doc/cloud-init/examples/network-config-v1-nameserver.yaml uses this notation to explicitly bind the generated dns-nameserver configuration to a named interface:

Code:

network:
  version: 1
  config:
    - type: physical
      name: interface0
      mac_address: '00:11:22:33:44:55'
      subnets:
         - type: static
           address: 192.168.23.14/27
           gateway: 192.168.23.1
    - type: nameserver
      interface: interface0  # Ties nameserver to interface0 only ## <<< THIS HERE ##
      address:
        - 192.168.23.2
        - 8.8.8.8
      search:
        - exemplary

I am not yet sure where in PVE this should be rectified, if at all. I guess it depends if there's cloud-init versions out there that break existing configs if the cloud-init drive's network config -type: nameserver stanza contains a interface: some_value key...

Last edited:

OK, so I came up with this brief patch against PVE/QemuServer/Cloudinit.pm:

Code:

diff --git a/src/PVE/QemuServer/Cloudinit.pm b/src/PVE/QemuServer/Cloudinit.pm
index c1311da8..b3d2e9e2 100644
--- a/src/PVE/QemuServer/Cloudinit.pm
+++ b/src/PVE/QemuServer/Cloudinit.pm
@@ -564,6 +564,10 @@ sub nocloud_network {
     my ($searchdomains, $nameservers) = get_dns_conf($conf);
     if ($searchdomains || $nameservers) {
         $content .= "${i}- type: nameserver\n";
+        if (defined(my $first_non_lo_iface = (sort { $a lt $b } @ifaces)[0])) {
+            (my $first_iface_idx = $first_non_lo_iface) =~ s/^net//;
+            $content .= "${i}  interface: eth${first_iface_idx}\n";
+        }
         if (defined($nameservers) && @$nameservers) {
             $content .= "${i}  address:\n";
             $content .= "${i}  - '$_'\n" foreach @$nameservers;

... which, after restarting pvedaemon.service on the PVE node, generates YAML on the cidata drive as expected, and structurally equivalent to the Debian-provided cloud-init example as mentioned before - let's take another look at it for good measure:

Code:

network:
  version: 1
  config:
    - type: physical
      name: interface0
      mac_address: '00:11:22:33:44:55'
      subnets:
         - type: static
           address: 192.168.23.14/27
           gateway: 192.168.23.1
    - type: nameserver
      interface: interface0  # Ties nameserver to interface0 only
      address:
        - 192.168.23.2
        - 8.8.8.8
      search:
        - exemplary

The equivalent of these settings passed in via PVE's cloud-init support will result in this file and content on cidata ISO fs (I also chose to configure IPv6 via DHCPv6, fwiw):

Code:

$ cat /media/cdrom0/network-config  
version: 1
config:
    - type: physical
      name: eth0
      mac_address: 'bc:24:11:11:22:33'
      subnets:
      - type: static
        address: '192.168.23.14/27'
        gateway: '192.168.23.1'
      - type: dhcp6
    - type: nameserver
      interface: eth0
      address:
      - '192.168.23.2'
      - '8.8.8.8'
      search:
      - 'exemplary'

... but when cloud-init on a Debian 13 host is tasked with rendering its "eni" stuff, THIS JUNK is what comes out as soon as an "interface" key with a valid interface value is present in the resulting dict:

Code:

$ cat /etc/network/interfaces.d/50-cloud-init
# This file is generated from information provided by the datasource.  Changes
# to it will not persist across an instance reboot.  To disable cloud-init's
# network configuration capabilities, write a file
# /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:
# network: {config: disabled}
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
    address 192.168.23.13/24
    gateway 192.168.23.1
    dns {'nameservers': ['8.8.8.8', '192.168.23.3'], 'search': ['exemplary']}

# control-alias eth0
iface eth0 inet6 dhcp

... which, afaiui, suggests a bug in the eni renderer of cloud-init as provided by Debian 13.

My disappointment is immeasurable and my day is ruined.

Here I generated this /etc/network/interfaces.d/50-cloud-init script to workaround this ridiculous issue when setting static IP in cloud-init for a debian 13 guest vm, while not touching the setup when configured DHCP:

Bash:

#!/bin/sh

CFG=/etc/network/interfaces.d/50-cloud-init

[ -f "$CFG" ] || exit 0

# Skip DHCP configurations
grep -q "iface .* inet dhcp" "$CFG" && exit 0

DNS=$(awk '/dns-nameservers/ {for(i=2;i<=NF;i++) print $i}' "$CFG")
SEARCH=$(awk '/dns-search/ {print $2}' "$CFG")

[ -n "$DNS" ] || exit 0

{
    echo "# Generated from cloud-init network config"
    [ -n "$SEARCH" ] && echo "search $SEARCH"

    for ns in $DNS; do
        echo "nameserver $ns"
    done
} > /etc/resolv.conf