calico | Cloud native networking and network security | Networking library
kandi X-RAY | calico Summary
kandi X-RAY | calico Summary
Calico is a widely adopted, battle-tested open source networking and network security solution for Kubernetes, virtual machines, and bare-metal workloads. Calico provides two major services for Cloud Native applications:.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of calico
calico Key Features
calico Examples and Code Snippets
Community Discussions
Trending Discussions on calico
QUESTION
I have microk8s v1.22.2 running on Ubuntu 20.04.3 LTS.
Output from /etc/hosts
:
ANSWER
Answered 2021-Oct-10 at 18:29error: unable to recognize "ingress.yaml": no matches for kind "Ingress" in version "extensions/v1beta1"
QUESTION
After I deployed the webui (k8s dashboard), I logined to the dashboard but nothing found there, instead a list of errors in notification.
...ANSWER
Answered 2021-Aug-24 at 14:00I have recreated the situation according to the attached tutorial and it works for me. Make sure, that you are trying properly login:
To protect your cluster data, Dashboard deploys with a minimal RBAC configuration by default. Currently, Dashboard only supports logging in with a Bearer Token. To create a token for this demo, you can follow our guide on creating a sample user.
Warning: The sample user created in the tutorial will have administrative privileges and is for educational purposes only.
You can also create admin role
:
QUESTION
I have a kubernetes cluster with calico. I want to prevent routing through external interfaces to reach the internal clusterIPs
of the cluster. I am planning to use this.
For which interfaces should the hostendpoint
be defined? Is it only the interface on which the Kubernetes was advertised or for all the external interfaces in the cluster?
ANSWER
Answered 2022-Mar-14 at 17:41The example from the article you mentioned has it: spec.interfaceName: eth0
. Have you tried it so far?
For each host point that you want to secure with policy, you must create a HostEndpoint object. To do that, you need the name of the Calico node on the host that owns the interface; in most cases, it is the same as the hostname of the host.
In the following example, we create a HostEndpoint for the host named my-host with the interface named eth0, with IP 10.0.0.1. Note that the value for node: must match the hostname used on the Calico node object.
When the HostEndpoint is created, traffic to or from the interface is dropped unless policy is in place.
QUESTION
I am trying to enable DNS for my pods with network policy. I am using https://kubernetes.io/docs/tasks/administer-cluster/dns-debugging-resolution/
When DNS works:
...ANSWER
Answered 2021-Oct-14 at 11:32the port is overwriten by the dns service to 8053. the tcpdumper is running inside the pod, so it does not know it is re-routed .
QUESTION
I need help understanding in detail how an ingress controller, specifically the ingress-nginx ingress controller, is supposed to work. To me, it appears as a black box that is supposed to listen on a public IP, terminate TLS, and forward traffic to a pod. But exactly how that happens is a mystery to me.
The primary goal here is understanding, the secondary goal is troubleshooting an immediate issue I'm facing.
I have a cluster with five nodes, and am trying to get the Jupyterhub application to run on it. For the most part, it is working fine. I'm using a pretty standard Rancher RKE setup with flannel/calico for the networking. The nodes run RedHat 7.9 with iptables and firewalld, and docker 19.03.
The Jupyterhub proxy is set up with a ClusterIP service (I also tried a NodePort service, that also works). I also set up an ingress. The ingress sometimes works, but oftentimes does not respond (connection times out). Specifically, if I delete the ingress, and then redeploy my helm chart, the ingress will start working. Also, if I restart one of my nodes, the ingress will start working again. I have not identified the circumstances when the ingress stops working.
Here are my relevant services:
...ANSWER
Answered 2022-Mar-13 at 06:38I found the answer to my question here: https://www.stackrox.io/blog/kubernetes-networking-demystified/ There probably is a caveat that this may vary to some extent depending on which networking CNI you are using, although everything I saw was strictly related to Kubernetes itself.
I'm still trying to digest the content of this blog, and I highly recommend referring directly to that blog, instead of relying on my answer, which could be a poor retelling of the story.
Here is approximately how a package that arrives on port 443 flows.
You will need to use the command to see the tables.
QUESTION
I was just checking the network driver used for google kubernetes engine
. It seems calico
is the default GKE driver for network policy.
ANSWER
Answered 2022-Jan-21 at 09:41Calico is only used for Network Policies in GKE. By default GKE uses a Google Network Plugin. You also have the option to enable Dataplane V2 which is eBPF Based.
In both cases the Plugins are managed by Google and you cannot change them
QUESTION
I have 2 kubernetes clusters in the IBM cloud, one has 2 Nodes, the other one 4.
The one that has 4 Nodes is working properly but at the other one I had to temporarily remove the worker nodes due to monetary reasons (shouldn't be payed while being idle).
When I reactivated the two nodes, everything seemed to start up fine and as long as I don't try to interact with Pods it still looks fine on the surface, no messages about inavailability or critical health status. OK, I deleted two obsolete Namespace
s which got stuck in the Terminating
state, but I could resolve that issue by restarting a cluster node (don't exactly know anymore which one it was).
When everything looked ok, I tried to access the kubernetes dashboard (everything done before was on IBM management level or in the command line) but surprisingly I found it unreachable with an error page in the browser stating:
503: Service Unavailable
There was a small JSON message at the bottom of that page, which said:
...ANSWER
Answered 2021-Nov-19 at 09:26The cause of the problem was an update of the cluster to the kubernetes version 1.21 while my cluster was meeting the following conditions:
- private and public service endpoint enabled
- VRF disabled
In Kubernetes version 1.21, Konnectivity replaces OpenVPN as the network proxy that is used to secure the communication of the Kubernetes API server master to worker nodes in the cluster.
When using Konnectivity, a problem exists with masters to cluster nodes communication when all of the above mentioned conditions are met.
- disabled the private service endpoint (the public one seems not to be a problem) by using the command
ibmcloud ks cluster master private-service-endpoint disable --cluster
(this command is provider specific, if you are experiencing the same problem with a different provider or on a local installation, find out how to disable that private service endpoint) - refreshed the cluster master using
ibmcloud ks cluster master refresh --cluster
and finally - reloaded all the worker nodes (in the web console, should be possible through a command as well)
- waited for about 30 minutes:
- Dashboard available / reachable again
Pod
s accessible and schedulable again
BEFORE you update any cluster to kubernetes 1.21, check if you have enabled the private service endpoint. If you have, either disable it or delay the update until you can, or enable VRF (virtual routing and forwarding), which I couldn't but was told it was likely to resolve the issue.
QUESTION
I have a baremetal cluster deployed using Kubespray with kubernetes 1.22.2, MetalLB, and ingress-nginx enabled. I am getting 404 Not found
when trying to access any service deployed via helm when setting ingressClassName: nginx
. However, everything works fine if I don't use ingressClassName: nginx
but kubernetes.io/ingress.class: nginx
instead in the helm chart values.yaml. How can I get it to work using ingressClassName
?
These are my kubespray settings for inventory/mycluster/group_vars/k8s_cluster/addons.yml
ANSWER
Answered 2021-Nov-16 at 13:42Running
kubectl get ingressclass
returned 'No resources found'.
That's the main reason of your issue.
Why?
When you are specifying ingressClassName: nginx
in your Grafana values.yaml
file you are setting your Ingress resource to use nginx
Ingress class which does not exist.
I replicated your issue using minikube, MetalLB and NGINX Ingress installed via modified deploy.yaml file with commented IngressClass
resource + set NGINX Ingress controller name to nginx
as in your example. The result was exactly the same - ingressClassName: nginx
didn't work (no address), but annotation kubernetes.io/ingress.class: nginx
worked.
(For the below solution I'm using controller pod name ingress-nginx-controller-86c865f5c4-qwl2b
, but in your case it will be different - check it using kubectl get pods -n ingress-nginx
command. Also keep in mind it's kind of a workaround - usually ingressClass
resource should be installed automatically with a whole installation of NGINX Ingress. I'm presenting this solution to understand why it's not worked for you before, and why it works with NGINX Ingress installed using helm)
In the logs of the Ingress NGINX controller I found (kubectl logs ingress-nginx-controller-86c865f5c4-qwl2b -n ingress-nginx
):
QUESTION
I was having K3s cluster with below pods running:
...ANSWER
Answered 2021-Aug-18 at 12:39I think you need to restart K3s via systemd if you want your cluster back after kill. Try command:
sudo systemctl restart k3s
This is supported by the installation script for systemd and openrc. Refer rancher docThe pod-xxx id will remain same as k3s-killall.sh doesn't uninstall k3s (you can verify this, after k3s-killall script
k3s -v
will return output) and it only restart the pods with same image. TheRestarts
column will increase the count of all pods.
QUESTION
I'm trying to understand why this particular socat
command isn't working in my case where I run it in a IPv6 only Kubernetes cluster.
Cluster is build on top of AWS with Calico CNI & containerd. Provisioned using kubeadm
and Kubernetes 1.21.
I have run the following socat
command which binds to loopback interface ::1
,
ANSWER
Answered 2021-Sep-22 at 00:03For those of you running into a similar issue with your IPv6 only Kubernetes clusters heres what I have investigated found so far.
Background: It seems that this is a generic issue relating to IPv6 and CRI.
I was running containerd
in my setup and containerd
versions 1.5.0
-1.5.2
added two PRs (don't use socat for port forwarding and use happy-eyeballs for port-forwarding) which fixed a number of issues in IPv6 port-forwarding.
Potential fix: Further to pulling in containerd
version 1.5.2
(as part of Ubuntu 20.04 LTS) I was also getting the error IPv4: dial tcp4 127.0.0.1:15021: connect: connection refused IPv6 dial tcp6: address localhost: no suitable address found
when port-forwarding. This is caused by a DNS issue when resolving localhost
. Hence I added localhost
to resolve as ::1
in the host machine with the following command.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install calico
Trying out Kubernetes on a single host or on your own hardware? The quick start guide will have you up and running in about fifteen minutes.
Running a managed public cloud? Use our guides for enabling Calico network policies.
Want to go deeper? Visit https://projectcalico.docs.tigera.io for full documentation.
Calico is an open source project, and welcomes your contribution, be it through code, a bug report, a feature request, or user feedback.
The Contribution Guidelines document will get you started on submitting changes to the project.
The Developer Guide will walk you through how to set up a development environment, build the code, and run tests.
The Calico Documentation Guide will get you started on making changes to https://projectcalico.docs.tigera.io.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page