public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
* [PATCH pve-container] lxc: pass hostname correctly when giving up an ip address
@ 2026-08-19 13:34 Hannes Laimer
  2026-10-23 11:29 ` Elias Huhsovitz
  0 siblings, 1 reply; 2+ messages in thread
From: Hannes Laimer @ 2026-08-19 13:34 UTC (permalink / raw)
  To: pve-devel

A container has no `name`, only a `hostname`. This led to left behind
DNS records.

Signed-off-by: Hannes Laimer <h.laimer@proxmox.com>
---
 src/PVE/LXC/Config.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/PVE/LXC/Config.pm b/src/PVE/LXC/Config.pm
index 7c81834..41dd22f 100644
--- a/src/PVE/LXC/Config.pm
+++ b/src/PVE/LXC/Config.pm
@@ -1850,7 +1850,7 @@ sub vmconfig_apply_pending {
                             PVE::Network::SDN::Vnets::del_ips_from_mac(
                                 $old_net->{bridge},
                                 $old_net->{hwaddr},
-                                $conf->{name},
+                                $conf->{hostname},
                             );
                             PVE::Network::SDN::Vnets::add_next_free_cidr(
                                 $net->{bridge},
-- 
2.47.3





^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH pve-container] lxc: pass hostname correctly when giving up an ip address
  2026-08-19 13:34 [PATCH pve-container] lxc: pass hostname correctly when giving up an ip address Hannes Laimer
@ 2026-10-23 11:29 ` Elias Huhsovitz
  0 siblings, 0 replies; 2+ messages in thread
From: Elias Huhsovitz @ 2026-10-23 11:29 UTC (permalink / raw)
  To: Hannes Laimer, pve-devel

Needs rebase onto master.

I was unable to find any mention of a container 'name' in the guest config.

I checked the config for all of my containers, and the $conf in 
always contains a 'hostname' key, never a 'name'.

So consider this

Reviewed-by: Elias Huhsovitz <e.huhsovitz@proxmox.com>
Tested-by: Elias Huhsovitz <e.huhsovitz@proxmox.com>

On Wed Aug 19, 2026 at 3:34 PM CEST, Hannes Laimer wrote:
> A container has no `name`, only a `hostname`. This led to left behind
> DNS records.
>
> Signed-off-by: Hannes Laimer <h.laimer@proxmox.com>
> ---
>  src/PVE/LXC/Config.pm | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/PVE/LXC/Config.pm b/src/PVE/LXC/Config.pm
> index 7c81834..41dd22f 100644
> --- a/src/PVE/LXC/Config.pm
> +++ b/src/PVE/LXC/Config.pm
> @@ -1850,7 +1850,7 @@ sub vmconfig_apply_pending {
>                              PVE::Network::SDN::Vnets::del_ips_from_mac(
>                                  $old_net->{bridge},
>                                  $old_net->{hwaddr},
> -                                $conf->{name},
> +                                $conf->{hostname},
>                              );
>                              PVE::Network::SDN::Vnets::add_next_free_cidr(
>                                  $net->{bridge},





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-10-23 11:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-19 13:34 [PATCH pve-container] lxc: pass hostname correctly when giving up an ip address Hannes Laimer
2026-10-23 11:29 ` Elias Huhsovitz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal