* [PATCH pmg-api v2] fix #7187: report: add ethtool output for physical interfaces
@ 2026-05-13 8:22 Erik Fastermann
2026-06-09 6:46 ` Erik Fastermann
2026-06-09 9:46 ` applied: " Thomas Lamprecht
0 siblings, 2 replies; 3+ messages in thread
From: Erik Fastermann @ 2026-05-13 8:22 UTC (permalink / raw)
To: pmg-devel; +Cc: Erik Fastermann
Adding ethtool output to pmg-system-report provides visibility into
actual and supported NIC link speeds, making it much easier to diagnose
network performance issues, negotiation failures, and configuration
mismatches. It also reduces support back-and-forth.
The implementation mirrors the change in pve-manager, as the report
functionality is similar in both projects.
Signed-off-by: Erik Fastermann <e.fastermann@proxmox.com>
---
NOTE: A similar patch was applied to all products:
pmg, pve, pbs, pdm.
changes since v1:
* add a more detailed commit message explaining the rational
* wrap in eval to prevent errors crashing the report
* use PVE::Tools::shellquote to prevent injection errors
src/PMG/Report.pm | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/src/PMG/Report.pm b/src/PMG/Report.pm
index 84d1b88..d5761e0 100644
--- a/src/PMG/Report.pm
+++ b/src/PMG/Report.pm
@@ -4,6 +4,7 @@ use strict;
use warnings;
use Mail::SpamAssassin::DnsResolver;
+use PVE::IPRoute2;
use PVE::Tools;
use PMG::Utils;
@@ -58,6 +59,20 @@ my $report_def = {
],
};
+eval {
+ my $interfaces = PVE::IPRoute2::ip_link_details();
+
+ for my $iface (sort keys %{$interfaces}) {
+ if (PVE::IPRoute2::ip_link_is_physical($interfaces->{$iface})) {
+ push @{ $report_def->{network} }, "ethtool " . PVE::Tools::shellquote($iface);
+ }
+ }
+};
+
+if ($@) {
+ print STDERR "building ethtool commands failed: $@";
+}
+
my @report_order = ('general', 'storage', 'network', 'firewall', 'cluster', 'pmg');
my $report = '';
--
2.47.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH pmg-api v2] fix #7187: report: add ethtool output for physical interfaces
2026-05-13 8:22 [PATCH pmg-api v2] fix #7187: report: add ethtool output for physical interfaces Erik Fastermann
@ 2026-06-09 6:46 ` Erik Fastermann
2026-06-09 9:46 ` applied: " Thomas Lamprecht
1 sibling, 0 replies; 3+ messages in thread
From: Erik Fastermann @ 2026-06-09 6:46 UTC (permalink / raw)
To: pmg-devel
Gentle ping. This patch still cleanly applies on the current master
On 5/13/26 10:21 AM, Erik Fastermann wrote:
> Adding ethtool output to pmg-system-report provides visibility into
> actual and supported NIC link speeds, making it much easier to diagnose
> network performance issues, negotiation failures, and configuration
> mismatches. It also reduces support back-and-forth.
>
> The implementation mirrors the change in pve-manager, as the report
> functionality is similar in both projects.
>
> Signed-off-by: Erik Fastermann <e.fastermann@proxmox.com>
> ---
>
> NOTE: A similar patch was applied to all products:
> pmg, pve, pbs, pdm.
>
> changes since v1:
> * add a more detailed commit message explaining the rational
> * wrap in eval to prevent errors crashing the report
> * use PVE::Tools::shellquote to prevent injection errors
>
> src/PMG/Report.pm | 15 +++++++++++++++
> 1 file changed, 15 insertions(+)
>
> diff --git a/src/PMG/Report.pm b/src/PMG/Report.pm
> index 84d1b88..d5761e0 100644
> --- a/src/PMG/Report.pm
> +++ b/src/PMG/Report.pm
> @@ -4,6 +4,7 @@ use strict;
> use warnings;
> use Mail::SpamAssassin::DnsResolver;
>
> +use PVE::IPRoute2;
> use PVE::Tools;
> use PMG::Utils;
>
> @@ -58,6 +59,20 @@ my $report_def = {
> ],
> };
>
> +eval {
> + my $interfaces = PVE::IPRoute2::ip_link_details();
> +
> + for my $iface (sort keys %{$interfaces}) {
> + if (PVE::IPRoute2::ip_link_is_physical($interfaces->{$iface})) {
> + push @{ $report_def->{network} }, "ethtool " . PVE::Tools::shellquote($iface);
> + }
> + }
> +};
> +
> +if ($@) {
> + print STDERR "building ethtool commands failed: $@";
> +}
> +
> my @report_order = ('general', 'storage', 'network', 'firewall', 'cluster', 'pmg');
>
> my $report = '';
^ permalink raw reply [flat|nested] 3+ messages in thread
* applied: [PATCH pmg-api v2] fix #7187: report: add ethtool output for physical interfaces
2026-05-13 8:22 [PATCH pmg-api v2] fix #7187: report: add ethtool output for physical interfaces Erik Fastermann
2026-06-09 6:46 ` Erik Fastermann
@ 2026-06-09 9:46 ` Thomas Lamprecht
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Lamprecht @ 2026-06-09 9:46 UTC (permalink / raw)
To: pmg-devel, Erik Fastermann
On Wed, 13 May 2026 10:22:52 +0200, Erik Fastermann wrote:
> Adding ethtool output to pmg-system-report provides visibility into
> actual and supported NIC link speeds, making it much easier to diagnose
> network performance issues, negotiation failures, and configuration
> mismatches. It also reduces support back-and-forth.
>
> The implementation mirrors the change in pve-manager, as the report
> functionality is similar in both projects.
>
> [...]
Applied, thanks!
[1/1] fix #7187: report: add ethtool output for physical interfaces
commit: d2696d09d30a253db19701d8a9dcb5d7b39ac943
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2026-06-09 9:46 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-13 8:22 [PATCH pmg-api v2] fix #7187: report: add ethtool output for physical interfaces Erik Fastermann
2026-06-09 6:46 ` Erik Fastermann
2026-06-09 9:46 ` applied: " Thomas Lamprecht
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox