Question

Kubernetes NodePort not accessible, opened thru firewall

I’ve spent all ideas why the NodePort of my service isn’t accessible on the external IP of a K8S node. The port is added to public DO Firewall for my K8S cluster, but I can’t even telnet to that ip:port.


Submit an answer


This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

This is the issue related to Managed K8s Offering by Digital Ocean. I have raised a support case and received following response:

====== The behavior you’re observing is related to an ongoing issue our team is aware of. Specifically, the connection from the internet to the NodePort service fails when the backend pod resides on a different subnet from the queried node. This scenario typically occurs when Cilium is running in eBPF mode with VPC-native networking, which creates a custom CIDR for the pods and places them on a different subnet than the node.

To resolve this issue, we recommend creating a new Kubernetes cluster in non-VPC-native mode with Cilium running in partial KPR mode. This configuration allows NodePort services to function correctly without encountering the connectivity issue. You can create a new cluster using the following doctl CLI command:

$ doctl kubernetes cluster create <cluster-name>
–region <region-slug>
–node-pool “name=<node-pool-name>;size=<node-size>;count=<node-count>”
–version <kubernetes-version>

======

Become a contributor for community

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

DigitalOcean Documentation

Full documentation for every DigitalOcean product.

Resources for startups and SMBs

The Wave has everything you need to know about building a business, from raising funding to marketing your product.

Get our newsletter

Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.

New accounts only. By submitting your email you agree to our Privacy Policy

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.