[pve-devel] [PATCH pve-manager v2 08/16] nic pinning: improve some informational and error output wording/formatting
Stefan Hanreich
s.hanreich at proxmox.com
Fri Jul 18 18:26:30 CEST 2025
From: Thomas Lamprecht <t.lamprecht at proxmox.com>
Mainly add a trailing \n to die invocations to avoid getting a ugly
"at line XY" in the output.
Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
Signed-off-by: Stefan Hanreich <s.hanreich at proxmox.com>
---
PVE/CLI/proxmox_network_interface_pinning.pm | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/PVE/CLI/proxmox_network_interface_pinning.pm b/PVE/CLI/proxmox_network_interface_pinning.pm
index 4b7f72404..ea98ccb5e 100644
--- a/PVE/CLI/proxmox_network_interface_pinning.pm
+++ b/PVE/CLI/proxmox_network_interface_pinning.pm
@@ -145,10 +145,10 @@ my sub parse_link_file {
$section = $1;
$data->{$section} = {};
} elsif ($line =~ m/^([a-zA-Z]+)=(.+)$/) {
- die "key-value pair before section" if !$section;
+ die "key-value pair before section at line: $line\n" if !$section;
$data->{$section}->{$1} = $2;
} else {
- die "unrecognized line";
+ die "unrecognized line: $line\n";
}
}
@@ -381,18 +381,18 @@ __PACKAGE__->register_method({
);
for my $old_name (sort keys $mapping->%*) {
- print "Renaming link '$old_name' to '$mapping->{$old_name}'\n";
+ print "Name for link '$old_name' will change to '$mapping->{$old_name}'\n";
}
generate_link_files($ip_links, $mapping);
- print "Succesfully generated .link files\n";
+ print "Successfully generated .link files in '/usr/local/lib/systemd/network/'\n";
update_host_fw_config($mapping);
update_etc_network_interfaces($mapping, $existing_pins);
update_sdn_controllers($mapping);
- print "Successfully updated Proxmox VE configuration files\n";
- print "Please reboot to apply the changes to your configuration\n";
+ print "Successfully updated Proxmox VE configuration files.\n";
+ print "\nPlease reboot to apply the changes to your configuration\n\n";
};
PVE::Tools::lock_file($PVEETH_LOCK, 10, $code);
--
2.39.5
More information about the pve-devel
mailing list