Skip to main content
Calico Open Source 3.33 (latest) documentation

calicoctl node diags

This section describes the calicoctl node diags command.

Read the calicoctl Overview for a full list of calicoctl commands.

Displaying the help text for 'calicoctl node diags' command​

Run calicoctl node diags --help to display the following help menu for the command.

Gather a diagnostics bundle from the Calico node on this host. Run it on the
affected node when troubleshooting a networking problem; it collects logs and
system information useful for diagnosis.

Usage:
calicoctl node diags [flags]

Examples:
calicoctl node diags

Flags:
-h, --help help for diags
--log-dir string The directory containing Calico logs. (default "/var/log/calico")

Global Flags:
--allow-version-mismatch Allow client and cluster versions mismatch
--context string The name of the kubeconfig context to use
-l, --log-level string Set the log level (panic, fatal, error, warn, info, debug) (default "panic")

Examples​

sudo calicoctl node diags

An example response follows.

Collecting diagnostics
Using temp dir: /tmp/calico676127473
Dumping netstat
Dumping routes (IPv4)
Dumping routes (IPv6)
Dumping interface info (IPv4)
Dumping interface info (IPv6)
Dumping iptables (IPv4)
Dumping iptables (IPv6)
Dumping ipsets
exit status 1
Dumping ipsets (container)
Copying journal for calico-node.service
Dumping felix stats
Copying Calico logs

Diags saved to /tmp/calico676127473/diags-20170522_151219.tar.gz
If required, you can upload the diagnostics bundle to a file sharing service
such as transfer.sh using curl or similar. For example:

curl --upload-file /tmp/calico676127473/diags-20170522_151219.tar.gz https://transfer.sh//tmp/calico676127473/diags-20170522_151219.tar.gz

Options​

--log-dir string The directory containing Calico logs. (default "/var/log/calico")