Kubernetes Dynamic Provisioning

4 MIN READ
MIN READ

At LogDNA, we're all about speed. We need to ingest, parse, index, and archive several terabytes of data per second. To reach these speeds, we need to find and implement innovative solutions for optimizing all steps of our pipeline, especially when it comes to storing data. Our architecture makes heavy use of Kubernetes distribution since it lets us deploy, manage, and scale quickly. However, we quickly ran into bottlenecks when attempting to store data for use in pods. To maximize efficiency and reduce costs, we needed to make use of local storage. To overcome this problem, we developed a solution for letting Pods store data directly on the node's disk. This solution lets us deploy high-volume workloads without breaking a key factor of microservices. In this post, we'll explain how our local storage solution works and how it enables us to manage enormous volumes of data without breaking Kubernetes.

The Problem With Local Storage in Kubernetes

Kubernetes has a number of options for letting pods store persistent data, but Kubernetes itself was originally designed to support only network storage. This is fine for most use cases on cloud infrastructure and while network speeds have gotten significantly faster over time, there's still an additional latency factor and a risk of bottlenecks due to network traffic. High-performance applications need a faster data storage solution, and using the node's local disk is the best alternative.Before the local volume type was introduced, the only way for a Pod to access local storage was by:

  • Using hostPath to mount a local directory to the Pod
  • Using a temporary, blank volume with emptyDir

These options either have limited functionality for our needs, or they required us to configure the host in advance. In both cases, our ability to automate deployments was limited. The local volume type aims to resolve some of these issues, but it's currently still in beta. We needed a solution that could be deployed as a Kubernetes workload, didn't require node-specific configurations, and could also handle scaling.

Overcoming Challenges with Kubernetes Local Storage

Implementing a disk-based storage solution in Kubernetes poses several challenges.

Our first challenge was determining how to provision storage for Pods. Each Pod requires a certain amount of disk space to complete its tasks. At the same time, we didn’t want a single Pod to consume a disproportionate amount of disk space by generating an excessive amount of data. By partitioning disks and assigning each Pod to a partition, we solve both of these problems.

Our next challenge was scheduling Pods. Since Pods are directly linked to host resources, we’re unable to easily migrate workloads across nodes. Once a Pod is scheduled on a node, it’s there for good. However, this doesn’t mean we don’t have any replication. Instead of relying on Kubernetes or a network storage solution to replicate our data, we handle replication within the application itself. This is similar to how applications like Elasticsearch handle clustering and replication internally.

This leads into our final challenge, which was tracking changes to Pods and their associated partitions. More specifically, handling Pod or node failures. Since partitions are linked to specific Pod instances, we can’t easily reuse a partition in the event of a Pod failure. This is less of a problem for us since our containerized application already handles replication, but it does mean an unused partition is left on the node. If we can restart the failed Pod, then it will mount the partition and continue working as before. But if we can’t restart it, then we need a way to identify and clean up the unused partition so another Pod can take its place.

LogDNA's Provisioner

At the heart of our solution is a DaemonSet running a service that monitors and partitions disk space for incoming Pods. Deploying our solution as a DaemonSet ensures that it runs on each node in our cluster, even if we add new nodes. The DaemonSet has two responsibilities:

  1. Monitor the Kubernetes scheduler for new Pods that are requesting disk space
  2. Provision and manage local disk storage for those Pods

Instead of mounting a file or directory, the DaemonSet mounts the newly created partition to the Pod. Using disk partitions instead of directories lets us set aside a specific amount of disk space for each Pod and separate Pod storage for easier isolation and cleanup.

Conclusion

Local storage is a growing topic in Kubernetes, especially for applications with high I/O requirements. Although local volumes are available in Kubernetes today, they're still in beta and don't yet support dynamic provisioning. We're interested in seeing how local storage develops in Kubernetes, and how it affects the performance of disk-heavy workloads in the future. Get in touch if you're working on or have use cases for dynamic provisioning in Kubernetes.Happy to connect through K8s Slack if you’re working on or have use cases for dynamic provisioning in Kubernetes.

