Welcome to the Linux Foundation Forum!

Lab 20.1 Kubernetes Installation Error: Repository Not Found - Looking for Alternatives

While trying to install Kubernetes, I encountered the following error:
Err:6 https://packages.cloud.google.com/apt kubernetes-xenial Release
404 Not Found [IP: 142.250.185.142 443]
Reading package lists... Done
E: The repository 'http://apt.kubernetes.io kubernetes-xenial Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

It seems that the repository for kubernetes-xenial is no longer available or doesn't have a Release file. Has anyone else faced this issue? Is there an alternative repository or method to install Kubernetes on this system?

Answers

  • chrispokorni
    chrispokorni Posts: 2,340

    Hi @roberto.banditt,

    The Kubernetes project is extremely dynamic, and its installation instructions have changed. I compiled a shell script that installs a single node Kubernetes cluster (v1.31.0 - the latest at this time), containerd runtime, and Flannel CNI network plugin (WeaveNet project has been archived).

    Please install Kubernetes on a Virtual Machine rather than your own workstation. It will make permanent changes to the networking configuration of the host system. The VM should have 2 CPU cores, 6-8 GB RAM, 15+ GB disk, a single bridged network interface, and run Ubuntu 20.04 LTS. The VM's private IP address should not be from the 10.244.0.0/16 subnet, in order to avoid overlapping with the Pod subnet managed by the Flannel plugin.

    The forum's policy does not allow for the script content to be shared here in any format, so I'd recommend retrieving the script from the following URL
    https://gist.githubusercontent.com/

    Download the script and run it in the VM's terminal as the non-root user. It covers lab exercise 20.1 in its entirety. After the scripts completion run kubectl get nodes and kubectl get pods -A commands several times until the Node becomes Ready and all Pods reach the Running state.

    Regards,
    -Chris

Categories

Upcoming Training