Changing the MTU Value on ARTESCA NodesΒΆ

Warning

Changing the MTU value on a running ARTESCA cluster can cause network disruptions.

Incorrect MTU values can cause network issues, such as packet loss, network congestion, and network performance degradation.

Make sure to choose a coherent value, plan the changes in sync with other devices and schedule a maintenance window to apply them.

  1. Use the nmtui tool to change the MTU value on the network adapters to the desired value.

    Important

    It is mandatory to reinitialize the network adapter in order to apply the changes.

    It can be done by simply disabling and enabling the network adapter within nmtui, or by restarting the NetworkManager daemon.

  2. Change the MTU value of the ARTESCA bootstrap.

    Note

    Replace <new_mtu> with your desired MTU value.

    [artesca-os@<NODE_NAME> ~]$
    
    sudo salt-call --local state.single file.serialize \
    /etc/metalk8s/bootstrap.yaml \
    dataset="{ \
       'networks': { \
          'workloadPlane': { \
             'mtu': <new_mtu> \
          } \
       } \
    }" \
    serializer=yaml merge_if_exists=True show_changes=True
    
  3. Export the MetalK8s version you are using as an environment variable:

    [artesca-os@bootstrap ~]$
    
    export MK8SVERSION=`sudo kubectl \
        --kubeconfig=/etc/kubernetes/admin.conf \
        get cm -n kube-system artesca-version \
        -o jsonpath="{.data.metalk8s}"`
    
  4. Propagate the MTU changes to the ARTESCA cluster internal network.

    [artesca-os@bootstrap ~]$
    
    sudo kubectl exec -n kube-system -c salt-master \
      --kubeconfig /etc/kubernetes/admin.conf \
      $(sudo kubectl --kubeconfig /etc/kubernetes/admin.conf \
        get pods -n kube-system -l app=salt-master -o name) \
      -- salt-run  state.sls metalk8s.kubernetes.cni.calico.deployed saltenv=metalk8s-$MK8SVERSION