Table of Contents

    Share Article

    RSS Feed

    Next blog post
    You're viewing our latest blog post.
    Previous blog post
    You're viewing our oldest blog post.
    Mezmo + Catchpoint deliver observability SREs can rely on
    Mezmo’s AI-powered Site Reliability Engineering (SRE) agent for Root Cause Analysis (RCA)
    What is Active Telemetry
    Launching an agentic SRE for root cause analysis
    Paving the way for a new era: Mezmo's Active Telemetry
    The Answer to SRE Agent Failures: Context Engineering
    Empowering an MCP server with a telemetry pipeline
    The Debugging Bottleneck: A Manual Log-Sifting Expedition
    The Smartest Member of Your Developer Ecosystem: Introducing the Mezmo MCP Server
    Your New AI Assistant for a Smarter Workflow
    The Observability Problem Isn't Data Volume Anymore—It's Context
    Beyond the Pipeline: Data Isn't Oil, It's Power.
    The Platform Engineer's Playbook: Mastering OpenTelemetry & Compliance with Mezmo and Dynatrace
    From Alert to Answer in Seconds: Accelerating Incident Response in Dynatrace
    Taming Your Dynatrace Bill: How to Cut Observability Costs, Not Visibility
    Architecting for Value: A Playbook for Sustainable Observability
    How to Cut Observability Costs with Synthetic Monitoring and Responsive Pipelines
    Unlock Deeper Insights: Introducing GitLab Event Integration with Mezmo
    Introducing the New Mezmo Product Homepage
    The Inconvenient Truth About AI Ethics in Observability
    Observability's Moneyball Moment: How AI Is Changing the Game (Not Ending It)
    Do you Grok It?
    Top Five Reasons Telemetry Pipelines Should Be on Every Engineer’s Radar
    Is It a Cup or a Pot? Helping You Pinpoint the Problem—and Sleep Through the Night
    Smarter Telemetry Pipelines: The Key to Cutting Datadog Costs and Observability Chaos
    Why Datadog Falls Short for Log Management and What to Do Instead
    Telemetry for Modern Apps: Reducing MTTR with Smarter Signals
    Transforming Observability: Simpler, Smarter, and More Affordable Data Control
    Datadog: The Good, The Bad, The Costly
    Mezmo Recognized with 25 G2 Awards for Spring 2025
    Reducing Telemetry Toil with Rapid Pipelining
    Cut Costs, Not Insights:   A Practical Guide to Telemetry Data Optimization
    Webinar Recap: Telemetry Pipeline 101
    Petabyte Scale, Gigabyte Costs: Mezmo’s Evolution from ElasticSearch to Quickwit
    2024 Recap - Highlights of Mezmo’s product enhancements
    My Favorite Observability and DevOps Articles of 2024
    AWS re:Invent ‘24: Generative AI Observability, Platform Engineering, and 99.9995% Availability
    From Gartner IOCS 2024 Conference: AI, Observability Data, and Telemetry Pipelines
    Our team’s learnings from Kubecon: Use Exemplars, Configuring OTel, and OTTL cookbook
    How Mezmo Uses a Telemetry Pipeline to Handle Metrics, Part II
    Webinar Recap: 2024 DORA Report: Accelerate State of DevOps
    Kubecon ‘24 recap: Patent Trolls, OTel Lessons at Scale, and Principle Platform Abstractions
    Announcing Mezmo Flow: Build a Telemetry Pipeline in 15 minutes
    Key Takeaways from the 2024 DORA Report
    Webinar Recap | Telemetry Data Management: Tales from the Trenches
    What are SLOs/SLIs/SLAs?
    Webinar Recap | Next Gen Log Management: Maximize Log Value with Telemetry Pipelines
    Creating In-Stream Alerts for Telemetry Data
    Creating Re-Usable Components for Telemetry Pipelines
    Optimizing Data for Service Management Objective Monitoring
    More Value From Your Logs: Next Generation Log Management from Mezmo
    A Day in the Life of a Mezmo SRE
    Webinar Recap: Applying a Data Engineering Approach to Telemetry Data
    Dogfooding at Mezmo: How we used telemetry pipeline to reduce data volume
    Unlocking Business Insights with Telemetry Pipelines
    Why Your Telemetry (Observability) Pipelines Need to be Responsive
    How Data Profiling Can Reduce Burnout
    Data Optimization Technique: Route Data to Specialized Processing Chains
    Data Privacy Takeaways from Gartner Security & Risk Summit
    Mastering Telemetry Pipelines: Driving Compliance and Data Optimization
    A Recap of Gartner Security and Risk Summit: GenAI, Augmented Cybersecurity, Burnout
    Why Telemetry Pipelines Should Be A Part Of Your Compliance Strategy
    Pipeline Module: Event to Metric
    Telemetry Data Compliance Module
    OpenTelemetry: The Key To Unified Telemetry Data
    Data optimization technique: convert events to metrics
    What’s New With Mezmo: In-stream Alerting
    How Mezmo Used Telemetry Pipeline to Handle Metrics
    Webinar Recap: Mastering Telemetry Pipelines - A DevOps Lifecycle Approach to Data Management
    Open-source Telemetry Pipelines: An Overview
    SRECon Recap: Product Reliability, Burn Out, and more
    Webinar Recap: How to Manage Telemetry Data with Confidence
    Webinar Recap: Myths and Realities in Telemetry Data Handling
    Using Vector to Build a Telemetry Pipeline Solution
    Managing Telemetry Data Overflow in Kubernetes with Resource Quotas and Limits
    How To Optimize Telemetry Pipelines For Better Observability and Security
    Gartner IOCS Conference Recap: Monitoring and Observing Environments with Telemetry Pipelines
    AWS re:Invent 2023 highlights: Observability at Stripe, Capital One, and McDonald’s
    Webinar Recap: Best Practices for Observability Pipelines
    Introducing Responsive Pipelines from Mezmo
    My First KubeCon - Tales of the K8’s community, DE&I, sustainability, and OTel
    Modernize Telemetry Pipeline Management with Mezmo Pipeline as Code
    How To Profile and Optimize Telemetry Data: A Deep Dive
    Kubernetes Telemetry Data Optimization in Five Steps with Mezmo
    Introducing Mezmo Edge: A Secure Approach To Telemetry Data
    Understand Kubernetes Telemetry Data Immediately With Mezmo’s Welcome Pipeline
    Unearthing Gold: Deriving Metrics from Logs with Mezmo Telemetry Pipeline
    Webinar Recap: The Single Pane of Glass Myth
    Empower Observability Engineers: Enhance Engineering With Mezmo
    Webinar Recap: How to Get More Out of Your Log Data
    Unraveling the Log Data Explosion: New Market Research Shows Trends and Challenges
    Webinar Recap: Unlocking the Full Value of Telemetry Data
    Data-Driven Decision Making: Leveraging Metrics and Logs-to-Metrics Processors
    How To Configure The Mezmo Telemetry Pipeline
    Supercharge Elasticsearch Observability With Telemetry Pipelines
    Enhancing Grafana Observability With Telemetry Pipelines
    Optimizing Your Splunk Experience with Telemetry Pipelines
    Webinar Recap: Unlocking Business Performance with Telemetry Data
    Enhancing Datadog Observability with Telemetry Pipelines
    Transforming Your Data With Telemetry Pipelines