Bug 1285536 - cannot rsh using cluster admin on master node
cannot rsh using cluster admin on master node
Status: CLOSED NOTABUG
Product: OpenShift Origin
Classification: Red Hat
Component: Command Line Interface (Show other bugs)
3.x
Unspecified Unspecified
unspecified Severity medium
: ---
: ---
Assigned To: Fabiano Franz
Wei Sun
: UpcomingRelease
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-11-25 16:16 EST by Aleksandar Kostadinov
Modified: 2016-01-08 12:41 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-01-08 12:41:59 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Aleksandar Kostadinov 2015-11-25 16:16:16 EST
Description of problem:
Not sure I've got component correct. I observe a strange thing. Given a 2 node cluster, I create a pod as  a regular user. Then ssh to master and try to rsh it. That fails. While running the rsh command on a remote machine as the regular user does work just fine.

Version-Release number of selected component (if applicable):
oc v3.1.0.4-9-g72d3991
kubernetes v1.1.0-origin-1107-g4c8e6f4

How reproducible:
always

Actual results:
# oc rsh cakephp-example-1-cutxg --namespace=c48hh -vvvvv
Error from server: pods "cakephp-example-1-cutxg" not found

Expected results:
the bash prompt
Comment 1 Fabiano Franz 2015-12-02 17:47:41 EST
Jordan please take a look here, does this look like authorization?
Comment 2 Jordan Liggitt 2015-12-02 18:05:59 EST
I think the namespace argument is not being honored. If I recall correctly, args to rsh need to come before the pod name. Can you rerun with --loglevel=6 to confirm which namespace is being used?

You might need to do this:
oc rsh --namespace=c48hh cakephp-example-1-cutxg
Comment 3 Jordan Liggitt 2015-12-02 18:07:12 EST
I'm almost certain that is the issue, since -vvvvv isn't valid. You'd need to put --loglevel=… immediately after the "rsh" as well
Comment 4 Aleksandar Kostadinov 2015-12-03 17:26:00 EST
my bad, didn't realize rsh also can execute command given on command line like `exec`.

In any case would be good to clarify command synopsis:

> oc rsh POD [command] [options]

One can assume `options` is for `oc` options. `exec` command help is a little more clear although it would be good to tell users where to put `oc` options.

Should we leave this bug open for documentation or close as notabug?

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