Welcome to the Linux Foundation Forum!

No config file generated when running k8sMaster.sh

I am following Lab2.2 to run the shell script "k8sMaster.sh" on my cloud instance with OS Ubuntu 18.04, when running "kubeadm init", I confirmed every port is available, but still get an error with warning like this: "W0603 01:50:38.774021 16094 configset.go:202] WARNING: kubeadm cannot validate component configs for API groups [kubelet.config.k8s.io kubeproxy.config.k8s.io] "

After this, I checked the path "~/.kube", it's empty, no config file. So the problem maybe caused by no config file, but how can I get it?

Comments

  • chrispokornichrispokorni Posts: 509

    Hi @ssghost,

    The ~/.kube/config file is generated in one of the last steps of the k8sMaster.sh script, and it is needed by the CLI client in later steps. So it is very unlikely that it is the cause of the Warning message you see.

    How exactly did you confirm that "every port is available"?

    Typically cluster bootstrapping issues are caused by a shortage in resources, misconfigured network, or firewall rules blocking some critical ports that either Kubernetes or its plugins need to use.

    Details of your infrastructure's configuration may help in determining the cause of your Warning and the missing .kube/config file.

    Regards,
    -Chris

  • ssghostssghost Posts: 2

    @chrispokorni, thanks for your help.

    I used a brand new cloud instance, no ports have been used before. The ready-for shell script shows no shortages of the infrastructure.

    I shot the screen when the problem is happening. All information is recorded here, please help me to find the reason and fix it.

  • chrispokornichrispokorni Posts: 509

    Hi @ssghost,

    Thanks for the detailed output. In such scenarios, of concern should be the [ERROR ...] messages, and not so much the [WARNING ...] messages, which have more of informational value.

    In your scenario, the [ERROR NumCPU] is self-explanatory. The instance has 1 single CPU, while at least 2 CPUs are required. This is consistent with the CPU count from the first paragraph of the "Overview and Preliminaries" section of Lab exercise 2.1.

    Regards,
    -Chris

Sign In or Register to comment.