Supported arch: amd64
Enabling this addon will add Elasticsearch, Fluentd and Kibana (the EFK stack) to MicroK8s. The components will be installed and connected together.
To enable the addon:
microk8s enable fluentd
To access the Kibana dashboard on a
v1.21 or newer cluster, point your browser at http://127.0.0.1:8181 after forwarding the kibana-logging port:
microk8s.kubectl port-forward -n kube-system service/kibana-logging 8181:5601
On a cluster prior to
v1.21 you should first start the kube proxy service:
microk8s kubectl proxy
The dashboard should be available at:
Note that you will still need to set up Kibana to track whatever you are
interested in. For more details see the upstream docs on EFK and the official Kibana documentation.
The addon can be disabled at any time with the command:
microk8s disable fluentd
Hello, How can I configure the fluentd? how can my app access it?
The proper way to access kibana is actually to do this:
$ microk8s kubectl cluster-info
Kubernetes control plane is running at https://192.168.1.1:16443
Kibana is running at https://192.168.116.50:16443/api/v1/namespaces/kube-system/services/kibana-logging/proxy
To further debug and diagnose cluster problems, use 'kubectl cluster-info dump'.
Open the link mentioned in the reply of
For this to work, you fist need to modify Kibana’s deployment as the microk8s add-on is wrongly configured:
$ microk8s kubectl set env deployments.apps kibana-logging \
I am not sure if I should modify the wiki or if someone else is responsible for that. Please advise.
@gildas it is published as a wiki so anyone can contribute if you want to. I do check over the additions
however, if there is a bug in the deployment we should probably fix that rather than document it @kjackal ?
@evilnick, sure, but I don’t want to overstep and break things that were done other ways before (as @balchua1 mentions).
That said, I installed a brand new microk8s and enabled fluentd. The
kubectl proxy mentioned in the wiki didn’t work. I could see in the web console the pages trying to get js/css resources using the wrong path.
That’s why I decided to explore the
kubectl cluster-info method and realized the kibana deployment was just an environment variable away from working.
IMHO, I kind of like the
cluster-info as I don’t have to remember to run a
kubectl proxy or
kubectl port-forward in another shell. Plus, as it is deployed today, the add-on adds kibana in the
cluster-info, so best to use it.
The drawback of
cluster-info lies in the self-signed certificate that modern browsers really do not like.
FYI, we are getting a
404 Not found atm for https://microk8s.io/docs/addon-fluentd or even other add-ons.
How heavy is the fluentd stack? Will my pi’s be able to run this load?
Its elastic which is going to be kindda heavy. Whats your rpi specs?
(3x) raspberry pi’s 4, each with 4gb of ram, and 64 gb of space
If you’re not going to index too many logs(few MBs), the default settings configured for elasticsearch seems ok to me.
Here’s what i notice about elasticsearch, it uses a good amount of memory and IO if you’re indexing lots of your logs. Fluentd isn’t that of a resource hog.
In many cases I’ve seen, elastic is often allocated to its own dedicated node. But these are heavily used elastics.
Another option that i tend to use lately is Loki The logging stuffs from grafana. A bit less storage needs but also less features unlike a full text search engine like elastic.