3.1 Install Kubernetes
Good afternoon.
I have a quick question regarding the instructions for installing Kubernetes.
I downloaded and unzipped the course tarball and I think I confused myself when looking at some of the files.
For example, the file ../SOLUTIONS/s_03/containerd-setup.txt
It has similar, yet differing commands to be run to install containerd.
Such as downloading the Keys and installing containerd, but using different filenames.
( /etc/sysctl.d/kubernetes.conf vs. /etc/sysctl.d/99-kubernetes-cri.conf)
Should I just ignore this, and follow the instructions from the 3.1 Lab?
I'm pretty sure they're doing the same thing but I don't want to assume that out of ignorance.
- NOTE: I'm just using minikube but I was going to install on an AWS EC2 for practice
Section from ../SOLUTIONS/s_03/containerd-setup.txt:
cat <<EOF | sudo tee /etc/modules-load.d/containerd.conf overlay br_netfilter EOF # Disable swap if not on a cloud instance - done anyway sudo swapoff -a # Load the modules now sudo modprobe overlay sudo modprobe br_netfilter # Update sysctl to load iptables and ipforwarding cat <<EOF | sudo tee /etc/sysctl.d/99-kubernetes-cri.conf net.bridge.bridge-nf-call-iptables = 1 net.ipv4.ip_forward = 1 net.bridge.bridge-nf-call-ip6tables = 1 EOF sudo sysctl --system # Install some necessary software sudo apt-get update && sudo apt-get install -y apt-transport-https ca-certificates curl software-properties-common # Install the Docker keyring # In Ubuntu 20.04, containerd part of local repos. sudo apt install containerd -y #Older OS steps #curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key --keyring /etc/apt/trusted.gpg.d/docker.gpg add - # Create a Docker repository #sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" # Install and configure the containerd package #sudo apt-get update && sudo apt-get install -y containerd.io #sudo mkdir -p /etc/containerd #sudo containerd config default | sudo tee /etc/containerd/config.toml # Verify the file has the appropriate contents #cat /etc/containerd/config.toml
Section from 3.1 Lab:
# 10. Update kernel networking
cat << EOF | tee /etc/sysctl.d/kubernetes.conf
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
net.ipv4.ip_forward = 1
EOF
# 11. Changes to be used by current kernel
sysctl --system
# 12. Install the necessary key for the software to install
sudo mkdir -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg \
| sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] \
https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
# 13. Install the containerd software
apt-get update && apt-get install containerd.io -y
containerd config default | tee /etc/containerd/config.toml
sed -e's/SystemdCgroup = false/SystemdCgroup = true/g'-i /etc/containerd/config.toml
systemctl restart containerd
Answers
-
Hi @mleager,
My recommendation is to follow the video demos from the introductory chapter to provision your lab environment and then follow the instructions provided in the pdf lab guide to complete the hands-on exercises.
Familiarize yourself with the scripts, definition and configuration files from the SOLUTIONS tarball, however, they will be invoked at various stages as you progress through the lab exercises. Some files will be used by the provided hands-on exercises, while others are made available for your review as additional learning material.
EDIT: Minikube is not a recommended lab environment for this class.
Regards,
-Chris0 -
Thank you @chrispokorni.
I'll move over to AWS then and just focus on that.0
Categories
- All Categories
- 177 LFX Mentorship
- 177 LFX Mentorship: Linux Kernel
- 750 Linux Foundation IT Professional Programs
- 373 Cloud Engineer IT Professional Program
- 169 Advanced Cloud Engineer IT Professional Program
- 74 DevOps IT Professional Program - Discontinued
- 4 DevOps & GitOps IT Professional Program
- 99 Cloud Native Developer IT Professional Program
- 7.6K Training Courses & Learning Paths
- 1 AI & ML Training
- 1 Blockchain & Decentralized Identity Training
- 4 Cloud & Containers Training
- 1 Cybersecurity Training
- 2 DevOps & Site-Reliability Training
- 1 Linux Kernel Development Training
- 1 Networking Training
- 2 Open Source Best Practice Training
- 1 System Administration Training
- 1 System Engineering Training
- 1 Web & Application Development Training
- 792 Hardware
- 202 Drivers
- 68 I/O Devices
- 37 Monitors
- 95 Multimedia
- 173 Networking
- 91 Printers & Scanners
- 87 Storage
- 769 Linux Distributions
- 81 Debian
- 68 Fedora
- 22 Linux Mint
- 13 Mageia
- 24 openSUSE
- 150 Red Hat Enterprise
- 31 Slackware
- 13 SUSE Enterprise
- 356 Ubuntu
- 465 Linux System Administration
- 31 Cloud Computing
- 73 Command Line/Scripting
- Github systems admin projects
- 98 Linux Security
- 78 Network Management
- 101 System Management
- 46 Web Management
- 106 Mobile Computing
- 18 Android
- 73 Development
- 1.2K New to Linux
- 1K Getting Started with Linux
- 392 Off Topic
- 121 Introductions
- 181 Small Talk
- 29 Study Material
- 955 Programming and Development
- 310 Kernel Development
- 627 Software Development
- 983 Software
- 375 Applications
- 182 Command Line
- 5 Compiling/Installing
- 68 Games
- 317 Installation
- Archived
- 2 LFD140 Class Forum
- 1.4K LFS258 Class Forum
Upcoming Training
-
August 20, 2018
Kubernetes Administration (LFS458)
-
August 20, 2018
Linux System Administration (LFS301)
-
August 27, 2018
Open Source Virtualization (LFS462)
-
August 27, 2018
Linux Kernel Debugging and Security (LFD440)