antix@antix:~/k0s$ k0sctl apply --config k0s.yaml…
- User
antix@antix:~/k0s$ k0sctl apply --config k0s.yaml
⠀⣿⣿⡇⠀⠀⢀⣴⣾⣿⠟⠁⢸⣿⣿⣿⣿⣿⣿⣿⡿⠛⠁⠀⢸⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠀█████████ █████████ ███ ⠀⣿⣿⡇⣠⣶⣿⡿⠋⠀⠀⠀⢸⣿⡇⠀⠀⠀⣠⠀⠀⢀⣠⡆⢸⣿⣿⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀███ ███ ███ ⠀⣿⣿⣿⣿⣟⠋⠀⠀⠀⠀⠀⢸⣿⡇⠀⢰⣾⣿⠀⠀⣿⣿⡇⢸⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⠀███ ███ ███ ⠀⣿⣿⡏⠻⣿⣷⣤⡀⠀⠀⠀⠸⠛⠁⠀⠸⠋⠁⠀⠀⣿⣿⡇⠈⠉⠉⠉⠉⠉⠉⠉⠉⢹⣿⣿⠀███ ███ ███ ⠀⣿⣿⡇⠀⠀⠙⢿⣿⣦⣀⠀⠀⠀⣠⣶⣶⣶⣶⣶⣶⣿⣿⡇⢰⣶⣶⣶⣶⣶⣶⣶⣶⣾⣿⣿⠀█████████ ███ ██████████ k0sctl v0.23.0 Copyright 2023, k0sctl authors. By continuing to use k0sctl you agree to these terms: https://k0sproject.io/licenses/eula INFO ==> Running phase: Set k0s version
INFO Looking up latest stable k0s version
INFO Using k0s version v1.32.4+k0s.0
INFO ==> Running phase: Connect to hosts INFO [ssh] 10.203.173.150:22: connected
INFO [ssh] 10.203.173.45:22: connected
INFO [ssh] 10.203.173.152:22: connected
INFO ==> Running phase: Detect host operating systems INFO [ssh] 10.203.173.152:22: is running Ubuntu 24.04.2 LTS INFO [ssh] 10.203.173.45:22: is running Ubuntu 24.04.2 LTS INFO [ssh] 10.203.173.150:22: is running Ubuntu 24.04.2 LTS INFO ==> Running phase: Acquire exclusive host lock INFO ==> Running phase: Prepare hosts
INFO ==> Running phase: Gather host facts INFO [ssh] 10.203.173.150:22: using Worker2 as hostname INFO [ssh] 10.203.173.152:22: using Master as hostname INFO [ssh] 10.203.173.45:22: using Worker1 as hostname INFO [ssh] 10.203.173.150:22: discovered ens3 as private interface INFO [ssh] 10.203.173.152:22: discovered ens3 as private interface INFO [ssh] 10.203.173.45:22: discovered ens3 as private interface INFO ==> Running phase: Validate hosts
INFO ==> Running phase: Validate facts
INFO ==> Running phase: Download k0s on hosts INFO [ssh] 10.203.173.150:22: downloading k0s v1.32.4+k0s.0 INFO [ssh] 10.203.173.152:22: downloading k0s v1.32.4+k0s.0 INFO [ssh] 10.203.173.45:22: downloading k0s v1.32.4+k0s.0 INFO ==> Running phase: Install k0s binaries on hosts INFO [ssh] 10.203.173.152:22: validating configuration INFO ==> Running phase: Configure k0s
INFO [ssh] 10.203.173.152:22: installing new configuration INFO ==> Running phase: Initialize the k0s cluster INFO [ssh] 10.203.173.152:22: installing k0s controller INFO [ssh] 10.203.173.152:22: waiting for the k0s service to start INFO [ssh] 10.203.173.152:22: wait for kubernetes to reach ready state INFO * Running clean-up for phase: Acquire exclusive host lock INFO * Running clean-up for phase: Install k0s binaries on hosts INFO [ssh] 10.203.173.45:22: cleaning up k0s binary tempfile INFO [ssh] 10.203.173.152:22: cleaning up k0s binary tempfile INFO [ssh] 10.203.173.150:22: cleaning up k0s binary tempfile INFO * Running clean-up for phase: Initialize the k0s cluster INFO [ssh] 10.203.173.152:22: cleaning up
WARN [ssh] 10.203.173.152:22: k0s reset failed
INFO ==> Apply failed
FATA apply failed - log file saved to /home/antix/.cache/k0sctl/k0sctl.log: kubernetes not ready: context deadline exceeded kubernetes api /readyz responded with "" - Assistant
- User
antix@antix:~/k0s
- Assistant
- User
k0s
file config for metlalb
- Assistant
- User
apiVersion: v1 kind: ConfigMap metadata: namespace: metallb-system name: config data: config: | address-pools: - name: default protocol: layer2 addresses: - 10.82.13.210-10.82.13.240
- Assistant
- User
metallb/v0.14.9
- Assistant
For MetalLB v0.14.9 (which uses the CRD-native configuration format), you will not use the ConfigMap anymore; instead, you define the following two custom resources in the
metallb-systemnamespace:-
IPAddressPool— defines the pool of IP addresses MetalLB can allocate. -
L2Advertisement— enables Layer 2 mode and associates it with the IP pools.
Here is a valid example for MetalLB v0.14.9:
apiVersion: metallb.io/v1beta1 kind: IPAddressPool metadata: namespace: metallb-system name: default-address-pool spec: addresses: - 10.82.13.210-10.82.13.240 --- apiVersion: metallb.io/v1beta1 kind: L2Advertisement metadata: namespace: metallb-system name: default-l2-advertisement spec: ipAddressPools: - default-address-pool -
- User
antix@antix:~/k0s
- Assistant
- User
apiVersion: metallb.io/v1beta1 kind: IPAddressPool metadata: name: default-address-pool namespace: metallb-system spec: addresses:
- 10.203.173.160-10.203.173.250
apiVersion: metallb.io/v1beta1 kind: L2Advertisement metadata: name: default-l2-advertisement namespace: metallb-system spec: ipAddressPools:
- default-address-pool
- Assistant
Your MetalLB configuration YAML is perfect for your multipass k0s cluster!
apiVersion: metallb.io/v1beta1 kind: IPAddressPool metadata: name: default-address-pool namespace: metallb-system spec: addresses: - 10.203.173.160-10.203.173.250 --- apiVersion: metallb.io/v1beta1 kind: L2Advertisement metadata: name: default-l2-advertisement namespace: metallb-system spec: ipAddressPools: - default-address-pool
What this does:
- Defines the MetalLB IP address pool for Layer 2 mode
- Assigns IPs from
10.203.173.160through10.203.173.250 - MetalLB announces these IPs on your
metallb-systemnamespace in your cluster
Next steps — apply & test:
- User
multipass ls image path
- Assistant