Skip to content

Commit

Permalink
add workaround for RHEL8
Browse files Browse the repository at this point in the history
Signed-off-by: Kay Yan <kay.yan@daocloud.io>
  • Loading branch information
yankay committed Jan 14, 2025
1 parent 2552941 commit 1596d95
Show file tree
Hide file tree
Showing 14 changed files with 49 additions and 15 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,13 +77,13 @@ vagrant up
- **Flatcar Container Linux by Kinvolk**
- **Debian** Bookworm, Bullseye
- **Ubuntu** 20.04, 22.04, 24.04
- **CentOS/RHEL** [8, 9](docs/operating_systems/centos.md#centos-8)
- **CentOS/RHEL** [8, 9](docs/operating_systems/rhel.md#rhel-8)
- **Fedora** 39, 40
- **Fedora CoreOS** (see [fcos Note](docs/operating_systems/fcos.md))
- **openSUSE** Leap 15.x/Tumbleweed
- **Oracle Linux** [8, 9](docs/operating_systems/centos.md#centos-8)
- **Alma Linux** [8, 9](docs/operating_systems/centos.md#centos-8)
- **Rocky Linux** [8, 9](docs/operating_systems/centos.md#centos-8)
- **Oracle Linux** [8, 9](docs/operating_systems/rhel.md#rhel-8)
- **Alma Linux** [8, 9](docs/operating_systems/rhel.md#rhel-8)
- **Rocky Linux** [8, 9](docs/operating_systems/rhel.md#rhel-8)
- **Kylin Linux Advanced Server V10** (experimental: see [kylin linux notes](docs/operating_systems/kylinlinux.md))
- **Amazon Linux 2** (experimental: see [amazon linux notes](docs/operating_systems/amazonlinux.md))
- **UOS Linux** (experimental: see [uos linux notes](docs/operating_systems/uoslinux.md))
Expand Down
1 change: 0 additions & 1 deletion docs/_sidebar.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 0 additions & 7 deletions docs/operating_systems/centos.md

This file was deleted.

11 changes: 9 additions & 2 deletions docs/operating_systems/rhel.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,17 @@ rh_subscription_role: "Red Hat Enterprise Server"
rh_subscription_sla: "Self-Support"
```

If the RHEL 7/8 hosts are already registered to a valid Red Hat support subscription via an alternative configuration management approach prior to the deployment of Kubespray, the successful RHEL `subscription-manager` status check will simply result in the RHEL subscription registration tasks being skipped.
If the RHEL 8/9 hosts are already registered to a valid Red Hat support subscription via an alternative configuration management approach prior to the deployment of Kubespray, the successful RHEL `subscription-manager` status check will simply result in the RHEL subscription registration tasks being skipped.

## RHEL 8

If you have containers that are using iptables in the host network namespace (`hostNetwork=true`),
In the RHEL(including the AlamLinux, RockyLinux, Centos) 8, if you have containers that are using iptables in the host network namespace (`hostNetwork=true`),
you need to ensure they are using iptables-nft.
An example how k8s do the autodetection can be found [in this PR](https://github.com/kubernetes/kubernetes/pull/82966)

Kernel version 4.18 is lower than the kubeadm 1.32 system verification requirement. Refer to [this PR](https://github.com/kubernetes/system-validators/pull/48). Therefore, you need to add the following configuration to ignore the kubeadm preflight errors:

```ini
kubeadm_ignore_preflight_errors:
- SystemVerification
```
1 change: 0 additions & 1 deletion roles/kubespray-defaults/defaults/main/download.yml
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,6 @@ snapshot_controller_supported_versions:
v1.32: "v7.0.2"
v1.31: "v7.0.2"
v1.30: "v7.0.2"
v1.29: "v7.0.2"
snapshot_controller_image_repo: "{{ kube_image_repo }}/sig-storage/snapshot-controller"
snapshot_controller_image_tag: "{{ snapshot_controller_supported_versions[kube_major_version] }}"

Expand Down
4 changes: 4 additions & 0 deletions tests/files/packet_almalinux8-calico-ha-ebpf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ vm_memory: 3072
calico_bpf_enabled: true
loadbalancer_apiserver_localhost: true
auto_renew_certificates: true

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,7 @@ vm_memory: 3072
# Kubespray settings
enable_nodelocaldns_secondary: true
loadbalancer_apiserver_type: haproxy

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
4 changes: 4 additions & 0 deletions tests/files/packet_almalinux8-calico-remove-node.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,7 @@ mode: ha

# Kubespray settings
auto_renew_certificates: true

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
4 changes: 4 additions & 0 deletions tests/files/packet_almalinux8-calico.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,7 @@ ntp_force_sync_immediately: true

# Scheduler plugins
scheduler_plugins_enabled: true

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
4 changes: 4 additions & 0 deletions tests/files/packet_almalinux8-crio.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,7 @@ mode: default
# Kubespray settings
container_manager: crio
auto_renew_certificates: true

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
4 changes: 4 additions & 0 deletions tests/files/packet_almalinux8-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,7 @@ vm_memory: 3072
container_manager: docker
etcd_deployment_type: docker
resolvconf_mode: docker_dns

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
4 changes: 4 additions & 0 deletions tests/files/packet_almalinux8-kube-ovn.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,7 @@ vm_memory: 3072

# Kubespray settings
kube_network_plugin: kube-ovn

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
4 changes: 4 additions & 0 deletions tests/files/packet_amazon-linux-2-all-in-one.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,7 @@
# Instance settings
cloud_image: amazon-linux-2
mode: all-in-one

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification
4 changes: 4 additions & 0 deletions tests/files/packet_rockylinux8-calico.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,7 @@ metrics_server_enabled: true
dashboard_namespace: "kube-dashboard"
dashboard_enabled: true
loadbalancer_apiserver_type: haproxy

# Workaround for RHEL8: kernel version 4.18 is lower than Kubernetes system verification.
kubeadm_ignore_preflight_errors:
- SystemVerification

0 comments on commit 1596d95

Please sign in to comment.