diff --git a/internal/cli/cmd/sysdump.go b/internal/cli/cmd/sysdump.go index 0b8dd46a11..9e29a9c010 100644 --- a/internal/cli/cmd/sysdump.go +++ b/internal/cli/cmd/sysdump.go @@ -32,7 +32,7 @@ func newCmdSysdump() *cobra.Command { // Silence klog to avoid displaying "throttling" messages - those are expected. klog.SetOutput(io.Discard) // Collect the sysdump. - collector, err := sysdump.NewCollector(k8sClient, sysdumpOptions, time.Now()) + collector, err := sysdump.NewCollector(k8sClient, sysdumpOptions, time.Now(), Version) if err != nil { return fmt.Errorf("failed to create sysdump collector: %v", err) } diff --git a/sysdump/sysdump.go b/sysdump/sysdump.go index 5093bf1991..24046011f4 100644 --- a/sysdump/sysdump.go +++ b/sysdump/sysdump.go @@ -125,7 +125,7 @@ type Collector struct { } // NewCollector returns a new sysdump collector. -func NewCollector(k KubernetesClient, o Options, startTime time.Time) (*Collector, error) { +func NewCollector(k KubernetesClient, o Options, startTime time.Time, cliVersion string) (*Collector, error) { c := Collector{ Client: k, Options: o, @@ -143,6 +143,7 @@ func NewCollector(k KubernetesClient, o Options, startTime time.Time) (*Collecto return nil, err } c.logDebug("Using %v as a temporary directory", c.sysdumpDir) + c.logTask("Collecting sysdump with cilium-cli version: %s, args: %s", cliVersion, os.Args[1:]) // Grab the Kubernetes nodes for the target cluster. c.logTask("Collecting Kubernetes nodes")