Oc describe: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
No edit summary
 
(26 intermediate revisions by the same user not shown)
Line 4: Line 4:


=Overview=
=Overview=
=Generic Syntax=
oc describe supports the following generic syntax:
oc describe ''<[[OpenShift_Concepts#Objects|componentType]]>''/''<componentName>''
oc describe daemonset/logging-fluentd
oc describe node/node1
oc describe pod/logging-fluentd-3kz30
The same pattern applies for [[oc edit#Generic_Syntax|oc edit]].
For a complete list of OpenShift component types, see {{Internal|OpenShift_Concepts#Objects|OpenShift Objects}}
There are cases when oc describe for a resource fails, but [[oc edit]] works:
oc describe  oauthclient/kibana-proxy
error: no description has been implemented for "OAuthClient"
oc edit oauthclient/kibana-proxy


=Subcommands=
=Subcommands=
==group==
Describe [[OpenShift_Security_Concepts#Group|groups]].
oc describe group


==quota==
==quota==


<pre>
oc describe quota core-object-counts -n demo project
oc describe quota core-object-counts -n demo project
 
</pre>
==pod==
 
Find the [[OpenShift_Concepts#Pod_Defintion|pod]] name with
 
[[Oc_get#pods|oc get pod]] -n ''<some-namespace>''
 
Then get more information:
 
oc describe pod -n ''<some-namespace>'' ''<pod-name>''
 
Example:
 
oc describe pod -n logging logging-kibana-1-d4bw2
 
Alternative:
 
oc describe -n logging po/logging-kibana-1-d4bw2
 
Output Example:
 
{{Internal|oc describe pod Output Example|oc describe pod Output Example}}
 
==node==
 
oc describe node ''<node-name>''
 
can be used to [[OpenShift Get Labels Applied to a Node|get the labels applied to the node]].
 
==service==
 
oc describe service <''service-name''>
 
Example:
 
oc describe service logging-kibana
 
Name: logging-kibana
Namespace: logging
Labels: logging-infra=support
Selector: component=kibana,provider=openshift
Type: ClusterIP
IP: 172.30.123.83
Port: <unset> 443/TCP
Endpoints: 10.131.0.25:3000
Session Affinity: None
No events.

Latest revision as of 20:26, 31 January 2018

Internal

Overview

Generic Syntax

oc describe supports the following generic syntax:

oc describe <componentType>/<componentName>
oc describe daemonset/logging-fluentd
oc describe node/node1
oc describe pod/logging-fluentd-3kz30

The same pattern applies for oc edit.

For a complete list of OpenShift component types, see

OpenShift Objects

There are cases when oc describe for a resource fails, but oc edit works:

oc describe  oauthclient/kibana-proxy
error: no description has been implemented for "OAuthClient"
oc edit oauthclient/kibana-proxy

Subcommands

group

Describe groups.

oc describe group

quota

oc describe quota core-object-counts -n demo project

pod

Find the pod name with

oc get pod -n <some-namespace>

Then get more information:

oc describe pod -n <some-namespace> <pod-name>

Example:

oc describe pod -n logging logging-kibana-1-d4bw2

Alternative:

oc describe -n logging po/logging-kibana-1-d4bw2

Output Example:

oc describe pod Output Example

node

oc describe node <node-name>

can be used to get the labels applied to the node.

service

oc describe service <service-name>

Example:

oc describe service logging-kibana
Name:			logging-kibana
Namespace:		logging
Labels:			logging-infra=support
Selector:		component=kibana,provider=openshift
Type:			ClusterIP
IP:			172.30.123.83
Port:			<unset>	443/TCP
Endpoints:		10.131.0.25:3000
Session Affinity:	None
No events.