Task 1: Control Plane Installation
This guide walks your team through the installation, of a K3s control plane. K3s is a lightweight, certified Kubernetes distribution. By following these steps, you will deploy the core "brain" of your new Kubernetes cluster, ready for worker nodes to join.
Before you start
Ensure your team has met the following prerequisites before beginning the installation.
Make sure that:
All participants have switched to the
k3suser account (e.g., usingsudo su - k3s).A shared
screensession has been started by the session leader (e.g.,screen -S group_session).All team members have successfully joined the shared
screensession.The designated Driver will run the commands, and others will observe.
How to install the control plane
The designated Driver will now execute the following commands. Observers should watch the shared screen and verify the output of each command before proceeding to the next step.
Step 1: Test Direct Internet Access
Ping Google's public DNS server to confirm the device can reach an external IP address. A successful result will show 0% packet loss. This is shown in the expected response.
Expected response:
Step 2: Test DNS Name Resolution
Ping a domain name to confirm that the Domain Name System (DNS) is working correctly. This is a critical test to ensure the server can find other computers on the internet by their name.
Expected response:
Step 3: Update the system
First, ensure all system packages are up-to-date. This prevents conflicts with existing software.
Step 4: Install k3s
Use the official installation script from k3s. This command downloads and runs the script, which automatically sets up k3s as a systemd service.
Expected response:
Accomplishments
A K3s control plane node has been successfully installed and configured on the system.
K3s Service: K3s version v1.30.6+k3s1 was installed and configured to run as a systemd service, ensuring it will start automatically on boot.
Node Configuration: The node has been configured with the name k3ssubmain and has been assigned its internal IP address for cluster communication.
System Integration: Necessary command-line tools, such as, kubectl have been linked, and the K3s service has been enabled and started. The node is currently initialized.
Remain in the shared terminal session, as this is required for the next Task.