MetalLB assigns IP to nginx, but Destination Host Unreachable

3/17/2020

I can't reach the IP address assigned (192.168.0.240) from outside the cluster.

❯ kubectl get services  -n kube-system -l app=nginx-ingress -o wide
NAME                       TYPE           CLUSTER-IP      EXTERNAL-IP     PORT(S)                      AGE    SELECTOR
nginx-ingress-controller   LoadBalancer   10.43.225.204   192.168.0.240   80:31012/TCP,443:32713/TCP   2d2h   app=nginx-ingress,component=controller,release=nginx-ingress

From a cluster node:

[sseneca@alarm-master ~]$ curl http://192.168.0.240/
<html>
<head><title>404 Not Found</title></head>
<body>
<center><h1>404 Not Found</h1></center>
<hr><center>nginx/1.17.8</center>
</body>
</html>

But from a machine on the network but not a part of the cluster:

curl: (7) Failed to connect to 192.168.0.240 port 80: No route to host

And using ping:

 ping 192.168.0.240
PING 192.168.0.240 (192.168.0.240) 56(84) bytes of data.
From 192.168.0.21 icmp_seq=1 Destination Host Unreachable
From 192.168.0.21 icmp_seq=2 Destination Host Unreachable
From 192.168.0.21 icmp_seq=3 Destination Host Unreachable
^C
--- 192.168.0.240 ping statistics ---
4 packets transmitted, 0 received, +3 errors, 100% packet loss, time 3095ms
pipe 3

I don't know how to debug this issue, any help appreciated. Somebody had a suggestion on another forum but I didn't understand what they wanted me to do.

-- seneca
k3s
kubernetes
networking

0 Answers