<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Shreelakshmi Javagal on Medium]]></title>
        <description><![CDATA[Stories by Shreelakshmi Javagal on Medium]]></description>
        <link>https://medium.com/@akshatajavagal99?source=rss-8a44f04d2774------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*WTsA5WIN3fMbTAI6</url>
            <title>Stories by Shreelakshmi Javagal on Medium</title>
            <link>https://medium.com/@akshatajavagal99?source=rss-8a44f04d2774------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 18:21:27 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@akshatajavagal99/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Crafting Seamless Deployments: Docker, Kubernetes, and Helm Unite for Java Spring Boot Applications]]></title>
            <link>https://medium.com/@akshatajavagal99/deploying-a-java-application-onto-a-kubernetes-cluster-using-docker-f5653c0161e4?source=rss-8a44f04d2774------2</link>
            <guid isPermaLink="false">https://medium.com/p/f5653c0161e4</guid>
            <dc:creator><![CDATA[Shreelakshmi Javagal]]></dc:creator>
            <pubDate>Thu, 10 Aug 2023 12:12:41 GMT</pubDate>
            <atom:updated>2023-08-17T07:12:35.152Z</atom:updated>
            <content:encoded><![CDATA[<p>Hello there🌻</p><p>In this article, we will be deploying a Java Spring Boot Application on Kubernetes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*PXvbKCQgXqFYT3_H.png" /></figure><blockquote><strong>Pre-requisites:</strong></blockquote><p>1. <strong>Java Application Code</strong>: You’ll need a Java application’s base code or a microservice setup, but don’t worry — we’re focusing on deployment, not development.</p><p>2. <strong>Docker Installed</strong>: Ensure Docker is up and running on your machine(Docker Desktop). It’s vital for building, testing, and pushing your application’s Docker images.</p><p>3. <strong>Kubernetes Cluster</strong>: Have a Kubernetes cluster ready for action(Enable Kubernetes in Docker Desktop). This is where your application will shine once deployed.</p><p>4. <strong>Maven Installed</strong>: A fundamental grasp of Maven will help you navigate the build process with confidence.</p><p>5. <strong>Docker Know-How</strong>: Familiarity with Docker is key. You’ll be crafting Dockerfiles and generating Docker images to encapsulate your app.</p><p>6. <strong>Understanding Kubernetes</strong>: A grasp of Kubernetes is crucial. You’ll be working with service and deployment YAML files to orchestrate your application.</p><p><strong>7</strong>. <strong>Helm Installed: </strong><a href="https://www.geeksforgeeks.org/installing-helm-kubernetes-in-docker/">https://www.geeksforgeeks.org/installing-helm-kubernetes-in-docker/</a></p><blockquote><strong>Workflow:</strong></blockquote><p>The workflow ensures that your application is scalable, manageable, and accessible to end users. Let’s dive right in!</p><p><strong><em>Step 1: Code Setup</em></strong></p><p>We’ll start by checking out the code from GitHub repository. Clone the project — <a href="https://github.com/shreelakshmi1111/Deploy-Java-Application.git">https://github.com/shreelakshmi1111/Deploy-Java-Application.git</a>. This code serves as the foundation, the base of our Java application.</p><p><strong><em>Step 2: Start Docker Desktop and Enable Kubernetes</em></strong></p><p><strong><em>Step 3: Build the Java Application</em></strong></p><p>Open a terminal and navigate to the project directory containing the `pom.xml` file. Run the below command to build the Java application. This will generate a target directory containing the jar files.</p><pre>mvn clean install</pre><p><strong><em>Step 4: Containerization with Docker</em></strong></p><p>Now we’re going to containerize our Java application using Docker. Docker allows us to package our application, its dependencies, and the runtime environment into a single Docker image. We achieve this by creating a Dockerfile, which outlines the steps to build the image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*zo8FOGuLbcwO801N.jpg" /></figure><p><strong><em>Step 5: Creating the Docker Image</em></strong></p><p>With the Dockerfile in place, we’ll use the ‘docker build’ command. This command takes the JAR file and other resources, copying them into the Docker image. The result is a self-contained Docker image ready to run our Java application.</p><pre>Run these commands in particular microservices folder to build the docker image:<br><br>docker build -t shreelakshmispsl/shopfront:latest . <br>docker build -t shreelakshmispsl/productcatalogue:latest .<br>docker build -t shreelakshmispsl/stockmanager:latest .</pre><p><strong><em>Step 6: Storing in Docker Hub</em></strong></p><p>To make our Docker image accessible and shareable, we’ll store it in Docker Hub. Docker Hub is a repository for Docker images, much like GitHub is for code. By pushing our image to Docker Hub, we ensure that it’s available for use in different environments.</p><pre>docker login -u &lt;username&gt; -p &lt;password&gt;<br>Run these commands in particular microservices folder to pushthe docker image:<br>docker push shreelakshmispsl/shopfront:latest <br>docker push shreelakshmispsl/productcatalogue:latest <br>docker push shreelakshmispsl/stockmanager:latest </pre><p><strong><em>Step 7: Kubernetes Deployment</em></strong></p><p>Now comes the exciting part — deploying our Java application onto a Kubernetes cluster. Kubernetes enables efficient management, scaling, and orchestration of containerized applications. We’ll set up services and deployments within Kubernetes to ensure our application runs smoothly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/953/0*O7TQjfBzfyazcrqL" /></figure><pre>Run these commands in Kubernetes folder:<br>kubectl apply -f shopfront-service.yaml   <br>kubectl apply -f productcatalogue-service.yaml   <br>kubectl apply -f stockmanager-service.yaml   </pre><p><strong><em>Step 8: Accessing the Application</em></strong></p><p>With our Java application running in the Kubernetes cluster, we configure routes and services to expose it externally. This means end users can access your application through a web browser, creating a seamless experience.</p><pre>To Get the nodeport – kubectl get all <br>- Shop Front: ` http://localhost:nodeport`<br>- Product Catalog: ` http://localhost:nodeport/products`<br>- Stock Manager: ` http://localhost:nodeport/stocks`</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*n9CXHLu_1rm-BpvqYSr9BA.png" /><figcaption><strong>Shop Front</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zkI8vXschDzESplF3vck1A.png" /><figcaption><strong>Product Catalog</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XvXr98KwxxOBwVjuMLmGcw.png" /><figcaption><strong>Stock Manager</strong></figcaption></figure><p>And there you have it! This manual process provides a deep understanding of the deployment process. While we can automate these steps with continuous integration tools like Jenkins, it’s important to grasp the fundamental concepts first. This workflow can be applied to various types of Java applications, making it a versatile approach to modern application deployment.</p><h3>Templating with Helm</h3><blockquote><em>Helm is a tool for managing Kubernetes charts. Charts are packages of pre-configured Kubernetes resources.</em></blockquote><p><a href="https://github.com/kubernetes/helm">Helm</a> is an open source project maintained by the Kubernetes organization. It makes it easy to pack, ship and update Kubernetes resources together as a single package.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1004/0*tv2R9QmTvSQPwhs2.png" /></figure><p>One of the best parts of Helm is that it comes with an open-source <a href="https://github.com/kubernetes/charts">repository</a> maintained by the community, where you can find hundreds of different pre-packed solutions from databases like MongoDB and Redis, to applications like WordPress and OpenVPN.</p><h3><strong>Now let’s deploy this Java Spring Boot Application on Kubernetes using Helm-Charts.</strong></h3><p><strong><em>Step 1: Remove the services &amp; deployments from the K8s cluster i.e., delete all the deployment and service files</em></strong></p><pre>kubectl delete service --all  <br>kubectl delete deployment -all </pre><p>Now, verify all the services &amp; deployments are removed from the cluster using <em>kubectl get all</em> command.</p><p><strong><em>Step 2: Create Helm Chart Directory for all the microservices files</em></strong></p><pre>For Shopfront - helm create helm-charts<br>For Productcatalogue - helm create helm-products<br>For Stockmanager - helm create helm-s</pre><p>Now, delete the unnecessary files from helm-chart folder — tests folder, In templates folder delete all files except deployment.yaml &amp; service.yaml.</p><p><strong><em>Step 3: Edit deployment.yaml, service.yaml &amp; values.yaml files</em></strong></p><p>Reference : <a href="https://github.com/shreelakshmi1111/Deploy-Java-Application.git">https://github.com/shreelakshmi1111/Deploy-Java-Application.git</a></p><p><strong><em>Step 4: Test the helm-chart’s template</em></strong></p><pre>For Shopfront - helm template test .\helm-charts\<br>For Productcatalogue - helm template test .\helm-products\<br>For Stockmanager - helm template test .\helm-s\ </pre><p><strong><em>Step 5: Deploy with Helm</em></strong></p><pre>For Productcatalogue - helm install products  .\helm-products\<br>For Stockmanager - helm install stocks .\helm-s\     <br>For Shopfront - helm install shopfront .\helm-charts\</pre><p><strong><em>Step 5: Access the Service</em></strong></p><pre>To Get the nodeport – kubectl get all <br>- Product Catalog: ` http://localhost:nodeport/products`<br>- Stock Manager: ` http://localhost:nodeport/stocks`<br>- Shop Front: ` http://localhost:nodeport`</pre><p>Thank you for your time, and I hope this overview gives you a clear picture of how we deploy Java applications using Docker and Kubernetes!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f5653c0161e4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Visualizing Log Data with Grafana, Loki, and Promtail]]></title>
            <link>https://medium.com/@akshatajavagal99/visualizing-log-data-with-grafana-loki-and-promtail-2e27543d1e0?source=rss-8a44f04d2774------2</link>
            <guid isPermaLink="false">https://medium.com/p/2e27543d1e0</guid>
            <dc:creator><![CDATA[Shreelakshmi Javagal]]></dc:creator>
            <pubDate>Thu, 03 Aug 2023 07:13:22 GMT</pubDate>
            <atom:updated>2023-08-03T07:13:40.984Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*V9y8pA4YgE3OgyyI.jpeg" /></figure><p>Now, it’s time to creating a dashboard using Grafana with integration of Loki and Promtail</p><p>In this exciting task, we’ll explore how Grafana enables you to monitor and analyze various components of your server in real-time.</p><p>So, let’s dive in and make monitoring a breeze!</p><h3>- What is Loki and Promtail..??</h3><p>Loki and Promtail are two key components of a log monitoring stack that work together to provide efficient log aggregation and analysis. Here’s a summary of their usage and the difference between them:</p><ol><li><strong>Loki:</strong> Loki is a horizontally scalable log aggregation system that stores and indexes log data for efficient querying and analysis. It acts as the central repository for log data and enables fast, distributed log processing.</li><li><strong>Promtail:</strong> Promtail is a lightweight log collector that runs on individual servers or containers and collects log data from various sources. It tails log files or streams and sends the data to Loki for storage and analysis.</li></ol><h3>- Creating a dashboard using Grafana with integration of Loki and Promtail.</h3><h3>Install Loki and Promtail using Docker</h3><h3>Install Grafana:</h3><p>we have discussed in previously story how to install Grafana you can read <a href="https://medium.com/p/2e27543d1e0/edit"><strong>here</strong></a><strong>.</strong></p><h3>Install Docker:</h3><p>Updates the package lists on the system, ensuring that the latest package information is available for installation.</p><pre>sudo apt-get update<br>sudo apt install docker.io<br>sudo usermod -aG docker $USER<br>sudo reboot</pre><ol><li>sudo apt install docker.io: Installs the Docker package on Ubuntu, enabling the use of Docker containers to deploy and manage applications.</li><li>sudo usermod -aG docker $USER: Grants the current user permission to run Docker commands by adding them to the docker group. This allows the user to execute Docker commands without using sudo for elevated privileges.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*5T10RHDQTsR8czHq.png" /></figure><h3>Download Loki Config:</h3><p>Use the following command to download the Loki configuration file:</p><pre>mkdir grafana_configs<br>cd grafana_configs<br>wget <br>https://raw.githubusercontent.com/grafana/loki/v2.8.0/cmd/loki/loki-local-config.yaml -O loki-config.yaml</pre><ul><li>This command uses wget to download the Loki configuration file from the specified URL.</li><li>The configuration file contains settings for Loki, such as storage configurations, retention policies, and remote storage options.</li></ul><h3>Download Promtail Config</h3><p>Download the Promtail configuration file using the command below in grafana_configs directory:</p><pre>wget <br>https://raw.githubusercontent.com/grafana/loki/v2.8.0/clients/cmd/promtail/promtail-docker-config.yaml -O promtail-config.yaml</pre><ul><li>The configuration file contains settings for Promtail, such as log file paths, labels, and target Loki endpoints.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*-LyhpR18B_dGl13a.png" /></figure><h3>Run Loki Docker container:</h3><p>Execute the following command to run the Loki Docker container, providing the downloaded configuration file:</p><pre>sudo docker run -d <br>--name loki -v $(pwd):/mnt/config -p 3100:3100<br>grafana/loki:2.8.0 --config.file=/mnt/config/loki-config.yaml</pre><ul><li>This command starts a Docker container named “loki” using the grafana/loki:2.8.0 image.</li><li>The -d flag runs the container in detached mode.</li><li>The -v flag mounts the current directory ($(pwd)) as a volume inside the container, allowing the Loki configuration file to be accessed.</li><li>The -p flag maps port 3100 of the container to the host, enabling access to Loki&#39;s HTTP endpoint.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*20RPJJ__BuMZLQ91.png" /></figure><ul><li>Edit inbound rule in security group of ec2 instance allow port 3100.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Kq8j0PaXhmqz3lA7.png" /></figure><ul><li>Copy public-ip of instance and paste in browser on https:&lt;public-ip&gt;:3100/ready and check loki is ready..?</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*TNuSAKuxwftpa-Ty.png" /></figure><ul><li>Yes Loki is Ready</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*tl6Vxc3ZqsppSw5D.png" /></figure><ul><li>In Loki what kind of logs or metrics are there we can get those like this use /metrics`</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*qwSryCmJ8l5DLtpc.png" /></figure><h3>Run Promtail Docker container:</h3><p>Run the Promtail Docker container with the downloaded configuration file, mounting the host’s log directory:</p><pre>sudo docker run -d --name promtail -v $(pwd):/mnt/config -v /var/log:/var/log <br>--link loki grafana/promtail:2.8.0 <br>--config.file=/mnt/config/promtail-config.yaml</pre><ul><li>This command starts a Docker container named “promtail” using the grafana/promtail:2.8.0 image.</li><li>The -d flag runs the container in detached mode.</li><li>The -v flag mounts the current directory ($(pwd)) as a volume inside the container, allowing access to the Promtail configuration file.</li><li>The second -v flag mounts the host&#39;s /var/log directory to the container&#39;s /var/log directory, enabling Promtail to collect logs from the host.</li><li>The --link loki flag establishes a network link between the Loki container and the Promtail container.</li><li>The --config.file flag specifies the location of the Promtail configuration file.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*5DjklASWnLalM-NU.png" /></figure><h3>- Add Data source in Grafana</h3><ul><li>Now, navigate to the Grafana webapp and on the homepage choose the add data source option.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*8rp_pyHGtO1dWc4w.png" /></figure><ul><li>Provide the HTTP URL as below to connect the loki data source to Grafana so that loki will send the logs to grafana.</li><li><a href="http://localhost:3100/"><em>localhost:3100</em></a></li><li>Click on save &amp; test to connect the data source.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Prwpl3FyrDYVtCBT.png" /></figure><h3>- Checking logs in Loki:</h3><ul><li>Click on explore in the below screenshot after adding the data source.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*aFn5GpGfPcBRNrhw.png" /></figure><ul><li>In the label filters, we can choose job and varlogs which is generally the path /var/log/*log in the backend to show all the system logs.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*N0AD8tQkoU66603w.png" /></figure><ul><li>Click on the run query in the above screenshot to execute and show all the system logs as below.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*brSaKoIykwesgj7H.png" /></figure><h3>- Now we have to Create Dashboard:</h3><ul><li>Let’s add the log to the dashboard by choosing the option from the above screenshot location.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*I80OHF1Zutt4rgDF.png" /></figure><ul><li>Now the system logs are added to the grafana dashboard.</li><li>Let’s add some more by clicking on visualization to add some graphs as shown below screenshot.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*15MNwfkMSbwix93n.png" /></figure><ul><li>In Label filters choose job and varlogs and line contains to error to show all the lines Run Query.</li><li>On right hand side choose Logs &gt; Click to change vizualization &gt; select row format as shown in below.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Lc5yJkBZBgFXyAy_.png" /></figure><ul><li><strong>Similarly, let’s check the error lines in grafana log that is placed in <em>/var/log/grafana/grafana.log</em></strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*laPyuJE4a5qQ0I6j.png" /></figure><ul><li>To accomplish the objective of displaying the Grafana log, we must specify the Grafana log path in the promtail config YAML file within the target section, as illustrated below.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*TkBlrYW_U7kiuBgZ.png" /></figure><ul><li>After edit promtail_config.yaml file we have to restart our promtail docker container</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*AJXNLnfD6JDl3jKl.png" /></figure><ul><li>We can now choose the label filters to set the job and grafana logs with the line contains and visualization option to view in a graphical manner. We can add this to our dashboard.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*GbjnZp1iLDReaeeC.png" /></figure><ul><li>Use the proper label filters to show an aggregate sum of words repeating nginx while installing. This can be achieved by setting the varlogs as label filters.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*dRnE2v5GoPd9E5U8.png" /></figure><ul><li>We can see now the complete grafana dashboard.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*X95Dto8W7ZMijkuF.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2e27543d1e0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Grafana: Gateway to Advanced Monitoring & Visualization]]></title>
            <link>https://medium.com/@akshatajavagal99/grafana-gateway-to-advanced-monitoring-visualization-2822952ae155?source=rss-8a44f04d2774------2</link>
            <guid isPermaLink="false">https://medium.com/p/2822952ae155</guid>
            <dc:creator><![CDATA[Shreelakshmi Javagal]]></dc:creator>
            <pubDate>Thu, 03 Aug 2023 06:54:58 GMT</pubDate>
            <atom:updated>2023-08-03T06:54:58.237Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*U_3YTq-GSDhD8kSH.jpeg" /></figure><p>Grafana, a powerful tool that enables intelligent monitoring of your resources.</p><p>In this story, we’ll explore what Grafana is, its key features, the reasons behind its popularity, the types of monitoring it supports, compatible databases, and the distinction between Grafana and Prometheus.</p><blockquote>What is Grafana?</blockquote><blockquote>Grafana is an open-source analytics and visualization platform designed for monitoring and observability. It allows you to query, visualize, and understand your metrics from various data sources in real-time. With its flexible and user-friendly interface, Grafana enables you to create customizable dashboards and alerts, making it a go-to solution for monitoring and analyzing complex systems.</blockquote><h3>- What are the features of Grafana?</h3><ol><li><strong>Data Source Flexibility:</strong> Grafana supports a wide range of data sources, including popular databases like Graphite, Prometheus, InfluxDB, Elasticsearch, and more. This flexibility allows you to connect to your preferred data source and leverage Grafana’s visualization capabilities.</li><li><strong>Rich Visualization Options:</strong> Grafana provides a rich set of visualizations, including graphs, charts, tables, heatmaps, and more. You can customize these visualizations, apply transformations, and create dynamic dashboards that suit your specific monitoring needs.</li><li><strong>Alerting and Notification:</strong> Grafana empowers you to set up alerts based on predefined conditions and thresholds. When these conditions are met, Grafana can trigger notifications via various channels such as email, Slack, PagerDuty, and more, ensuring timely response to critical incidents.</li><li><strong>Dashboard Templating:</strong> With Grafana’s dashboard templating feature, you can create dynamic and reusable dashboards. Templating enables you to define variables that can be dynamically populated, allowing for easy exploration and monitoring of different aspects of your system.</li><li><strong>Plugin Ecosystem:</strong> Grafana boasts a vibrant plugin ecosystem, providing additional functionality and integrations. You can enhance your Grafana experience by installing plugins for specific data sources, panels, and even custom visualizations.</li></ol><h3>Why Grafana?</h3><p>Grafana has gained immense popularity among developers and system administrators for several reasons:</p><ol><li><strong>Intuitive User Interface:</strong> Grafana offers a user-friendly interface that simplifies the process of creating and managing monitoring dashboards. Its drag-and-drop functionality, coupled with rich visualization options, makes it easy for users of all skill levels to build informative and interactive dashboards.</li><li><strong>Extensibility and Integration:</strong> Grafana’s flexibility lies in its ability to integrate with a wide range of data sources and systems. Whether you’re using traditional databases, time-series databases, or cloud-native observability solutions, Grafana can connect to and consolidate data from multiple sources, providing a unified view of your infrastructure.</li><li><strong>Community Support:</strong> Grafana benefits from a strong and active community of users and contributors. This active community ensures continuous development, regular updates, and a wealth of resources, including plugins, tutorials, and community-driven dashboards, making it easier for newcomers to get started and experienced users to enhance their monitoring setups.</li></ol><h3>- What type of monitoring can be done via Grafana?</h3><p>Grafana supports various types of monitoring, including but not limited to:</p><ol><li><strong>System Monitoring:</strong> Keep track of CPU usage, memory utilization, disk space, network traffic, and other system-level metrics to gain insights into the health and performance of your infrastructure.</li><li><strong>Application Monitoring:</strong> Monitor the performance and behavior of your applications by tracking metrics such as response times, request rates, error rates, and other application-specific indicators.</li><li><strong>Infrastructure Monitoring:</strong> Grafana allows you to monitor and visualize metrics related to your cloud infrastructure, containers, virtual machines, and other infrastructure components.</li></ol><h3>- What databases work with Grafana?</h3><p>Grafana is compatible with a wide range of databases, allowing users to connect and visualize data from different sources. Some of the databases that work seamlessly with Grafana include:</p><p><strong>1. Prometheus:</strong> Grafana integrates well with Prometheus, a popular open-source monitoring and alerting system. It allows users to query and visualize metrics collected by Prometheus.</p><p><strong>2. InfluxDB:</strong> Grafana has native support for InfluxDB, a high-performance time-series database. It enables users to connect to InfluxDB and create visualizations based on the stored time-series data.</p><p><strong>3. Elasticsearch:</strong> Grafana can connect to Elasticsearch, a distributed search and analytics engine, to fetch and display data in real-time. It provides powerful querying capabilities and visualizations for Elasticsearch data.</p><p><strong>4. MySQL:</strong> Grafana supports MySQL, an open-source relational database management system. Users can connect to MySQL databases to fetch and visualize data using Grafana’s querying and visualization features.</p><p><strong>5. PostgreSQL:</strong> Grafana also works with PostgreSQL, an advanced open-source database system. It allows users to connect to PostgreSQL databases and create visualizations based on the queried data.</p><p><strong>6. Microsoft SQL Server:</strong> Grafana provides support for Microsoft SQL Server, a relational database management system developed by Microsoft. Users can connect to SQL Server databases and leverage Grafana’s visualization capabilities.</p><p>These are just a few examples of the databases that work with Grafana. Grafana’s flexibility and extensibility make it compatible with many other databases, enabling users to connect to their preferred data sources and visualize the data effectively.</p><h3>- What are metrics and visualizations in Grafana?</h3><p>In Grafana, metrics refer to the numerical data that is collected and monitored from various sources, such as databases, APIs, or monitoring systems. These metrics can represent different aspects of system performance, resource utilization, network statistics, or any other measurable data relevant to monitoring.</p><p>Visualizations, on the other hand, are the graphical representations of these metrics. Grafana offers a wide range of visualization options, including line charts, bar graphs, histograms, gauges, heatmaps, and more. These visualizations allow users to interpret and analyze the collected metrics in a meaningful way.</p><p>Overall, metrics and visualizations in Grafana play a crucial role in monitoring and analyzing data, enabling users to effectively track and understand the behavior and performance of their systems, applications, or infrastructure.</p><h3>- What is the difference between Grafana vs Prometheus?</h3><p>Grafana and Prometheus are both popular tools used in monitoring and observability, but they serve different purposes.</p><p>Grafana is a data visualization and analytics platform that allows users to create rich and interactive dashboards to visualize data from various sources. It supports a wide range of data sources, including Prometheus, and offers extensive customization and dashboarding capabilities. Grafana excels at providing visually appealing and user-friendly representations of data.</p><p>On the other hand, Prometheus is a time-series database and monitoring system. It is designed specifically for collecting, storing, and querying time-series data, typically related to system metrics, application performance, and other operational data. Prometheus provides powerful querying and alerting functionalities and is well-suited for monitoring and alerting in dynamic environments.</p><p>In summary, Grafana focuses on data visualization and dashboarding, allowing users to create stunning visual representations of data from different sources. Prometheus, on the other hand, specializes in data collection, storage, and querying for monitoring and alerting purposes. While Grafana can integrate with Prometheus as a data source, they serve distinct functions in the monitoring ecosystem.</p><h3>- Setup Grafana in your local environment on AWS EC2.</h3><ul><li>Go to the AWS console, and create an EC2 instance named “grafana-server”.</li><li>With basic configuration OS`- ubuntu server 22.04 LTS` ,Instance type`- t2.micro` , Select or create new key and Launch Instance`</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*EWKH7wY2wFHLvhXo.png" /></figure><ul><li>After successfully launched instance connect SSH into instance.</li><li>We have to follow installation guide as follows.</li><li>Download the Grafana <a href="https://www.digitalocean.com/community/tutorials/how-to-use-gpg-to-encrypt-and-sign-messages">GPG key</a> with <a href="https://www.gnu.org/software/wget/">wget</a>, then <a href="https://www.digitalocean.com/community/tutorials/an-introduction-to-linux-i-o-redirection#pipes">pipe the output</a> to gpg.</li></ul><pre>wget -q -O - https://packages.grafana.com/gpg.key | gpg --dearmor | sudo tee /usr/share/keyrings/grafana.gpg &gt; /dev/null</pre><ul><li>Next, add the Grafana repository to your APT sources:</li></ul><pre>echo &quot;deb [signed-by=/usr/share/keyrings/grafana.gpg] https://packages.grafana.com/oss/deb stable main&quot; | sudo tee -a /etc/apt/sources.list.d/grafana.list</pre><ul><li>Refresh your APT cache to update your package lists:</li></ul><pre>sudo apt update</pre><ul><li>You can now proceed with the installation:</li></ul><pre>sudo apt install grafana</pre><ul><li>Once Grafana is installed, use systemctl to start the Grafana server:</li></ul><pre>sudo systemctl start grafana-server</pre><ul><li>Next, verify that Grafana is running by checking the service’s status:</li></ul><pre>sudo systemctl status grafana-server</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*x-xReKMbOBHOAimq.png" /></figure><ul><li>Lastly, enable the service to automatically start Grafana on boot:</li></ul><pre>sudo systemctl enable grafana-server</pre><ul><li>Now, allow the inbound port 3000 from the “Security Group” because Grafana is running on 3000 port.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*f6uFpAIwjLsbUjtu.png" /></figure><ul><li>Now, goto the browser and search with “http:&lt;public-ip-of-ec2&gt;:3000”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*CiBcM7N1PNMgjTql.png" /></figure><ul><li>Yeesss, WELCOME TO GRAFANA…..</li><li>Login using default login-id`and password`as admin` and admin` then you can change this default password as you wish.</li><li>You will be entered in the Grafana dashboard.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*srf9x_lhzO_D6J5WilmU0w.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2822952ae155" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>