This example shows that NSM keeps working after restarting all management resources.
NSC and NSE are using the memif
mechanism to connect to its local forwarder.
Forwarders are using the wireguard
mechanism to connect with each other.
Make sure that you have completed steps from basic.
Deploy NSC and NSE:
kubectl apply -k https://github.com/networkservicemesh/deployments-k8s/examples/heal/remote-nsm-system-restart-memif-ip?ref=34e1f2476dbc21097ab0a50348a966fd58b79985
Wait for applications ready:
kubectl wait --for=condition=ready --timeout=1m pod -l app=nsc-memif -n ns-remote-nsm-system-restart-memif-ip
kubectl wait --for=condition=ready --timeout=1m pod -l app=nse-memif -n ns-remote-nsm-system-restart-memif-ip
Ping from NSC to NSE:
result=$(kubectl exec deployments/nsc-memif -n ns-remote-nsm-system-restart-memif-ip -- vppctl ping 172.16.1.100 repeat 4)
echo ${result}
! echo ${result} | grep -E -q "(100% packet loss)|(0 sent)|(no egress interface)"
Ping from NSE to NSC:
result=$(kubectl exec deployments/nse-memif -n ns-remote-nsm-system-restart-memif-ip -- vppctl ping 172.16.1.101 repeat 4)
echo ${result}
! echo ${result} | grep -E -q "(100% packet loss)|(0 sent)|(no egress interface)"
Restart nsm-system:
kubectl delete mutatingwebhookconfiguration nsm-mutating-webhook
kubectl delete ns nsm-system
kubectl create ns nsm-system
kubectl apply -k https://github.com/networkservicemesh/deployments-k8s/examples/basic?ref=34e1f2476dbc21097ab0a50348a966fd58b79985
Ping from NSC to NSE:
result=$(kubectl exec deployments/nsc-memif -n ns-remote-nsm-system-restart-memif-ip -- vppctl ping 172.16.1.100 repeat 4)
echo ${result}
! echo ${result} | grep -E -q "(100% packet loss)|(0 sent)|(no egress interface)"
Ping from NSE to NSC:
result=$(kubectl exec deployments/nse-memif -n ns-remote-nsm-system-restart-memif-ip -- vppctl ping 172.16.1.101 repeat 4)
echo ${result}
! echo ${result} | grep -E -q "(100% packet loss)|(0 sent)|(no egress interface)"
Delete ns:
kubectl delete ns ns-remote-nsm-system-restart-memif-ip