Bug 1810266 - Unexpected Interface chosen when running oc port-forward
Summary: Unexpected Interface chosen when running oc port-forward
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: oc
Version: 4.3.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 4.5.0
Assignee: Nobody
QA Contact: zhou ying
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-03-04 20:08 UTC by Chris Paquin
Modified: 2022-10-06 12:29 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-05-08 17:30:27 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Chris Paquin 2020-03-04 20:08:14 UTC
Description of problem: 

Incorrect ip/network being choosen by port forward. An IP address should be choosen on the provisioning address. However the address that is being used is not on the correct network - the provisioning 

oc port-forward tiller-deploy-649959bd94-8bprm 44134:44134 
error: error upgrading connection: unable to upgrade connection: error dialing backend: dial tcp 172.22.0.39:10010: connect: no route to host

See version below 


Version-Release number of selected component (if applicable):

[corona@bastion ~]$ oc version
Client Version: openshift-clients-4.3.0-201910250623-88-g6a937dfe
Server Version: 4.3.0
Kubernetes Version: v1.16.2
[corona@bastion ~]$ hostname
bastion.stablcurco.vici.verizon.com

Description of problem: 

Incorrect ip/network being choosen by port forward. An IP address should be choosen on the provisioning address. However the address that is being used is not on the correct network - the provisioning 

oc port-forward tiller-deploy-649959bd94-8bprm 44134:44134 
error: error upgrading connection: unable to upgrade connection: error dialing backend: dial tcp 172.22.0.39:10010: connect: no route to host

See version below 


Version-Release number of selected component (if applicable):

[corona@bastion ~]$ oc version
Client Version: openshift-clients-4.3.0-201910250623-88-g6a937dfe
Server Version: 4.3.0
Kubernetes Version: v1.16.2
[corona@bastion ~]$ hostname
bastion.stablcurco.vici.verizon.com



How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:



How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Dan Williams 2020-03-05 21:38:27 UTC
If you use the --address option for port-forward and set it to the right node IP address, does that make it work?

Comment 2 Maciej Szulik 2020-05-08 17:30:27 UTC
If your machine has multiple addresses one is chosen base on alphabetical order. You have the --address option to explicitly specify one, if the default picked is not the desired one.


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