Skip to main content

px csi diags

Collect diagnostics from PX-CSI components

Examples:

# Collect all diagnostics (logs + cluster info)
kubectl px csi diags --all

# Collect only pod logs (controller and node plugin logs)
kubectl px csi diags --logs

# Collect node plugin logs from specific nodes
kubectl px csi diags --logs --node node-1,node-2

# Collect logs from the last hour with custom output directory
kubectl px csi diags --logs --since 1h --output-dir /tmp/px-csi-diags

Flags

FlagInput typeDescriptionDefaultRequired
--all, -aboolCollect all diagnostics: logs, pod info, PVCs, PVs, and CSI resourcesfalseOptional
--logs, -lboolCollect only pod logs from controller and node pluginsfalseOptional
--namespace, -nstring(optional) Kubernetes namespace where PX-CSI pods are running-Optional
--nodestringCollect node plugin logs from specific nodes (comma-separated)-Optional
--output-dir, -ostringTarget directory to store diagnostic files (defaults to px-csi-diags directory)-Optional
--sincestringOnly return logs newer than a relative duration like 5s, 2m, or 3h-Optional