I would like to have Proxmox resolve its local name itself, without querying an external DNS. A (common) Debian system should actually be able to do this. However, my PVE (a Debian "onTop" installation) doesn't do that.
My PVE has (as an example) the following names in the
"/etc/hosts" are entered:
127.0.0.1 localhost
192.168.1.1 pve.domain.org pve
192.168.100.100 pve100.local pve100
"host pve", "host pve100" and "host pve100.local" ("host pve" also) each return:
"Host {yxz} not found: 3(NXDOMAIN)"
This is initially correct because external name servers are entered in "/etc/resolv.conf", which of course cannot resolve internal names.
However, according to "/etc/nsswitch.conf" the PVE is instructed to
first query its local entries (files) and only then the DNS from "/etc/resolv.conf":
passwd: files systemd sss
group: files systemd sss
shadow: files sss
gshadow: files
hosts: files mdns4_minimal [NOTFOUND=return] dns
networks: files
protocols: db files
services: db files sss
ethers: db files
rpc: db files
netgroup: nis sss
sudoers: files sss
However, when making requests via "host", the external DNS is apparently queried and the local entries in "/etc/hosts" are apparently ignored.
However, queries via "getent hosts" provide correct answers, and the "/etc/hosts" is apparently also evaluated correctly by the PVE to the extent that the host name of the PVE ("hostname -f") appears to be correct:
pve.domain.org
(but only the first line)
Is this behavior correct so far?
How do I get Proxmox to resolve its own name without having to query a separate DNS?
Thank you very much and greetings
My PVE has (as an example) the following names in the
"/etc/hosts" are entered:
127.0.0.1 localhost
192.168.1.1 pve.domain.org pve
192.168.100.100 pve100.local pve100
"host pve", "host pve100" and "host pve100.local" ("host pve" also) each return:
"Host {yxz} not found: 3(NXDOMAIN)"
This is initially correct because external name servers are entered in "/etc/resolv.conf", which of course cannot resolve internal names.
However, according to "/etc/nsswitch.conf" the PVE is instructed to
first query its local entries (files) and only then the DNS from "/etc/resolv.conf":
passwd: files systemd sss
group: files systemd sss
shadow: files sss
gshadow: files
hosts: files mdns4_minimal [NOTFOUND=return] dns
networks: files
protocols: db files
services: db files sss
ethers: db files
rpc: db files
netgroup: nis sss
sudoers: files sss
However, when making requests via "host", the external DNS is apparently queried and the local entries in "/etc/hosts" are apparently ignored.
However, queries via "getent hosts" provide correct answers, and the "/etc/hosts" is apparently also evaluated correctly by the PVE to the extent that the host name of the PVE ("hostname -f") appears to be correct:
pve.domain.org
(but only the first line)
Is this behavior correct so far?
How do I get Proxmox to resolve its own name without having to query a separate DNS?
Thank you very much and greetings
Last edited: