OC-ADM-INSPECT(1)

πŸ“¦
version 4.22.0 Β· 2 versions
, in nixpkgs unstable

OC ADM(1) (oc adm inspect) πŸ’…

Okay bestie, so this page is from the OC ADM manual, and it's literally all about oc adm inspect. Let's get into it! 🫢

✨ NAME ✨

oc adm inspect: collect debugging data for a given resource. That's the whole vibe. πŸ’–

πŸ› οΈ SYNOPSIS πŸ› οΈ

oc adm inspect [OPTIONS]

That's the whole command line, no cap.

🌸 DESCRIPTION 🌸

So like, this command gathers debugging information for a resource.

It downloads the specified resource and any related resources, all for the purpose of gathering debugging information. It's giving detective energy, honestly. πŸ”

✨ OPTIONS ✨

  • -A, --all-namespaces=false β€” if you include this, it lists the requested object(s) across all namespaces. The namespace in the current context is ignored even if you specify it with --namespace. So like, it's the "all the namespaces" button, periodt. πŸ’…
  • --as="" β€” username to impersonate for the operation. The user could be a regular user or a service account in a namespace. Like, you're cosplaying as someone else, lowkey. 🎭
  • --as-group=[] β€” group to impersonate for the operation. This flag can be repeated to specify multiple groups. So you can stack 'em up, bestie. πŸŽ€
  • --as-uid="" β€” UID to impersonate for the operation. It's giving "who am I really" energy. πŸ™ˆ
  • --as-user-extra=[] β€” user extras to impersonate for the operation. This flag can be repeated to specify multiple values for the same key. So like, you can add all the extra bits, periodt. πŸ’…
  • --cache-dir="/homeless-shelter/.kube/cache" β€” default cache directory. Like, it's where stuff gets cached, you know? 😭
  • --certificate-authority="" β€” path to a cert file for the certificate authority. So like, the CA cert goes here. πŸ“œ
  • --client-certificate="" β€” path to a client certificate file for TLS. For when you need to prove who you are. πŸͺͺ
  • --client-key="" β€” path to a client key file for TLS. The secret sauce to your client certificate. πŸ”‘
  • --cluster="" β€” the name of the kubeconfig cluster to use. So like, which cluster are we talking to? 🌐
  • --context="" β€” the name of the kubeconfig context to use. It's the vibe of your kubeconfig, honestly. 🎯
  • --dest-dir="" β€” root directory used for storing all gathered cluster operator data. It defaults to $(PWD)/inspect.local.<rand>. So like, if you don't specify, it makes a random folder in your current directory. πŸŽ€
  • --disable-compression=false β€” if true, opt-out of response compression for all requests to the server. So like, no compression, no problem? πŸ’
  • --events-file="" β€” a path to an events.json file to create a HTML page from. So like, you give it a JSON file and it makes a little HTML page. Cute! 🎨
  • --insecure-skip-tls-verify=false β€” if true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure. So like, only do this if you're feeling risky, bestie. πŸ’€
This will make your HTTPS connections insecure, so like, be careful! πŸ”₯
  • --kubeconfig="" β€” path to the kubeconfig file to use for CLI requests. So like, where's your kubeconfig at? πŸ“
  • -n, --namespace="" β€” if present, the namespace scope for this CLI request. So like, which namespace are we poking around in? πŸ•΅οΈ
  • --request-timeout="0" β€” the length of time to wait before giving up on a single server request. Non-zero values should contain a corresponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't timeout requests. So like, zero means wait forever, which is giving patient queen energy. πŸ‘‘
  • -s, --server="" β€” the address and port of the Kubernetes API server. So like, where's the server at? 🌐
  • --since=0 β€” only return logs newer than a relative duration like 5s, 2m, or 3h. It defaults to all logs. Only one of since-time / since may be used. So like, it's a time filter for logs. ⏰
  • --since-time="" β€” only return logs after a specific date (RFC3339). It defaults to all logs. Only one of since-time / since may be used. So like, you can specify an exact date, but you can't use both. πŸ—“οΈ
  • --tls-server-name="" β€” server name to use for server certificate validation. If it is not provided, the hostname used to contact the server is used. So like, it's the name on the certificate. πŸ“›
  • --token="" β€” bearer token for authentication to the API server. It's like your VIP pass. 🎟️
  • --user="" β€” the name of the kubeconfig user to use. So like, which user are we? πŸ‘€

πŸ‘‘ OPTIONS INHERITED FROM PARENT COMMANDS πŸ‘‘

  • --kuberc="" β€” path to the kuberc file to use for preferences. This can be disabled by exporting KUBECTL_KUBERC=false feature gate or turning off the feature KUBERC=off. So like, it's a preferences file, but you can turn it off if you want. πŸ’…
  • --match-server-version=false β€” require server version to match client version. So like, if you want them to be exactly the same, this is your flag. 🎯
  • --profile="none" β€” name of profile to capture. One of (none|cpu|heap|goroutine|threadcreate|block|mutex). So like, you can profile all the things. πŸ“Š
  • --profile-output="profile.pprof" β€” name of the file to write the profile to. So like, where does the profile go? πŸ“
  • --warnings-as-errors=false β€” treat warnings received from the server as errors and exit with a non-zero exit code. So like, warnings become errors, periodt. πŸ’€

πŸ¦‹ EXAMPLE πŸ¦‹

Here are some iconic examples, bestie:

# Collect debugging data for the "openshift-apiserver" clusteroperator
oc adm inspect clusteroperator/openshift-apiserver

# Collect debugging data for the "openshift-apiserver" and "kube-apiserver" clusteroperators
oc adm inspect clusteroperator/openshift-apiserver clusteroperator/kube-apiserver

# Collect debugging data for all clusteroperators
oc adm inspect clusteroperator

# Collect debugging data for all clusteroperators and clusterversions
oc adm inspect clusteroperators,clusterversions

🌈 SEE ALSO 🌈

oc-adm(1), that's the parent command, so go check it out if you want the full picture. πŸ’–

πŸ’œ HISTORY πŸ’œ

June 2016, ported from the Kubernetes man-doc generator. So like, this page has been around for a minute, but it's still iconic. πŸ‘‘


This page is from the Openshift CLI User Manuals, part of the OC ADM(1) family, and it was last updated in June 2016. Stay slay, bestie! πŸ’–βœ¨

πŸ“¦ where this page comes from