Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How pod access service's ClusterIP in contive + vlan + bridge mode #8200

Closed
jeffrey4l opened this issue Apr 30, 2018 · 5 comments
Closed

How pod access service's ClusterIP in contive + vlan + bridge mode #8200

jeffrey4l opened this issue Apr 30, 2018 · 5 comments
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Comments

@jeffrey4l
Copy link
Contributor

Description

I am deploying openshift+contiv with vlan + bridge mode. So far the connectivity between two pods is perfect. But the service ip is not.

Technically, i can not found any doc or explanation how Pod could service's ClusterIP. So cloud anyone give me some info about this?

Expected Behavior

Service ClusterIP should be accessible from Pod.

Observed Behavior

Seems there is a OVS bridge holds all the traffics, like bellow

$ oc get svc
NAME         TYPE        CLUSTER-IP   EXTERNAL-IP   PORT(S)                 AGE
kubernetes   ClusterIP   172.30.0.1   <none>        443/TCP,53/UDP,53/TCP   7h

# ip a show dev contivh0
10: contivh0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN qlen 1000
    link/ether 02:02:0a:82:ff:fe brd ff:ff:ff:ff:ff:ff
    inet 10.130.255.254/16 scope global contivh0
       valid_lft forever preferred_lft forever
    inet6 fe80::2:aff:fe82:fffe/64 scope link 
       valid_lft forever preferred_lft forever

# ovs-vsctl show
fd7d2400-5497-4c82-9b67-8c911f015bc8
    Manager "ptcp:6640"
    Bridge contivVxlanBridge
        Controller "tcp:127.0.0.1:6633"
            is_connected: true
        fail_mode: secure
        Port "contivh0"
            tag: 2
            Interface "contivh0"
                type: internal
    Bridge contivVlanBridge
        Controller "tcp:127.0.0.1:6634"
            is_connected: true
        fail_mode: secure
        Port "vvport1"
            tag: 2970
            Interface "vvport1"
        Port "vvport2"
            tag: 2970
            Interface "vvport2"
        Port "eth1"
            Interface "eth1"
    ovs_version: "2.9.0"

# iptables -t nat -S | grep -i contiv
-N CONTIV-NODEPORT
-A PREROUTING -m addrtype --dst-type LOCAL -j CONTIV-NODEPORT
-A POSTROUTING -s 10.130.0.0/16 ! -o contivh0 -j MASQUERADE

Access the kubernetes service ip from HOST is OK too. But failed to access it from Pod.

Your Environment

# netctl -v
netctl version 
Version: 1.2.0
GitCommit: f78851a
BuildTime: 12-14-2017.07-32-25.UTC

# oc version
oc v3.9.0+ba7faec-1
kubernetes v1.9.1+a0ce1bc657
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://node1:8443
openshift v3.9.0+ba7faec-1
kubernetes v1.9.1+a0ce1bc657

# cat /etc/redhat-release 
CentOS Linux release 7.4.1708 (Core) 

# rpm -qa | grep openvswitch
openvswitch-2.9.0-3.el7.x86_6
@jeffrey4l jeffrey4l changed the title How pod access service's ClusterIP in openshift environment How pod access service's ClusterIP in contive + vlan + bridge mode Apr 30, 2018
@jeffrey4l
Copy link
Contributor Author

I created the same issue for contiv project check contiv/netplugin#1131

@openshift-bot
Copy link

Issues go stale after 90d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@openshift-ci-robot openshift-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label May 23, 2020
@openshift-bot
Copy link

Stale issues rot after 30d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle rotten
/remove-lifecycle stale

@openshift-ci-robot openshift-ci-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Jun 22, 2020
@openshift-bot
Copy link

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

@openshift-ci-robot
Copy link

@openshift-bot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.
Projects
None yet
Development

No branches or pull requests

3 participants