Bug 1420235 - usage of oc logs -h need update
Summary: usage of oc logs -h need update
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 3.5.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: 3.9.z
Assignee: Fabiano Franz
QA Contact: Weihua Meng
Depends On:
TreeView+ depends on / blocked
Reported: 2017-02-08 09:32 UTC by Weihua Meng
Modified: 2019-06-06 06:56 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2019-06-06 06:56:05 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:0788 0 None None None 2019-06-06 06:56:14 UTC

Description Weihua Meng 2017-02-08 09:32:24 UTC
Description of problem:
oc logs supports not only pods. Current usage info conflicts with examples and makes users confused.
usage info should be updated to include other resource types such as BC,DC

Version-Release number of selected component (if applicable):
openshift v3.5.0.17+c55cf2b
kubernetes v1.5.2+43a9be4
etcd 3.1.0

How reproducible:

Steps to Reproduce:
1. oc logs -h

Actual results:
  oc logs [-f] [-p] POD [-c CONTAINER] [options]

  # Start streaming the logs of the most recent build of the openldap build config.
  oc logs -f bc/openldap
  # Start streaming the logs of the latest deployment of the mysql deployment config.
  oc logs -f dc/mysql
  # Get the logs of the first deployment for the mysql deployment config. Note that logs
  # from older deployments may not exist either because the deployment was successful
  # or due to deployment pruning or manual deletion of the deployment.
  oc logs --version=1 dc/mysql
  # Return a snapshot of ruby-container logs from pod backend.
  oc logs backend -c ruby-container
  # Start streaming of ruby-container logs from pod backend.
  oc logs -f pod/backend -c ruby-container

Expected results:
update usage info accordingly. 

Additional info:

Comment 1 Weihua Meng 2018-04-25 09:22:33 UTC
This is fixed.
openshift v3.9.24
openshift v3.10.0-0.28.0

  oc logs [-f] [-p] (POD | TYPE/NAME) [-c CONTAINER] [flags]

Comment 3 errata-xmlrpc 2019-06-06 06:56:05 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.