1KUBERNETES(1)(kubernetes)                            KUBERNETES(1)(kubernetes)
2
3
4
5Eric Paris Jan 2015
6
7

NAME

9       kubectl  cluster-info  dump  - Dump lots of relevant info for debugging
10       and diagnosis
11
12
13

SYNOPSIS

15       kubectl cluster-info dump [OPTIONS]
16
17
18

DESCRIPTION

20       Dumps cluster info out suitable for debugging  and  diagnosing  cluster
21       problems.   By  default, dumps everything to stdout. You can optionally
22       specify a directory with --output-directory.  If you specify  a  direc‐
23       tory,  kubernetes  will build a set of files in that directory.  By de‐
24       fault only dumps things in the 'kube-system'  namespace,  but  you  can
25       switch  to a different namespace with the --namespaces flag, or specify
26       --all-namespaces to dump all namespaces.
27
28
29       The command also dumps the logs of all of  the  pods  in  the  cluster,
30       these logs are dumped into different directories based on namespace and
31       pod name.
32
33
34

OPTIONS

36       -A, --all-namespaces=false      If true, dump all namespaces.  If true,
37       --namespaces is ignored.
38
39
40       --allow-missing-template-keys=true       If  true, ignore any errors in
41       templates when a field or map key is missing in the template. Only  ap‐
42       plies to golang and jsonpath output formats.
43
44
45       --namespaces=[]      A comma separated list of namespaces to dump.
46
47
48       -o,  --output="json"      Output format. One of: json|yaml|name|go-tem‐
49       plate|go-template-file|template|templatefile|jsonpath|json‐
50       path-as-json|jsonpath-file.
51
52
53       --output-directory=""       Where to output the files.  If empty or '-'
54       uses stdout, otherwise creates a directory hierarchy in that directory
55
56
57       --pod-running-timeout=20s      The length of time (like 5s, 2m, or  3h,
58       higher than zero) to wait until at least one pod is running
59
60
61       --show-managed-fields=false       If  true, keep the managedFields when
62       printing objects in JSON or YAML format.
63
64
65       --template=""      Template string or path to template file to use when
66       -o=go-template, -o=go-template-file. The template format is golang tem‐
67       plates [http://golang.org/pkg/text/template/#pkg-overview].
68
69
70

OPTIONS INHERITED FROM PARENT COMMANDS

72       --add-dir-header=false      If true, adds the  file  directory  to  the
73       header of the log messages
74
75
76       --alsologtostderr=false      log to standard error as well as files
77
78
79       --application-metrics-count-limit=100       Max  number  of application
80       metrics to store (per container)
81
82
83       --as=""      Username to impersonate for the operation
84
85
86       --as-group=[]      Group to impersonate for the  operation,  this  flag
87       can be repeated to specify multiple groups.
88
89
90       --azure-container-registry-config=""       Path  to the file containing
91       Azure container registry configuration information.
92
93
94       --boot-id-file="/proc/sys/kernel/random/boot_id"        Comma-separated
95       list of files to check for boot-id. Use the first one that exists.
96
97
98       --cache-dir="/builddir/.kube/cache"      Default cache directory
99
100
101       --certificate-authority=""      Path to a cert file for the certificate
102       authority
103
104
105       --client-certificate=""      Path to a client certificate file for TLS
106
107
108       --client-key=""      Path to a client key file for TLS
109
110
111       --cloud-provider-gce-l7lb-src-cidrs=130.211.0.0/22,35.191.0.0/16
112            CIDRs  opened  in  GCE  firewall  for  L7 LB traffic proxy  health
113       checks
114
115
116       --cloud-provider-gce-lb-src-cidrs=130.211.0.0/22,209.85.152.0/22,209.85.204.0/22,35.191.0.0/16
117            CIDRs  opened  in  GCE  firewall  for  L4 LB traffic proxy  health
118       checks
119
120
121       --cluster=""      The name of the kubeconfig cluster to use
122
123
124       --container-hints="/etc/cadvisor/container_hints.json"      location of
125       the container hints file
126
127
128       --containerd="/run/containerd/containerd.sock"      containerd endpoint
129
130
131       --containerd-namespace="k8s.io"      containerd namespace
132
133
134       --context=""      The name of the kubeconfig context to use
135
136
137       --default-not-ready-toleration-seconds=300       Indicates  the tolera‐
138       tionSeconds of the toleration for notReady:NoExecute that is  added  by
139       default to every pod that does not already have such a toleration.
140
141
142       --default-unreachable-toleration-seconds=300      Indicates the tolera‐
143       tionSeconds of the toleration for unreachable:NoExecute that  is  added
144       by default to every pod that does not already have such a toleration.
145
146
147       --disable-root-cgroup-stats=false       Disable  collecting root Cgroup
148       stats
149
150
151       --docker="unix:///var/run/docker.sock"      docker endpoint
152
153
154       --docker-env-metadata-whitelist=""      a comma-separated list of envi‐
155       ronment  variable  keys  matched with specified prefix that needs to be
156       collected for docker containers
157
158
159       --docker-only=false      Only report docker containers in  addition  to
160       root stats
161
162
163       --docker-root="/var/lib/docker"       DEPRECATED:  docker  root is read
164       from docker info (this is a fallback, default: /var/lib/docker)
165
166
167       --docker-tls=false      use TLS to connect to docker
168
169
170       --docker-tls-ca="ca.pem"      path to trusted CA
171
172
173       --docker-tls-cert="cert.pem"      path to client certificate
174
175
176       --docker-tls-key="key.pem"      path to private key
177
178
179       --enable-load-reader=false      Whether to enable cpu load reader
180
181
182       --event-storage-age-limit="default=0"      Max length of time for which
183       to store events (per type). Value is a comma separated list of key val‐
184       ues, where the keys are event types (e.g.: creation, oom) or  "default"
185       and  the  value  is a duration. Default is applied to all non-specified
186       event types
187
188
189       --event-storage-event-limit="default=0"      Max number  of  events  to
190       store  (per type). Value is a comma separated list of key values, where
191       the keys are event types (e.g.: creation, oom)  or  "default"  and  the
192       value  is  an  integer.  Default  is applied to all non-specified event
193       types
194
195
196       --global-housekeeping-interval=1m0s      Interval between global house‐
197       keepings
198
199
200       --housekeeping-interval=10s       Interval between container housekeep‐
201       ings
202
203
204       --insecure-skip-tls-verify=false      If true, the server's certificate
205       will not be checked for validity. This will make your HTTPS connections
206       insecure
207
208
209       --kubeconfig=""      Path to the kubeconfig file to  use  for  CLI  re‐
210       quests.
211
212
213       --log-backtrace-at=:0       when logging hits line file:N, emit a stack
214       trace
215
216
217       --log-cadvisor-usage=false      Whether to log the usage of the  cAdvi‐
218       sor container
219
220
221       --log-dir=""      If non-empty, write log files in this directory
222
223
224       --log-file=""      If non-empty, use this log file
225
226
227       --log-file-max-size=1800       Defines  the maximum size a log file can
228       grow to. Unit is megabytes. If the value is 0, the maximum file size is
229       unlimited.
230
231
232       --log-flush-frequency=5s       Maximum  number  of  seconds between log
233       flushes
234
235
236       --logtostderr=true      log to standard error instead of files
237
238
239       --machine-id-file="/etc/machine-id,/var/lib/dbus/machine-id"
240            Comma-separated  list  of  files  to check for machine-id. Use the
241       first one that exists.
242
243
244       --match-server-version=false       Require  server  version  to   match
245       client version
246
247
248       -n,  --namespace=""       If  present, the namespace scope for this CLI
249       request
250
251
252       --one-output=false      If true, only write logs to their native sever‐
253       ity level (vs also writing to each lower severity level)
254
255
256       --password=""      Password for basic authentication to the API server
257
258
259       --profile="none"         Name   of   profile   to   capture.   One   of
260       (none|cpu|heap|goroutine|threadcreate|block|mutex)
261
262
263       --profile-output="profile.pprof"      Name of the  file  to  write  the
264       profile to
265
266
267       --referenced-reset-interval=0       Reset interval for referenced bytes
268       (container_referenced_bytes metric), number of measurement cycles after
269       which  referenced  bytes  are cleared, if set to 0 referenced bytes are
270       never cleared (default: 0)
271
272
273       --request-timeout="0"      The length of time to wait before giving  up
274       on  a  single  server  request. Non-zero values should contain a corre‐
275       sponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't time‐
276       out requests.
277
278
279       -s, --server=""      The address and port of the Kubernetes API server
280
281
282       --skip-headers=false       If  true,  avoid  header prefixes in the log
283       messages
284
285
286       --skip-log-headers=false      If true, avoid headers when  opening  log
287       files
288
289
290       --stderrthreshold=2      logs at or above this threshold go to stderr
291
292
293       --storage-driver-buffer-duration=1m0s      Writes in the storage driver
294       will be buffered for this duration, and committed  to  the  non  memory
295       backends as a single transaction
296
297
298       --storage-driver-db="cadvisor"      database name
299
300
301       --storage-driver-host="localhost:8086"      database host:port
302
303
304       --storage-driver-password="root"      database password
305
306
307       --storage-driver-secure=false      use secure connection with database
308
309
310       --storage-driver-table="stats"      table name
311
312
313       --storage-driver-user="root"      database username
314
315
316       --tls-server-name=""       Server  name  to  use for server certificate
317       validation. If it is not provided, the hostname  used  to  contact  the
318       server is used
319
320
321       --token=""      Bearer token for authentication to the API server
322
323
324       --update-machine-info-interval=5m0s       Interval between machine info
325       updates.
326
327
328       --user=""      The name of the kubeconfig user to use
329
330
331       --username=""      Username for basic authentication to the API server
332
333
334       -v, --v=0      number for the log level verbosity
335
336
337       --version=false      Print version information and quit
338
339
340       --vmodule=       comma-separated  list  of   pattern=N   settings   for
341       file-filtered logging
342
343
344       --warnings-as-errors=false      Treat warnings received from the server
345       as errors and exit with a non-zero exit code
346
347
348

EXAMPLE

350                # Dump current cluster state to stdout
351                kubectl cluster-info dump
352
353                # Dump current cluster state to /path/to/cluster-state
354                kubectl cluster-info dump --output-directory=/path/to/cluster-state
355
356                # Dump all namespaces to stdout
357                kubectl cluster-info dump --all-namespaces
358
359                # Dump a set of namespaces to /path/to/cluster-state
360                kubectl cluster-info dump --namespaces default,kube-system --output-directory=/path/to/cluster-state
361
362
363
364

SEE ALSO

366       kubectl-cluster-info(1),
367
368
369

HISTORY

371       January 2015, Originally compiled by Eric Paris (eparis at  redhat  dot
372       com)  based  on the kubernetes source material, but hopefully they have
373       been automatically generated since!
374
375
376
377Manuals                              User            KUBERNETES(1)(kubernetes)
Impressum