From: Alexandre Derumier <aderumier@odiso.com>
To: pve-devel@lists.proxmox.com
Subject: [pve-devel] [qemu-server 1/1] add_next_free_cidr: remove old dhcprange param
Date: Thu, 4 Jan 2024 17:27:28 +0100 [thread overview]
Message-ID: <20240104162733.4152467-2-aderumier@odiso.com> (raw)
In-Reply-To: <20240104162733.4152467-1-aderumier@odiso.com>
Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
---
PVE/QemuServer.pm | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm
index 600d0a8..a00e09e 100644
--- a/PVE/QemuServer.pm
+++ b/PVE/QemuServer.pm
@@ -5279,7 +5279,7 @@ sub vmconfig_apply_pending {
}
}
#fixme: reuse ip if mac change && same bridge
- PVE::Network::SDN::Vnets::add_next_free_cidr($new_net->{bridge}, $conf->{name}, $new_net->{macaddr}, $vmid, undef, 1);
+ PVE::Network::SDN::Vnets::add_next_free_cidr($new_net->{bridge}, $conf->{name}, $new_net->{macaddr}, $vmid);
}
}
};
@@ -5349,7 +5349,7 @@ sub vmconfig_update_net {
if (safe_string_ne($oldnet->{bridge}, $newnet->{bridge})) {
if ($have_sdn) {
PVE::Network::SDN::Vnets::del_ips_from_mac($oldnet->{bridge}, $oldnet->{macaddr}, $conf->{name});
- PVE::Network::SDN::Vnets::add_next_free_cidr($newnet->{bridge}, $conf->{name}, $newnet->{macaddr}, $vmid, undef, 1);
+ PVE::Network::SDN::Vnets::add_next_free_cidr($newnet->{bridge}, $conf->{name}, $newnet->{macaddr}, $vmid);
}
}
@@ -5381,7 +5381,7 @@ sub vmconfig_update_net {
if ($hotplug) {
if ($have_sdn) {
- PVE::Network::SDN::Vnets::add_next_free_cidr($newnet->{bridge}, $conf->{name}, $newnet->{macaddr}, $vmid, undef, 1);
+ PVE::Network::SDN::Vnets::add_next_free_cidr($newnet->{bridge}, $conf->{name}, $newnet->{macaddr}, $vmid);
PVE::Network::SDN::Vnets::add_dhcp_mapping($newnet->{bridge}, $newnet->{macaddr}, $vmid, $conf->{name});
}
vm_deviceplug($storecfg, $conf, $vmid, $opt, $newnet, $arch, $machine_type);
@@ -8691,7 +8691,7 @@ sub create_ifaces_ipams_ips {
if ($opt =~ m/^net(\d+)$/) {
my $value = $conf->{$opt};
my $net = PVE::QemuServer::parse_net($value);
- eval { PVE::Network::SDN::Vnets::add_next_free_cidr($net->{bridge}, $conf->{name}, $net->{macaddr}, $vmid, undef, 1) };
+ eval { PVE::Network::SDN::Vnets::add_next_free_cidr($net->{bridge}, $conf->{name}, $net->{macaddr}, $vmid) };
warn $@ if $@;
}
}
--
2.39.2
next prev parent reply other threads:[~2024-01-04 16:27 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-01-04 16:27 [pve-devel] [pve-network/qemu-server/pve-container/pve-manager] RFC: use ipam without dhcp Alexandre Derumier
2024-01-04 16:27 ` Alexandre Derumier [this message]
2024-01-04 16:27 ` [pve-devel] [pve-manager 1/1] sdn: zones: add ipam reservation option Alexandre Derumier
2024-01-04 16:27 ` [pve-devel] [pve-network 1/4] vnets: use ipam without dhcp Alexandre Derumier
2024-01-04 16:27 ` [pve-devel] [pve-network 2/4] vnets: add_next_free_cidr : skip if ipamreservation is not defined Alexandre Derumier
2024-01-04 16:27 ` [pve-devel] [pve-network 3/4] subnets: call add_range_next_freeip only if dhcp is defined Alexandre Derumier
2024-01-04 16:27 ` [pve-devel] [pve-network 4/4] api2: ipam status: display ipam zones without dhcp flag Alexandre Derumier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240104162733.4152467-2-aderumier@odiso.com \
--to=aderumier@odiso.com \
--cc=pve-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.