[ Kube 100 ] Getting started with Grafana Loki in Kubernetes

  Рет қаралды 47,753

Just me and Opensource

Just me and Opensource

3 жыл бұрын

In this video, I will show you how to deploy Loki stack in a Kubernetes cluster and start collecting logs in a central place. The stack will container Loki as the logs storage engine, Promtail as the logs collection agent and Grafana for visualization.
Loki Documentation:
grafana.com/docs/loki/latest/...
LogQL:
grafana.com/docs/loki/latest/...
📺 Learn Kubernetes Playlist:
• Learn Kubernetes
Hope you enjoyed this video. Please share it with your friends and don't forget to subscribe to my channel. For any questions/issues/feedback, please leave me a comment and I will be happy to help.
👏 Thanks for watching.
💗 If you wish to support me:
www.paypal.com/cgi-bin/webscr...

Пікірлер: 153
@leopoldobarreiro9766
@leopoldobarreiro9766 3 жыл бұрын
Venkat always bringing great tech contents. Thanks a lot.
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Hi Leo, many thanks for watching.
@giarc1988
@giarc1988 2 жыл бұрын
This is an amazing tutorial. Bravo and thanks
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Hi Craig, Thanks for watching.
@BemusedSoliloquy
@BemusedSoliloquy 2 жыл бұрын
You are a very sharp cookie, I was impressed not even one minute into the video. Your tip of saving out the chart values for reference has accelerated my progress immensely, I don't know why but I had gravitated towards using --set to get things done, no more, tyvm :D
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Hi Derek, thanks for watching. I am used to using values file :)
@JohnMatthew1
@JohnMatthew1 Жыл бұрын
Thank you so much for your video, it really helped me get Loki running with my Prometheus installation!
@justmeandopensource
@justmeandopensource Жыл бұрын
Hi John, thanks for watching.
@teknikalyfit
@teknikalyfit 2 жыл бұрын
With this video, I have learned a huge amount of valuable information. Thanks bro.
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Glad it helped. Thanks for watching. Cheers.
@mr.cybernetyc7292
@mr.cybernetyc7292 3 жыл бұрын
You knew it :)) I was searching for this info regarding loki , thnx man , much appreciated it.
@justmeandopensource
@justmeandopensource 3 жыл бұрын
You are welcome and thanks for watching.
@kamrulahsan06
@kamrulahsan06 3 жыл бұрын
Thanks a lot Venkat. Much needed.
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Hi Kamrul, thanks for watching.
@danielmarques433
@danielmarques433 2 жыл бұрын
Thank you. I always learn a lot from you.
@justmeandopensource
@justmeandopensource 2 жыл бұрын
My pleasure!
@kevinyu9934
@kevinyu9934 3 жыл бұрын
Thanks for the great content. Really appreciated it.
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching Chinglong.
@cezaralmeida1564
@cezaralmeida1564 2 жыл бұрын
Thanks for this great content! Congrats!
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Hi Cezar, thanks for watching.
@MrKumargopalan
@MrKumargopalan Жыл бұрын
Hi Venkat, excellent video. It was very helpful. Keep doing more videos.
@justmeandopensource
@justmeandopensource Жыл бұрын
Hi, Thanks for watching.
@chandunallani6283
@chandunallani6283 3 жыл бұрын
Superb content and straight forward
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Hi Chandu, thanks for watching. CHeers.
@nacholibre4530
@nacholibre4530 3 жыл бұрын
great content as usual, thanks!
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching.
@dannykopping
@dannykopping 2 жыл бұрын
Loki maintainer here, great job on the video!
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Cool. Thanks for watching.
@zubairhaque2706
@zubairhaque2706 3 ай бұрын
i agree, its good@@justmeandopensource
@Tikhon_FaiR
@Tikhon_FaiR Жыл бұрын
Thank you for the guide!)
@justmeandopensource
@justmeandopensource Жыл бұрын
Hi Tokhon, thanks for watching.
@user-hp3hr7jf1n
@user-hp3hr7jf1n Жыл бұрын
Thank you very much 👍
@justmeandopensource
@justmeandopensource Жыл бұрын
hi, thanks for watching.
@julianomoraisbarbosa
@julianomoraisbarbosa 3 жыл бұрын
Cool !!! Content of great relevance !!!
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks
@suchithreddy733
@suchithreddy733 3 ай бұрын
Thanks a lot. You saved my day :)
@justmeandopensource
@justmeandopensource 3 ай бұрын
Glad it was helpful. Thanks for watching.
@user-nr8rt1xc2e
@user-nr8rt1xc2e 2 жыл бұрын
great!! many thanks to you!
@justmeandopensource
@justmeandopensource 2 жыл бұрын
You are welcome. Thanks for watching.
@fuliaamiya
@fuliaamiya 2 ай бұрын
Very straight and specific to solution but details. It is really helpful.
@justmeandopensource
@justmeandopensource 2 ай бұрын
Thanks for watching.
@kumareswaramoorthi8828
@kumareswaramoorthi8828 5 ай бұрын
Life saver, Thanks a lot
@justmeandopensource
@justmeandopensource 5 ай бұрын
Hi kumar, Thanks for watching.
@kanwalnainsingh
@kanwalnainsingh 2 жыл бұрын
Fantastic video.
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Thanks for watching.
@networkfreddy2000
@networkfreddy2000 2 күн бұрын
Nice!
@gouterelo
@gouterelo 3 жыл бұрын
Great video Venkat ! Im trying to send to a external grafana the loki service ! thanks again for all the videos !
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching. You can just add the lok datasource in your external Grafana provided you expose loki outside the cluster and that grafana can reach it. Cheers.
@liorco300
@liorco300 3 жыл бұрын
Thanks great video
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Hi, thanks for watching.
@coppyphommin9337
@coppyphommin9337 2 жыл бұрын
Oh Thank you.
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Thanks for watching. CHeers.
@Thirumalesh100
@Thirumalesh100 2 жыл бұрын
Great content, I could able to deploy Loki for our use case by referring this video. Thanks . I am also looking out the way to get the logs using Loki API for given pod
@javisartdesign
@javisartdesign 3 жыл бұрын
awesome thanks!
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching Javier.
@skycomandor
@skycomandor 2 жыл бұрын
you the best
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Thanks for watching. Cheers.
@Pyrusmalus
@Pyrusmalus 3 жыл бұрын
Thanks 😊
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching Adil
@devmrtcbk
@devmrtcbk 3 жыл бұрын
thank you Venkat
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Rhanks for watching Murat.
@aaslanli3943
@aaslanli3943 3 жыл бұрын
Thanks for this good jobs
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching.
@guillermobarroso1139
@guillermobarroso1139 Жыл бұрын
Nice
@justmeandopensource
@justmeandopensource Жыл бұрын
Thanks for watching
@pawansolanki20095
@pawansolanki20095 3 жыл бұрын
Hi , Venkat . Very informatic video. Which logging soultion you will suggest in production for cluster having more than 50 nodes?
@dattak2625
@dattak2625 3 жыл бұрын
Thank you for all your wonderful videos, I have a query regarding logs, can we use loki to monitor application specific logs, if not would you suggest any tools for application specific? Thank you.
@himansusekharmishra5114
@himansusekharmishra5114 Жыл бұрын
Thank you for this amazing video. I have a question that I have a customize storage class of type gp2 along with PV and PVC , so shall I need to mention the PV and PVC in the Loki yaml file or the storage class name will be sufficient enough for the yaml.
@rmnobarra
@rmnobarra 3 жыл бұрын
Another amazing video, Mr Venkat. Would be awesome a traefik v2 video.
@justmeandopensource
@justmeandopensource 3 жыл бұрын
I have already prepared for Traefik v2. Just need to record it. Will do it soon. Cheers.
@rmnobarra
@rmnobarra 3 жыл бұрын
@@justmeandopensource Venkat, The only one!! :)
@yashshah111
@yashshah111 Жыл бұрын
Great tutorial! Is there any way you could make an updated tutorial on this? Can you also touch upon their Grafana Cloud offering versus using the open source community version?
@rc3043
@rc3043 2 жыл бұрын
This explanation was awesome! I saw your logs have also this prefixed metadata: `stderr` before the real log the JSON. How can you remove this so loki will recognize the json properties correctly!? If you use for example fluent bit instead of Promtail?
@bharathmc7964
@bharathmc7964 2 жыл бұрын
It's very helpful and to the point. Thanks. If possible, can you please make a small demo of "Simple scalable deployment of Grafana Loki ", which is latest and as loki-stack is mostly depreciated and could not find the official documentation as well.
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Hi, thanks for watching. Why do you think loki-stack is deprecated? The chart is still maintained in grafana helm repository. I can certainly do a video on simple scalable deployment. I will try and record in the coming weeks. Cheers.
@sumanniroula3497
@sumanniroula3497 3 жыл бұрын
Thanks for the video. I followed the steps but 'Explore' page is empty for me even though loki data source is added. While checking the Javascript console, I see "Datasource named Prometheus was not found". Can you help?
@sunnynehar
@sunnynehar 2 жыл бұрын
Hi Venkat, your videos are just mind-blowing, want to ask about any upcoming videos on Grafan Tempo?
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Hi Gordis, many thanks for watching. I haven't explored Grafana Tempo. I can add it to my list and I am going through my user requested videos list at the moment.
@wva5089
@wva5089 2 жыл бұрын
Thanks. (hopefully this comment shows interaction with your vids and gets you more views)
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Thanks 😊
@Ajmalkhalil-cx4gf
@Ajmalkhalil-cx4gf 3 ай бұрын
Hello, I have setup the grafana/loki stack similar way you did. Now in grafana dashboards i am trying to create dashboard for individual pods and i am able to do it. But when i am restarting the pods, pods name gets changed. Now i am not getting any logs on dashboard. I am not sure if its the correct way of setting the dashboard i.e individual dashboards. or i just need to setup logs for namespaces only? would be grateful for your help
@nikhilpatel4278
@nikhilpatel4278 3 жыл бұрын
That was awesome! Thank You. Can you please also make some video series on securing Kube API servers with Oauth & OIDC.
@justmeandopensource
@justmeandopensource 3 жыл бұрын
I have that in my list. Let me see if I get some time to explore that. Cheers.
@sandeepmishal2376
@sandeepmishal2376 3 жыл бұрын
Hi Venkat.. It would great if you do for both in house cluster as well as cloud provided managed k8 cluster where one don't have access to the control plane.. Once again it's a great work Thanks again
@justmeandopensource
@justmeandopensource 3 жыл бұрын
@@sandeepmishal2376 Thanks for watching. I mostly cover the concept in a more generic way and let people explore further. I know people are not going to be running clusters on their laptop in the real world. But I won't be able to cover all the scenarios. Some might be interested in gke and other eks etc. But I will keep this in mind. Cheers.
@sandeepmishal2376
@sandeepmishal2376 3 жыл бұрын
Thanks Venkat.. I understood.. May be I could have been more specific to my comment and not confused you.. I was stating it for SSO using oidc topic where it can become a bit tricky as we will not have access to control plane . Sry for the confusion I love the generic way it self..
@justmeandopensource
@justmeandopensource 3 жыл бұрын
@@sandeepmishal2376 Ah okay. Now it makes sense as to why you replied in this thread. Cheers.
@user-cd9tj2tw1z
@user-cd9tj2tw1z Жыл бұрын
up!
@evgeniyburovnikov656
@evgeniyburovnikov656 3 жыл бұрын
Thank you so much for the video, it was very helpful for me. I would also be very grateful if someone could tell me how to get the loki, promtoil configuration files after installation???
@ehtishamrajput3597
@ehtishamrajput3597 8 ай бұрын
I’ve grafana loki stack running on my local docker desktop k8s , i’m integrating it with GitHub Oauth, what root url and callback url should i set, I’m getting mismatch redirect
@carmilocabigon6233
@carmilocabigon6233 Жыл бұрын
Hi, can you do a video on how to add additional config to get logs for a custom application? What configs do we need to edit, is it the configmap for the created promtail service?
@MIRISU2
@MIRISU2 3 жыл бұрын
Hi! Many thanks for that video! I have one question. I've installed loki and grafana. But I don't see how to expand log line and find out more details of log item.
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching. Do you mean in Grafana that you can't see the full log item? I am not sure if loki truncates the log item. I would be surprised if it does that and there is no configuration to control that behaviour.
@HDGlazaa
@HDGlazaa 2 жыл бұрын
Can you tell me how to change config file for loki ? for example set max_query_series = 1000 ( dafault is 500 ) in kubernetes
@kranteshshrestha361
@kranteshshrestha361 9 ай бұрын
Hello can you please make a video for setting up log retention period in loki stack. As i have tried to set the parameter according to documentation but doesn't retain the log according to set period.
@ChristianAltamiranoAyala
@ChristianAltamiranoAyala 3 жыл бұрын
Nice tutorial, Did you test the query performace with a large mount of data? If so, Is loki more performant than EFK?
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Hi Chris, thanks for watching. I haven't tested the performance with large dataset. But according to them, it should perform better than Elasticsearch as it doesn't have the index overhead.
@tamilan_editzz
@tamilan_editzz 10 ай бұрын
Hey hi, actually im using xk6 for sending logs to loki, is it possible to send our own messages to loki like " This is loki test by chandru" Message?
@Sony-il2ti
@Sony-il2ti Жыл бұрын
deploy Loki in my cluster using helm but promtail was not deployed to the bare metal servers, how do i get it deployed on them too?
@mahfoudissam1285
@mahfoudissam1285 3 жыл бұрын
hi thanks for this guide,but how can i display all the namespaces of the cluster,because loki display only some namespaces to me in the grafana dashboard
@mahfoudissam1285
@mahfoudissam1285 3 жыл бұрын
hi thanks you ,i have found the answer , there was any logs to display in the other namespaces
@dattak2625
@dattak2625 3 жыл бұрын
Hi, I am getting 502 bad gateway error, when I test data source in grafana, can you help me with this, my setup is with kubeadm on aws and it's single node, I am accessing grafana with nodeport.
@student_voice
@student_voice 11 ай бұрын
Hey i have setup a Dashboard for App logs in Grafana - Loki. Logs are coming but there is an error showing "LogfmtParserErr" The actual error looks like this: __error__ : LogfmtParserErr
@Dheerajpant5211
@Dheerajpant5211 3 жыл бұрын
Thanks for the explanation, is there any way that grafana can send full information of logs in email as alert, we are getting alert but it is only giving count, if there any way to get full information of log in email?
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Hi, thanks for watching. You could use alert manager and configure it to your liking.
@manidevops8501
@manidevops8501 3 жыл бұрын
Thanks for such a wonderful video. I'll really enjoyed the way explained. Can we do log rotation in LOKI? bcoz, in my production environment the EBS volume is getting filled with lots of logs. if i want to delete the logs which is 10 days older, how will i do that with loki?
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching. You have to configure retention settings in storage configuration. grafana.com/docs/loki/latest/operations/storage/retention/
@manidevops8501
@manidevops8501 3 жыл бұрын
@@justmeandopensource thank you so much..........
@justmeandopensource
@justmeandopensource 3 жыл бұрын
You are welcome.
@vikasp1262
@vikasp1262 3 жыл бұрын
Thanks a lot, how can i make alerts if any pod having error in logs
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching. You have to use alertmanager for that I guess. Haven't tried it myself.
@bunnyzero9125
@bunnyzero9125 2 жыл бұрын
Hi can anyone tell me how to get MySQL server query logs to Loki grafana dashboard, Mysql query logs are in pod container (opt/bitnami/MySQL/logs/query.log ) i want this logs which are in this pod container location to show displayed in Loki grafana dashboard can anyone here guide through this
@bharatarya7929
@bharatarya7929 Жыл бұрын
Hi! How to handle archiving of logs
@pjj7466
@pjj7466 4 ай бұрын
Bro can you please make another video with latest loki monolithic setup and microservices loki setup on kubernetes please?
@2mahender
@2mahender 6 ай бұрын
thank you, can you let me know how to setup alerts for loki stack
@justmeandopensource
@justmeandopensource 6 ай бұрын
Hi, Thanks for watching. I haven't tried it myself but here is the documentation that might be helpful.
@bmanikantareddy
@bmanikantareddy Жыл бұрын
what is the browser you are using for demos. I can see some tabs and running commands for opening the URLs
@justmeandopensource
@justmeandopensource Жыл бұрын
I use Qutebrowser as my web browser on Arch Linux. This browser is python based and keyboard driven. You will find it extremely useful if you are a keyboard centric person and VIM user.
@justmeandopensource
@justmeandopensource Жыл бұрын
www.qutebrowser.org/
@malcolmserrao8721
@malcolmserrao8721 Жыл бұрын
nice explanation, i have a question, if i need to configure logging on multiple kubernetes clusters can i use a single grafana instance for viewing the loki logs from different clusters?, appreciate your help
@justmeandopensource
@justmeandopensource Жыл бұрын
Hi Malcolm, thanks for watching. Yes that set up is entirely possible. You can have all logging stuff (like prometheus, grafana etc) on a separate cluster and configure ingress routes so that they can be connected from agents on other clusters.
@malcolmserrao8721
@malcolmserrao8721 Жыл бұрын
@@justmeandopensource thank you very much for the quick reply
@justmeandopensource
@justmeandopensource Жыл бұрын
@@malcolmserrao8721 no worries
@soukhyabhat9588
@soukhyabhat9588 3 жыл бұрын
Hi Venkat,Can you Please give me yaml file for adding S3 bucket as storage .Have tried many ways but nothing is working .It would be great if you could help
@mzw8374
@mzw8374 3 күн бұрын
When tried to setup data source for loki, it was unable to connect to loki service. Can you please help for solve this?
@pavankumarnalajala2678
@pavankumarnalajala2678 2 жыл бұрын
Please make videos on Splunk for monitoring of k8s.
@justmeandopensource
@justmeandopensource 2 жыл бұрын
I can give it a try
@shamanthreddy8154
@shamanthreddy8154 Жыл бұрын
Can You do a fluentd with loki and Amazon managed grafana
@pisckipratama9529
@pisckipratama9529 2 жыл бұрын
Hi Venkat, thank you for informatic video. I'm deploying it with grafana disabled, and how do I update the grafana enabled without deleting the configured?
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Hi Piscki, thanks for watching. I am not sure if I understood your question correctly. Can you elaborate your requirement please? Thanks.
@pisckipratama9529
@pisckipratama9529 2 жыл бұрын
@@justmeandopensource so i have deployed loki-stack with grafana disabled, but i want to change it to enable, is it possible without running "helmet uninstall" command?
@justmeandopensource
@justmeandopensource 2 жыл бұрын
@@pisckipratama9529 Ah okay. You should be able to change most of the stuff without uninstalling. For example, as shown in this video, if you checked out the values of the chart with "helm show values" to a local file and used that in helm install command with --values option, then you can edit that values file, enable grafana and run "helm upgrade --install --values ". I haven't tried it in this case but I know it worked for me in the past. However there are certain stuff in the values file that you can update on live deployment. You will have to helm uninstall it first and deploy again.
@pisckipratama9529
@pisckipratama9529 2 жыл бұрын
@@justmeandopensource ohh okay Venkat, thanks for the good explanation
@justmeandopensource
@justmeandopensource 2 жыл бұрын
You are welcome.
@amarchand6981
@amarchand6981 2 жыл бұрын
Which shell are you using?
@justmeandopensource
@justmeandopensource 2 жыл бұрын
Zsh along with some goodies which I have explained in this video if you would like to watch. kzbin.info/www/bejne/hoa6n3aYp56WhJo
@Ariel-om1lt
@Ariel-om1lt 3 жыл бұрын
requesting for Grafana tempo too :)
@justmeandopensource
@justmeandopensource 3 жыл бұрын
I will add it to my list. Cheers.
@Ariel-om1lt
@Ariel-om1lt 3 жыл бұрын
@@justmeandopensource Thank you! as always great content!
@justmeandopensource
@justmeandopensource 3 жыл бұрын
@@Ariel-om1lt You are welcome.
@sealedd
@sealedd 2 жыл бұрын
No need to setup a PersistentVolumeClaim?
@justmeandopensource
@justmeandopensource 2 жыл бұрын
It all comes from helm chart. No need to setup pvc but you should have automated volume provisioning in your cluster.
@user-kt9gr4iu9h
@user-kt9gr4iu9h 5 ай бұрын
how to download these logs
@justmeandopensource
@justmeandopensource 5 ай бұрын
Hi, thanks for watching. I am not sure why you would want to download the logs. Its because you wanted to retain the logs from various applications, you have deployed Loki and storing logs in there where you can query and visualize stuff. If you want to download logs, you will have to write a query and store the output in a file. Hope this helps.
@YongUnHeo
@YongUnHeo 3 жыл бұрын
good job man! i want use nodeport service on loki-stack-grafana. teach me edit option. tmp/loki-stack-values.yaml
@justmeandopensource
@justmeandopensource 3 жыл бұрын
Thanks for watching. I will try it out and if possible do a follow up video to this one. Cheers.
@bobbyhamel4345
@bobbyhamel4345 2 жыл бұрын
I don't understand why you would skip setting up an ingress, in a real production env you wouldn't use port forwarding... All tutorials related to Loki fail to acknowledge the ingress.
@ervikasrastogi
@ervikasrastogi 2 жыл бұрын
Hi....I have loki promtail and grafana setup and want to see grafana usage per user with dashboard from grafana.log..I have referer label in logs which is having dashboard name along with https url but i only want to show dashboards accessed userwise..can you please help me for same?
[ Kube 101.1 ] Traefik v2 | Part 1 | How to deploy in Kubernetes
19:06
Just me and Opensource
Рет қаралды 39 М.
Monitoring, Logging, And Alerting In Kubernetes
22:07
DevOps Toolkit
Рет қаралды 28 М.
Grafana Loki: Like Prometheus, But for logs. - Tom Wilkie, Grafana Labs
36:42
CNCF [Cloud Native Computing Foundation]
Рет қаралды 69 М.
[ Kube 26 ] Prometheus monitoring for Kubernetes Cluster and Grafana visualization
34:09
Server Monitoring // Prometheus and Grafana Tutorial
24:36
Christian Lempa
Рет қаралды 620 М.
6 Easy Ways to Improve your Log Dashboards with Grafana and Loki
16:34