1OC EX(1) June 2016 OC EX(1)
2
3
4
6 oc ex diagnostics - Diagnose common cluster problems
7
8
9
11 oc ex diagnostics [OPTIONS]
12
13
14
16 This utility helps troubleshoot and diagnose known problems for an
17 OpenShift cluster and/or local host. The base command runs a standard
18 set of diagnostics:
19
20
21 oc ex diagnostics
22
23
24 Available diagnostics vary based on client config and local OpenShift
25 host config. Config files in standard locations for client, master, and
26 node are used, or you may specify config files explicitly with flags.
27 For example:
28
29
30 oc ex diagnostics --master-config=/etc/origin/master/master-config.yaml
31
32 · Explicitly specifying a config file raises an error if it is
33 not found.
34
35 · A client config with cluster-admin access is required for most
36 cluster diagnostics.
37
38 · Diagnostics that require a config file are skipped if it is
39 not found.
40
41 · The standard set also skips diagnostics considered too heavy‐
42 weight.
43
44 An individual diagnostic may be run as a subcommand which may have
45 flags for specifying options specific to that diagnostic.
46
47
48 Finally, the "all" subcommand runs all available diagnostics (including
49 heavyweight ones skipped in the standard set) and provides all individ‐
50 ual diagnostic flags.
51
52
53
55 --cluster-context=""
56 Client context to use for cluster administrator
57
58
59 -l, --diaglevel=1
60 Level of diagnostic output: 4: Error, 3: Warn, 2: Notice, 1: Info,
61 0: Debug
62
63
64 --host=false
65 If true, look for systemd and journald units even without mas‐
66 ter/node config
67
68
69 --loglevel=0
70 Set the level of log output (0-10)
71
72
73 --logspec=""
74 Set per module logging with file|pattern=LEVEL,...
75
76
77 --master-config=""
78 Path to master config file (implies --host)
79
80
81 --node-config=""
82 Path to node config file (implies --host)
83
84
85 --prevent-modification=false
86 If true, may be set to prevent diagnostics making any changes via
87 the API
88
89
90
92 --allow_verification_with_non_compliant_keys=false
93 Allow a SignatureVerifier to use keys which are technically
94 non-compliant with RFC6962.
95
96
97 --alsologtostderr=false
98 log to standard error as well as files
99
100
101 --application_metrics_count_limit=100
102 Max number of application metrics to store (per container)
103
104
105 --as=""
106 Username to impersonate for the operation
107
108
109 --as-group=[]
110 Group to impersonate for the operation, this flag can be repeated
111 to specify multiple groups.
112
113
114 --azure-container-registry-config=""
115 Path to the file containing Azure container registry configuration
116 information.
117
118
119 --boot_id_file="/proc/sys/kernel/random/boot_id"
120 Comma-separated list of files to check for boot-id. Use the first
121 one that exists.
122
123
124 --cache-dir="/builddir/.kube/http-cache"
125 Default HTTP cache directory
126
127
128 --certificate-authority=""
129 Path to a cert file for the certificate authority
130
131
132 --client-certificate=""
133 Path to a client certificate file for TLS
134
135
136 --client-key=""
137 Path to a client key file for TLS
138
139
140 --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
141 CIDRs opened in GCE firewall for LB traffic proxy health checks
142
143
144 --cluster=""
145 The name of the kubeconfig cluster to use
146
147
148 --container_hints="/etc/cadvisor/container_hints.json"
149 location of the container hints file
150
151
152 --containerd="unix:///var/run/containerd.sock"
153 containerd endpoint
154
155
156 --context=""
157 The name of the kubeconfig context to use
158
159
160 --default-not-ready-toleration-seconds=300
161 Indicates the tolerationSeconds of the toleration for
162 notReady:NoExecute that is added by default to every pod that does not
163 already have such a toleration.
164
165
166 --default-unreachable-toleration-seconds=300
167 Indicates the tolerationSeconds of the toleration for unreach‐
168 able:NoExecute that is added by default to every pod that does not
169 already have such a toleration.
170
171
172 --docker="unix:///var/run/docker.sock"
173 docker endpoint
174
175
176 --docker-tls=false
177 use TLS to connect to docker
178
179
180 --docker-tls-ca="ca.pem"
181 path to trusted CA
182
183
184 --docker-tls-cert="cert.pem"
185 path to client certificate
186
187
188 --docker-tls-key="key.pem"
189 path to private key
190
191
192 --docker_env_metadata_whitelist=""
193 a comma-separated list of environment variable keys that needs to
194 be collected for docker containers
195
196
197 --docker_only=false
198 Only report docker containers in addition to root stats
199
200
201 --docker_root="/var/lib/docker"
202 DEPRECATED: docker root is read from docker info (this is a fall‐
203 back, default: /var/lib/docker)
204
205
206 --enable_load_reader=false
207 Whether to enable cpu load reader
208
209
210 --event_storage_age_limit="default=24h"
211 Max length of time for which to store events (per type). Value is a
212 comma separated list of key values, where the keys are event types
213 (e.g.: creation, oom) or "default" and the value is a duration. Default
214 is applied to all non-specified event types
215
216
217 --event_storage_event_limit="default=100000"
218 Max number of events to store (per type). Value is a comma sepa‐
219 rated list of key values, where the keys are event types (e.g.: cre‐
220 ation, oom) or "default" and the value is an integer. Default is
221 applied to all non-specified event types
222
223
224 --global_housekeeping_interval=0
225 Interval between global housekeepings
226
227
228 --housekeeping_interval=0
229 Interval between container housekeepings
230
231
232 --insecure-skip-tls-verify=false
233 If true, the server's certificate will not be checked for validity.
234 This will make your HTTPS connections insecure
235
236
237 --kubeconfig=""
238 Path to the kubeconfig file to use for CLI requests.
239
240
241 --log-flush-frequency=0
242 Maximum number of seconds between log flushes
243
244
245 --log_backtrace_at=:0
246 when logging hits line file:N, emit a stack trace
247
248
249 --log_cadvisor_usage=false
250 Whether to log the usage of the cAdvisor container
251
252
253 --log_dir=""
254 If non-empty, write log files in this directory
255
256
257 --logtostderr=true
258 log to standard error instead of files
259
260
261 --machine_id_file="/etc/machine-id,/var/lib/dbus/machine-id"
262 Comma-separated list of files to check for machine-id. Use the
263 first one that exists.
264
265
266 --match-server-version=false
267 Require server version to match client version
268
269
270 -n, --namespace=""
271 If present, the namespace scope for this CLI request
272
273
274 --request-timeout="0"
275 The length of time to wait before giving up on a single server
276 request. Non-zero values should contain a corresponding time unit (e.g.
277 1s, 2m, 3h). A value of zero means don't timeout requests.
278
279
280 -s, --server=""
281 The address and port of the Kubernetes API server
282
283
284 --stderrthreshold=2
285 logs at or above this threshold go to stderr
286
287
288 --storage_driver_buffer_duration=0
289 Writes in the storage driver will be buffered for this duration,
290 and committed to the non memory backends as a single transaction
291
292
293 --storage_driver_db="cadvisor"
294 database name
295
296
297 --storage_driver_host="localhost:8086"
298 database host:port
299
300
301 --storage_driver_password="root"
302 database password
303
304
305 --storage_driver_secure=false
306 use secure connection with database
307
308
309 --storage_driver_table="stats"
310 table name
311
312
313 --storage_driver_user="root"
314 database username
315
316
317 --token=""
318 Bearer token for authentication to the API server
319
320
321 --user=""
322 The name of the kubeconfig user to use
323
324
325 -v, --v=0
326 log level for V logs
327
328
329 --version=false
330 Print version information and quit
331
332
333 --vmodule=
334 comma-separated list of pattern=N settings for file-filtered log‐
335 ging
336
337
338
340 oc-ex(1), oc-ex-diagnostics-aggregatedlogging(1), oc-ex-diagnos‐
341 tics-all(1), oc-ex-diagnostics-analyzelogs(1), oc-ex-diagnos‐
342 tics-appcreate(1), oc-ex-diagnostics-clusterregistry(1), oc-ex-diagnos‐
343 tics-clusterrolebindings(1), oc-ex-diagnostics-clusterroles(1),
344 oc-ex-diagnostics-clusterrouter(1), oc-ex-diagnostics-configcon‐
345 texts(1), oc-ex-diagnostics-diagnosticpod(1), oc-ex-diagnostics-etcd‐
346 writevolume(1), oc-ex-diagnostics-inpod-networkcheck(1), oc-ex-diagnos‐
347 tics-inpod-poddiagnostic(1), oc-ex-diagnostics-masternode(1),
348 oc-ex-diagnostics-metricsapiproxy(1), oc-ex-diagnostics-net‐
349 workcheck(1), oc-ex-diagnostics-nodedefinitions(1), oc-ex-diagnos‐
350 tics-routecertificatevalidation(1), oc-ex-diagnostics-securitycon‐
351 textconstraints(1), oc-ex-diagnostics-serviceexternalips(1),
352 oc-ex-diagnostics-unitstatus(1),
353
354
355
357 June 2016, Ported from the Kubernetes man-doc generator
358
359
360
361Openshift Openshift CLI User Manuals OC EX(1)