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

runc: Pods can't reach cluster service IPs #2

Closed
seanknox opened this issue May 12, 2018 · 2 comments
Closed

runc: Pods can't reach cluster service IPs #2

seanknox opened this issue May 12, 2018 · 2 comments
Labels
bug Something isn't working network

Comments

@seanknox
Copy link
Owner

seanknox commented May 12, 2018

Using runc, pods cannot reach cluster service IPs (10.0.0.0/16), including apiserver at 10.0.0.1. Nodes can reach service IPs, however.

May be related to #1

To repro:

  • Try curl'ing the apiserver from a pod (doesn't work):
$ kubectl run -it --image ianneub/network-tools nettools bash

If you don't see a command prompt, try pressing enter.

root@nettools-69f59c45fc-ghzmf:/# curl --connect-timeout 10 -k https://10.0.0.1
curl: (28) Connection timed out after 10000 milliseconds

curl'ing from a node does work, however:

CLUSTER_NAME=containerd2nics make ssh hostname=node1
Agent pid 56185
Identity added: .keypair/containerd2nics/containerd2nics.pem (.keypair/containerd2nics/containerd2nics.pem)
Welcome to Ubuntu 17.10 (GNU/Linux 4.13.0-39-generic x86_64)
...
ubuntu@node1:~$ curl -k https://10.0.0.1
{
  "kind": "Status",
  "apiVersion": "v1",
  "metadata": {

  },
  "status": "Failure",
  "message": "Unauthorized",
  "reason": "Unauthorized",
  "code": 401 
@seanknox seanknox added the bug Something isn't working label May 12, 2018
@seanknox
Copy link
Owner Author

Docker seems to work, probably because it creates a bridge network:

May 13 17:12:33 node1 dockerd[94383]: time="2018-05-13T17:12:33.614546457Z" level=info msg="Default bridge (docker0) is assigned with an IP address 172.17.0.0/16. Daemon option --bip can be used to set a preferred IP address"

$ ifconfig
docker0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        inet 172.17.0.1  netmask 255.255.0.0  broadcast 0.0.0.0
        inet6 fe80::42:41ff:febb:302c  prefixlen 64  scopeid 0x20<link>
        ether 02:42:41:bb:30:2c  txqueuelen 0  (Ethernet)
        RX packets 36  bytes 2893 (2.8 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 41  bytes 5561 (5.5 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

@seanknox seanknox changed the title Pods can't reach cluster service IPs runc: Pods can't reach cluster service IPs May 13, 2018
@seanknox
Copy link
Owner Author

Fixed in dd03078

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working network
Projects
None yet
Development

No branches or pull requests

1 participant