Welcome to the Linux Foundation Forum!

Lab 5.3

when i try to run 'curl' in the container, parameters with either IP of master or kubernetes.default, the console is halt without any output. Do you know why?

Comments

  • serewicz
    serewicz Posts: 976

    Hello,

    I'm unsure what you are saying. You are trying to connect to 443, a secure port, but using an insecure flag. The API server is listening on 6443. Also try using the IP to see if DNS is part of the issue.


    Regards,

  • vwong
    vwong Posts: 16

    Hi Tim,

    It is the same with apiserver IP, thx

  • vwong
    vwong Posts: 16

    curl command works in the master OS itself for sure

  • chrispokorni
    chrispokorni Posts: 1,281

    Hi @vwong,

    It seems you slightly deviated from the lab guide, by configuring your kubectl CLI tool to run as root. I have attempted the same, hoping to reproduce your issue, but that does not impact my curl command from inside the container.

    Who's IP address is 192.168.1.200?

    What are the IP addresses of your nodes?

    What is the Pod IP subnet used to init your cluster and also set in your calico.yaml file?

    What type of infrastructure are you using for your cluster? What cloud provider or what local hypervisor?

    Regards,
    -Chris

  • vwong
    vwong Posts: 16

    Hi Chris,

    I use vsphere to host those VMs. 192.168.1.200 is the ip of the VMs and I suppose it should be the ip of apiserver

  • chrispokorni
    chrispokorni Posts: 1,281

    Hi @vwong,

    Based on the limited information provided in your latest response, I am assuming here that the cluster has been initialized with the default Pod subnet 192.168.0.0/16 as described by the lab guide. If that is the case, the nodes' IP subnet and Pods subnet seem to be overlapping, and as a result networking tools may be impacted. I would recommend that cluster nodes' IP addresses to be selected from a different private network, one that does not overlap with the default Pod network of your calico network plugin.

    Regards,
    -Chris

  • vwong
    vwong Posts: 16

    thx, Chris; I planned to rebuilt the k8s instance and retry again, thx

  • vwong
    vwong Posts: 16

    @chrispokorni, you are correct that I have IP subnet overlap issue before. And is able to fix the issue by this direction. thank you so much

Categories

Upcoming Training