Azure Data Lake Storage Gen2

Azure Data Lake Storage Gen2

A clear, patient guide to the storage service built for big data and analytics: how it keeps files organized like folders, how it protects them, how to design a lake that stays tidy, and how to keep its cost and speed under control.

Imagine a huge warehouse where a company keeps everything it might one day need: invoices, photographs, sensor readings, website logs, spreadsheets, and recordings. At first the warehouse is a joy, because anything can be thrown in without sorting. A year later nobody can find anything, nobody knows which boxes are safe to throw away, and every visitor needs a different key. The warehouse has become a swamp.

A data lake is that warehouse for digital information, and Azure Data Lake Storage Gen2 is a place to build one properly. It stores files of any size and any kind, arranges them in real folders, controls who may enter each room, and lets powerful analytics tools read vast amounts of data at once. With good design, the lake stays clean. Without it, the lake becomes the swamp.

In this guide you will learn what Data Lake Storage Gen2 is, the words around it, and the ideas inside it. You will learn how files are organized, how access is controlled, how data is kept safe and cheap, and how to avoid the mistakes that catch most beginners. No earlier knowledge is required, and every new word is explained when it first appears.

1What Is Azure Data Lake Storage Gen2?

Azure Data Lake Storage Gen2, often shortened to ADLS Gen2, is a storage service in Azure designed to hold very large amounts of data of any kind and to let analytics tools read it quickly, with real folders and fine-grained permissions.

Start with the idea of storage

Every application needs somewhere to keep files. Cloud providers offer a simple kind of storage called object storage, where each file is stored as a separate object with a name. Object storage is cheap, huge, and very durable. But it has a weakness: it has no real folders. A name such as sales/2026/october/data.csv is just one long label. Everything is in one flat space, and the slashes are only decoration.

For small jobs this does not matter. For big data work, it matters a great deal. Analytics tools often need to rename a folder, move a folder, or delete a folder with a million files. On a flat space, each of those jobs means touching a million separate objects, one at a time. It is slow, and if it stops halfway, it leaves a mess.

What Gen2 adds

ADLS Gen2 is not a separate product with its own boxes. It is a set of extra abilities that you switch on in an ordinary Azure storage account. The key switch is called the hierarchical namespace, which turns the flat space into a true tree of folders and files. With it, renaming or deleting a folder is a single quick action. On top of this, Gen2 adds file-and-folder permissions in the style used by Linux, and an access method designed for analytics engines.

  • Scale. It holds from a few files to many petabytes, with no servers for you to manage.
  • Any data. Tables, logs, images, audio, documents, and streams all fit, in any format.
  • Real folders. A hierarchy makes organizing, renaming, and securing data natural and fast.
  • Fine-grained access. You can set permissions on individual folders and files, not just on a whole container.
  • Analytics-ready. Tools such as Spark, Synapse, Databricks, and Data Factory read it directly and in parallel.
  • Low cost. It uses the same low-priced object storage underneath, with tiers that make cold data very cheap.
Analogy

Ordinary object storage is like a giant pile of labeled boxes in one huge room. You can find a box if you know its label, but moving “everything from last year” means carrying boxes one by one. Data Lake Storage Gen2 is the same warehouse with proper aisles, shelves, and signs. Moving a whole aisle takes one decision, because the aisle itself is a real thing.

PB+
petabyte-scale capacity without any servers to run
1
switch, the hierarchical namespace, turns a flat store into a real folder tree
11
nines of durability are offered at the top redundancy choices, depending on the option
i
Remember this

ADLS Gen2 is Azure Blob Storage with the hierarchical namespace turned on and a few analytics features added. If you already know blob storage, you already know most of it. The new part is the folder tree and the permissions that go with it.

2Why Data Lake Storage Exists

To see why this storage exists, look at how companies handled data before data lakes, and what went wrong.

The old way: the data warehouse only

For decades, companies stored analytical data in a data warehouse: a database with carefully designed tables. Before data could go in, it had to be cleaned and shaped to fit. That works well for tidy business numbers. But it forces you to decide in advance what questions you will ask, and it handles messy data, such as logs, images, or sensor streams, badly. It is also expensive per terabyte.

The problem of many kinds of data

Modern companies collect data of every shape: click streams from websites, readings from machines, text from emails, pictures from cameras, files from partners. Much of it has no neat table structure. Throwing it away wastes value that may be needed later, for example to train a machine learning model on last year’s behavior.

The data lake idea

A data lake is a central store where you keep data in its original form first, and decide how to use it later. You save everything cheaply, then shape the part you need when you need it. This is sometimes called “schema on read”: the structure is applied when you read the data, not when you write it.

Why the first generation of lakes struggled

Early lakes on flat object storage had real troubles. Renaming a folder was slow and unsafe. Permissions were coarse: you could allow someone into a whole container or none of it. Analytics engines had to work around these gaps. Gen2 was created to keep the low price and huge scale of object storage while fixing these weaknesses.

Analogy

A warehouse stocks only neatly boxed products on labeled shelves, ready to sell. A lake is a big receiving yard that accepts anything, including raw crates and loose goods. You can sort and box things later, once you know what customers want. The yard is cheap and flexible, but it needs signs and rules or it turns into clutter.

What it solves in practice

A single home for analytics data

Data from many systems lands in one place, where reporting, science, and engineering teams all read the same copy.

Keeping raw history

Original data is stored untouched, so when rules change you can reprocess from the source instead of begging the source system again.

Machine learning and data science

Large training sets, including images and text, sit next to the compute that uses them.

Cheap long-term storage

Old data moves to cooler tiers automatically, so you can keep years of history at a low price.

When it is not the right tool

A data lake is not a database. It does not offer fast single-row lookups, transactions across many records, or indexes by itself. It holds files. Tools on top of it, or databases beside it, add those abilities. If your need is a fast application database, use one, and use the lake for the analytical copy.

A lake is cheap to fill and expensive to clean. Design it before you pour.

3Core Concepts and Vocabulary

Data Lake Storage Gen2 has a small vocabulary. Learn these words once, and the documentation will read easily.

The account

Storage account

The top-level Azure resource that holds your data. It has a name, a region, a redundancy choice, and settings such as the hierarchical namespace.

The tree

Hierarchical namespace

The setting that turns flat object storage into a real tree of directories and files.

The top folder

Container

A top-level grouping inside the account. In Gen2 it works like a file system, the root of a tree. Also called a file system.

A folder

Directory

A real folder inside a container, which can hold files and other directories, and can be renamed or deleted in one step.

A file

Blob or file

The actual data item. In the blob view it is called a blob, and in the file system view it is called a file. It is the same thing.

Door

Endpoint

The web address used to reach the account. Gen2 has a dedicated address for file system operations and another for blob operations.

Driver

ABFS driver

The Azure Blob File System driver, the connector that analytics tools use to read and write the lake efficiently.

Rules

ACL

Access control list. A list of who may read, write, or enter a directory or file, in the style used by Linux.

Identity

Microsoft Entra ID

The sign-in system for people and applications. It is the recommended way to authenticate to the lake.

Roles

RBAC

Role-based access control. Azure roles that grant broad rights, such as read all data in a container.

Temporary pass

Shared access signature

A special link that grants limited access for a limited time, without handing over the account key.

Master key

Account key

A powerful secret that gives full access to everything in the account. Best avoided.

Price tier

Access tier

Hot, cool, cold, and archive tiers trade storage price against access price and speed.

Copies

Redundancy

How many copies Azure keeps and where, such as within a zone, across zones, or across regions.

Automation

Lifecycle management

Rules that move or delete data automatically as it ages.

Table format

Delta, Parquet

File formats that make data compact and fast to query. Delta adds table-like safety on top of Parquet files.

Two ways to see the same data

One of the neat features of Gen2 is that the same data can be reached in two ways. Through the blob endpoint, it looks like blob storage, and tools built for blobs work. Through the dfs endpoint, it looks like a file system with directories, and tools built for analytics work. You do not copy the data between them. It is one set of files with two doors.

Analogy

Think of a library with a front entrance for visitors who want to borrow single books and a loading dock for delivery trucks that move whole shelves. The books inside are the same. Only the door and the way of working differ.

Naming matters

Storage account names must be unique across Azure, use only lowercase letters and numbers, and stay within a short length limit. Choose them with care, because the name becomes part of every address, and you cannot rename the account later. A clear pattern, including the environment and purpose, saves confusion.

4Architecture and Components

A data lake is not only storage. Around the storage sit the tools that fill it, shape it, read it, and protect it.

flowchart LR
    subgraph IN["Data sources"]
        A1["Databases"]
        A2["Applications and logs"]
        A3["Devices and streams"]
        A4["Partner files"]
    end
    subgraph ING["Ingestion tools"]
        B1["Data Factory pipelines"]
        B2["Event streaming services"]
        B3["Direct upload tools"]
    end
    subgraph LAKE["Data Lake Storage Gen2 account"]
        C1["Container: raw zone"]
        C2["Container: cleaned zone"]
        C3["Container: curated zone"]
    end
    subgraph USE["Consumers"]
        D1["Spark and Databricks"]
        D2["Synapse and SQL engines"]
        D3["Machine learning"]
        D4["Reports and dashboards"]
    end
    subgraph GOV["Control and care"]
        E1["Entra ID, RBAC, and ACLs"]
        E2["Network rules and private endpoints"]
        E3["Monitoring and lifecycle rules"]
    end
    A1 --> B1
    A2 --> B3
    A3 --> B2
    A4 --> B1
    B1 --> C1
    B2 --> C1
    B3 --> C1
    C1 --> C2
    C2 --> C3
    C2 --> D1
    C3 --> D2
    C3 --> D3
    C3 --> D4
    E1 -.-> LAKE
    E2 -.-> LAKE
    E3 -.-> LAKE
    
Figure 1: A typical data lake with sources, ingestion, storage zones, consumers, and governance

Read the diagram from left to right. Data starts in sources such as databases, applications, devices, and partner files. Ingestion tools bring it into the lake, where it first lands in a raw zone. Further steps clean it into a second zone and shape it into a curated zone ready for use. Consumers such as analytics engines, machine learning tools, and reports read from the zones that suit them. Along the bottom, the dotted lines show the controls that surround the whole lake: identity and permissions, network rules, monitoring, and lifecycle rules.

The storage layer

At the core is the storage account with the hierarchical namespace switched on. Inside it are containers, and inside those are directories and files. Azure keeps multiple copies according to your redundancy choice, and charges by the amount stored and by the operations performed.

The ingestion layer

Tools such as Azure Data Factory, event streaming services, and command line utilities push data into the lake. Some copy in batches on a schedule. Others write continuously as events arrive. Chapter 8 covers these routes.

The processing layer

Engines such as Spark, Synapse, and Databricks read files from the lake, transform them, and write results back. They run on their own compute, separate from storage. This separation of storage and compute is a defining feature: you can switch off the compute and keep the data, and you can run many different engines on the same data at the same time.

The consumption layer

Reports, dashboards, and models read the curated data. Often a SQL engine sits in front, letting analysts query the files with familiar commands.

The governance layer

Identity, permissions, network rules, encryption, auditing, and lifecycle rules protect and tidy the lake. They are not extras. In a lake that holds data from the whole business, they are as important as the storage itself.

Analogy

Picture a port. Ships and trucks arrive at the docks, which are the ingestion tools. Containers are unloaded into a yard, which is the lake. Cranes and factories nearby, the processing engines, work on the goods. Trucks leave for shops, the consumers. The harbor master, the customs office, and the guards, the governance layer, control who comes and goes.

i
Storage and compute are separate

This is the biggest design benefit. Data stays in the lake all the time. Compute is rented only while it works. You never pay for an idle engine just to keep your data safe.

5The Hierarchical Namespace

This single setting is what turns an ordinary storage account into a Data Lake Storage Gen2 account. It is worth understanding deeply, because it explains most of Gen2’s advantages.

Flat versus hierarchical

In a flat namespace, the store keeps a list of object names. A name such as logs/2026/10/30/app.log is a single string. The slashes mean nothing to the store. If you ask to rename the “folder” logs/2026/10, the store must find every object whose name starts with that text, copy each to a new name, and delete the old one. With a million objects, that is a million copies, and failure partway leaves some renamed and some not.

In a hierarchical namespace, folders are real objects in a tree. Renaming a directory changes one entry in the tree, and everything beneath it comes along. The change is quick, and it happens as a single, all-or-nothing action. This property is called atomic: it either fully happens or does not happen at all.

Analogy

In a flat store, renaming a folder is like walking through a warehouse and rewriting the label on every single box. In a hierarchical store, it is like changing the sign on the aisle. Everything inside is now under the new sign, with nothing to carry.

What the hierarchy gives you

AbilityFlat namespaceHierarchical namespace
Rename a directoryCopy and delete each object; slow and not atomicOne quick, atomic operation
Delete a directoryDelete each object one by oneOne quick, atomic operation
Permissions on a folderNot available; only at container levelAvailable through ACLs on each directory and file
Analytics job commitRelies on slow copy-and-delete tricksUses fast renames, which speeds up job completion
Empty directoriesNot really possibleSupported as real objects
Price per operationStandard blob ratesSome operations are priced differently; check the current rates

Why analytics tools love it

Big data engines write results into a temporary folder and then rename it to the final name, so that readers never see a half-finished result. On a flat store, that rename is a slow copy. On Gen2, it is nearly instant. Jobs finish sooner and fail less often at the very last step.

Turning it on

The hierarchical namespace is chosen when you create the storage account. Microsoft has also offered a way to upgrade an existing blob account, with conditions and a period in which the account is restricted, and with some features that do not work together with the hierarchical namespace. The details, including the list of unsupported features, have changed over time, so check current documentation before you plan. Test with a copy of your data and workloads first.

Features that behave differently

  • Some blob features are not available, or are limited, on accounts with the hierarchical namespace. Examples that have been listed as limited in the past include certain versioning and snapshot features. Confirm the current list.
  • Some network file protocols and SFTP access are available on these accounts with specific requirements and extra charges. Check current availability.
  • Tools written only for flat blob storage may treat directories oddly. Test them before relying on them.
!
Decide early

If you will use the account for analytics, turn the hierarchical namespace on from the start. Switching later is possible in some cases, but it is a project with testing and a restricted period. Starting right costs nothing.

6Designing the Lake: Zones and Folder Structure

A lake without a plan becomes a swamp. The most valuable work you will do is deciding, before the first file lands, how data will be organized.

The zone idea

Most well-run lakes divide data into zones that reflect how refined it is. A popular naming is the medallion pattern, with three levels:

Bronze

Raw zone

Data exactly as it arrived, never edited. This is your safety net: from here you can always rebuild everything else.

Silver

Cleaned zone

Data with errors fixed, duplicates removed, types corrected, and formats made consistent. Good for most analysts and engineers.

Gold

Curated zone

Business-ready data shaped for particular uses, such as sales summaries, customer views, or training sets.

Other names exist, such as raw, enriched, and workspace, or landing, standardized, and curated. The names matter less than agreeing on them. Many lakes also keep a sandbox area where individuals can experiment without affecting shared data, and a landing area where outside partners drop files before checks are made.

Analogy

Think of a restaurant’s supply chain. Bronze is the delivery dock, with crates exactly as they arrived. Silver is the prep kitchen, where ingredients are washed and chopped. Gold is the finished plate, ready for the customer. Mixing them up leads to unwashed food on the guest’s table.

Containers or folders for zones?

You can make each zone its own container, or each zone a top-level folder within one container. Separate containers make it simpler to set different permissions and to apply lifecycle rules by zone. Folders are simpler to manage when the number of zones is small. Many teams use one container per zone for the main layers.

Designing folder paths

A good folder path tells you what a file is without opening it. A common pattern uses the subject first, then the source, then the date:

  • Zone (as a container or top folder), such as raw or curated.
  • Business area or subject, such as sales or finance.
  • Source system or data set, such as orders or customers.
  • Date parts, such as year, month, and day, so that tools can read just the days they need.

Putting the date at the end, in year, month, day order, keeps related files together and makes it easy to read one day or one month. It also lets lifecycle rules and permissions work on natural boundaries.

Rules for good paths

DoAvoid
Use lowercase letters, digits, and hyphens or underscoresSpaces, mixed case, and special characters that tools treat badly
Put stable, wide categories first and the date lastPutting the date first, which scatters related data
Keep the path shallow enough to read, yet deep enough to organizeDozens of levels, or one folder with millions of files
Include the source and data set in the pathGeneric names such as “data” or “misc”
Agree names in a short written standardEvery team inventing its own pattern
Align paths with who needs accessMixing sensitive and open data in one folder

Think about security when drawing folders

Permissions work most easily on folder boundaries. If the HR data lives in one folder tree and the sales data in another, access can be granted by folder. If they are mixed, you must set permissions file by file. Draw your folders so that each tree has one audience.

!
The swamp warning

The most common failure of data lakes is not technical. It is that nobody knows what is in them, who owns each folder, or which data is correct. Write down a folder standard, give every top-level folder an owner, and keep a catalog of what is where.

7Accessing the Lake: Endpoints, Drivers, and Tools

Data in the lake is useful only if tools can reach it. This chapter shows the doors into the lake and what happens when a request arrives.

sequenceDiagram
    participant C as Client or Analytics Tool
    participant E as Microsoft Entra ID
    participant S as Storage Service
    participant N as Hierarchical Namespace
    participant D as Data Files
    C->>E: Ask for a token for the storage service
    E-->>C: Return a signed token
    C->>S: Request to read a file with the token attached
    S->>S: Check network rules and the token
    S->>S: Check Azure role assignments
    S->>N: Check the access control lists along the path
    N-->>S: Permission granted or denied
    S->>D: Read the file contents
    D-->>S: Return the data
    S-->>C: Send the data back
    
Figure 2: What happens when a tool reads a file from the lake

The sequence follows one read request. The client first obtains a token from Microsoft Entra ID, proving who it is. It sends the request with the token. The storage service checks the network rules and the token, then checks role assignments, then checks the access control lists on the folders along the path. If everything allows it, the data is read and returned. Any check can stop the request.

The two endpoints

EndpointStyleUsed by
dfs endpointFile system with real directoriesAnalytics engines, the ABFS driver, and Gen2-aware tools
blob endpointBlob storage interfaceTools and applications built for blob storage

The same account name appears in both addresses, followed by a different part. Which one a tool uses is usually chosen for you, but it matters for network rules: if you lock down the account with private endpoints, you may need to create a private endpoint for each of the two doors you use.

The ABFS driver

Analytics engines use a connector called the Azure Blob File System driver. It speaks to the dfs endpoint, understands directories, and is built for big parallel reads and writes. Paths for it begin with a short scheme name and include the container and the account, followed by the folder path. You will see these addresses in notebooks and pipeline settings. The secure version of the scheme uses encrypted connections and should be your default.

Tools people use

Visual

Storage Explorer and the portal

Browse folders, upload and download files, and set permissions by clicking.

Command

Command line tools

Scripts and utilities for bulk copies, synchronization, and automation.

Code

Software development kits

Libraries for common languages to read, write, and manage files from applications.

Analytics

Spark, Databricks, Synapse

Read and write whole datasets in parallel using the ABFS driver.

Pipelines

Data Factory and Synapse pipelines

Schedule and orchestrate copies and transformations.

Query

SQL engines over files

Let analysts query files with SQL without moving the data.

Analogy

A museum has a public entrance for visitors with tickets and a service entrance for staff with trolleys. Visitors and staff both prove who they are, and both are checked against lists of who may enter which room. The dfs endpoint is the service entrance, built for heavy loads. The blob endpoint is the public entrance, built for ordinary visits.

Mounting and drives

Some platforms let you mount a lake folder so that it appears as a normal drive or folder in a notebook or virtual machine. This is convenient for exploration, but it hides the access rules behind a shared identity, so use it with care. Prefer direct access using each user’s own identity where you can.

i
Use identity, not keys

Wherever possible, connect with Entra ID identities, including managed identities for services. This lets the lake’s permissions apply to each person or service individually and removes the need to store secrets.

8Getting Data In: Ingestion Patterns

A lake is only as useful as the data inside it. There are several routes for data to arrive, and each suits a different kind of source.

Batch loads

In a batch load, data is moved in chunks at set times, such as every night. Azure Data Factory or Synapse pipelines are the common tools. They read from databases, files, and applications, and write to the lake, often converting formats on the way. Batch is simple, predictable, and good for data that does not need to be fresh to the second.

Streaming loads

In a streaming load, data arrives continuously as events happen, such as clicks, sensor readings, or transactions. Event streaming services collect them, and a capture feature or a processing job writes them to the lake in small files, often grouped by time. Streaming gives fresher data but needs more care with file sizes and ordering.

File drops

Partners often send files. They may use a secure file transfer, a web upload, or a shared link. A common design is a separate landing area in the lake, with narrow permissions, where outside files arrive. A pipeline then checks them, for size, format, and safety, and moves good ones into the raw zone.

Bulk migration

When moving existing data into the lake for the first time, large copies can take days. Command line copy tools, high-speed pipelines, and offline transfer devices can all help. Plan for restarts, checks of file counts and sizes, and the bandwidth you will use.

PatternTypical toolFreshnessWatch out for
Scheduled batchData Factory pipelinesHours to a dayLate sources, and loads that must be safe to rerun
Micro-batchFrequent pipelines or Spark jobsMinutesMany small files and extra cost
Streaming captureEvent services writing to the lakeSeconds to minutesTiny files and out-of-order events
Partner file dropSecure upload to a landing areaWhen files arriveUnchecked files and unexpected formats
One-time migrationCopy utilities or offline devicesOnceBandwidth, restarts, and verification
Analogy

Batch is a delivery truck that arrives each night with a full load. Streaming is a conveyor belt that brings items one by one all day. A file drop is a parcel locker where a courier leaves a package for you to check before taking it in. A migration is moving house: one huge, careful, one-time job.

The small files problem

Analytics engines are efficient at reading a few large files, and slow at reading millions of tiny ones. Each file adds overhead, and each request costs a small fee. Streaming and frequent loads tend to create tiny files. The fix is to compact them: periodically merge small files into larger ones, aiming for sizes in the range of hundreds of megabytes to a gigabyte, depending on the engine and the format. Plan compaction from the start.

Keep the raw data raw

Write incoming data to the raw zone exactly as it arrived, adding only the folder structure and perhaps a record of when it arrived. Do not clean or reshape it there. If a later step is wrong, you can reprocess from the untouched originals.

!
Make loads safe to repeat

Loads fail and are rerun. Design them so that running twice does not create duplicates, for example by writing each load into its own dated folder and replacing that folder whole.

9Durability and Redundancy

Data you cannot lose must be kept in more than one place. Redundancy options decide how many copies Azure keeps, and how far apart they are.

Why copies matter

Hardware fails. Disks break, racks lose power, buildings flood. Azure protects your data by keeping several copies, so a single failure never destroys it. You choose how many copies and how widely they are spread. More spread means more protection and a higher price.

The redundancy choices

OptionWhat it doesProtects againstCost level
Locally redundant (LRS)Keeps three copies inside one data centerDisk and rack failuresLowest
Zone redundant (ZRS)Keeps copies in three separate zones of one regionThe loss of one whole data center in the regionMiddle
Geo redundant (GRS)Three local copies plus an asynchronous copy in a paired region far awayThe loss of an entire regionHigher
Geo-zone redundant (GZRS)Zone redundant in the main region, plus a copy in the paired regionZone loss and region loss togetherHighest
Read access variants (RA-GRS, RA-GZRS)Same as above, but the secondary copy can be readSame, plus reads can continue from the secondary when the primary is downSame as base option, with a small read premium
Analogy

Think of keeping copies of an important document. One copy in your drawer protects against losing a page. Copies in three offices in the same city protect against a fire in one building. A copy in another country protects against a regional disaster. Each extra step costs more and takes more care.

How the geo copy works

The copy in the second region is made asynchronously, which means a short time after the write, not at the same moment. If the main region is lost suddenly, the very latest writes may not have reached the second region yet. The gap is usually small, but it is not zero. This is called the recovery point. If your business cannot lose any data, plan for it explicitly.

Failover

With geo redundancy, you can start a failover to make the secondary region the new main one. Failover has consequences: some recent data may be lost, the account becomes locally redundant in the new region until it is changed back, and some features may have limits on accounts with the hierarchical namespace. Treat failover as a decision for serious outages, rehearse it, and check the current conditions in Microsoft’s documentation.

Choosing a level

  • Re-creatable data, such as a working copy of data that can be rebuilt, may be fine with local redundancy.
  • Important production data usually deserves zone redundancy as a minimum, so a data center failure does not stop the lake.
  • Business-critical or regulated data often needs geo or geo-zone redundancy, and a documented recovery plan.
  • Data residency rules may limit which regions can hold copies. Check the paired region for your chosen one.
!
Redundancy is not backup

Copies protect against hardware and site failures. They do not protect against a person deleting the wrong folder, because the delete is copied too. Add soft delete, careful permissions, and a backup or copy strategy for accidental or malicious deletion.

10Access Tiers and Lifecycle Management

Not all data is used equally. Last week’s data is read daily; data from five years ago may be read once a year. Tiers let you pay less for data you touch rarely.

The tiers

TierStorage priceAccess priceBest for
HotHighestLowestData used often, such as the latest days and active working sets
CoolLowerHigherData used rarely, kept for at least a month or so
ColdLower stillHigher stillData used very rarely, kept for a few months or more
ArchiveLowestHighest, and data is offlineData kept for compliance or history, needed almost never

Cooler tiers have minimum storage periods. If you delete or move data sooner, you pay an early deletion charge. Archive data is offline: before you can read it, you must rehydrate it, which means moving it back to a hotter tier, and this can take hours. The exact minimum periods, prices, and support on accounts with the hierarchical namespace should be checked in current documentation.

Analogy

Think of an office. Papers you use daily are on your desk. Those you need monthly are in a cabinet nearby. Old records are in a basement archive, and the very oldest are in a distant warehouse that needs a day’s notice to fetch from. The desk is expensive space, the warehouse is cheap, and retrieval costs more the further you go.

Setting the tier

The account has a default access tier, usually hot or cool, which applies to new data. You can also set the tier on individual files. Moving a file between tiers is a small operation, but with many files it adds up in cost, so automate it.

Lifecycle management rules

A lifecycle management policy is a set of rules that Azure applies automatically. Each rule selects data by folder prefix, file type, or tags, and says what to do as the data ages. Typical actions include:

  • Move to cool after thirty days without being changed.
  • Move to cold or archive after ninety days or a year.
  • Delete after the required retention period, such as seven years.
  • Delete old temporary or staging files after a week.

Match rules to zones

1

Raw zone

Often kept for a long time, because it is the source of truth. Move to cool and then archive as it ages, if reprocessing is rare.

2

Cleaned zone

Keep recent months hot, because many jobs read them. Move older data to cool.

3

Curated zone

Keep hot while it feeds reports. Old versions can move down or be deleted.

4

Temporary areas

Delete after a short time, so scratch data does not pile up.

i
Folder design makes rules easy

Lifecycle rules select data by path prefix. A folder structure with the date in the path, and a clear zone at the top, lets you write simple rules. Messy folders lead to messy rules, or no rules at all.

Watch for hidden costs

Do not move small files to cool or archive without thinking. Each move is a charged operation, and small files may cost more to move than they save. Cooler tiers also charge more to read, so moving data that jobs still read often can raise the bill instead of lowering it.

11The Life of Data in the Lake

Data does not just sit in a lake. It arrives, is refined, is used, ages, and eventually leaves. Planning each stage keeps the lake healthy.

flowchart TD
    A["Source data is created"] --> B["Ingested into the raw zone"]
    B --> C["Validated and cleaned into the cleaned zone"]
    C --> D["Shaped into the curated zone"]
    D --> E["Read by reports, models, and analysts"]
    E --> F["Data ages and is read less often"]
    F --> G["Lifecycle rule moves it to a cooler tier"]
    G --> H["Retention period ends"]
    H --> I["Data is deleted or archived under policy"]
    B --> J["Raw copy kept for reprocessing"]
    J --> C
    
Figure 3: The life of data in a lake, from creation to deletion

The diagram shows the main path from top to bottom. Data is created at the source, lands raw, is cleaned and shaped, and is used. As it ages, it is read less, moves to cooler tiers, and finally leaves the lake when its retention period ends. A side loop shows the raw copy, which is kept so that cleaning can be redone whenever rules change.

Stage one: arrival

Data lands in the raw zone as received. Record where it came from, when it arrived, and how many records it holds. These small notes make later problems far easier to trace.

Stage two: cleaning

Pipelines check structure, remove duplicates, fix types, and set aside bad records in a separate folder for review. Keep a log of what was changed, so analysts can trust the cleaned data and explain it.

Stage three: shaping

Cleaned data is combined and reshaped for particular uses, such as sales summaries or customer profiles. These are the datasets people actually read, so they deserve names, owners, descriptions, and quality checks.

Stage four: use

Reports, dashboards, and models read the curated data. Usage tells you which data is valuable, and which can be retired.

Stage five: aging

Over time, data is read less often. Lifecycle rules shift it to cheaper tiers. Old versions of curated tables can be trimmed.

Stage six: retention and deletion

Every dataset should have a retention period, driven by law, contracts, and business need. When it ends, delete the data or move it to a long-term archive. Keeping data forever has a cost, and for personal data, it can also be a legal risk. Rules about erasure requests also apply, and designing for them early is far easier than adding them later.

Analogy

Data in a lake is like food in a restaurant. It arrives fresh from suppliers, is prepared, served, and eventually moves to storage or the bin when it is too old. A good restaurant tracks dates and rotates stock. A bad one finds a forgotten crate at the back of the freezer.

i
Give every dataset an owner

An owner decides who may access the data, how long to keep it, and when to retire it. Without owners, decisions are never made and the lake only grows.

12File Formats and Partitioning

How you store data inside files makes a huge difference to speed and cost. The right format and layout can make queries ten times faster and storage several times smaller.

Row formats and column formats

Some formats store data row by row, like a list of records. Others store it column by column. Analytics usually asks questions about a few columns across many rows, such as “total sales by region”. A column format lets the engine read only the columns it needs and skip the rest, which saves huge amounts of reading.

FormatLayoutStrengthsLimits
CSVText, row by rowSimple, readable, understood everywhereLarge, slow, and loose about types and special characters
JSONText, nested recordsFlexible for nested and changing structuresLarge and slow to scan
AvroBinary, row by row, with schemaGood for streams and for schemas that changeLess efficient for column-based analytics
ParquetBinary, column by column, compressedCompact and fast for analytics, widely supportedNot human-readable; updates mean rewriting files
ORCBinary, column by columnEfficient for some enginesLess universal than Parquet
DeltaParquet files plus a transaction logSafe updates, deletes, history, and consistent readsNeeds tools that understand it
Analogy

Imagine a phone directory. A row format is the usual book: each entry lists name, address, and number together. If you only want phone numbers, you must flip through everything. A column format is like having three separate booklets: names, addresses, and numbers. To read only the numbers, you pick up one booklet. For counting and summing, that is much faster.

Why Delta and similar table formats matter

Plain files are hard to update safely. If two jobs write at the same time, or a job fails halfway, readers can see half-finished data. Table formats such as Delta keep a log of changes and make each write all-or-nothing. They add features that databases take for granted: updates, deletes, merges, time travel to earlier versions, and consistent reads. Many modern lakes keep their cleaned and curated zones in such a format.

Partitioning

Partitioning means splitting a dataset into folders by the value of one or two columns, usually the date. When a query asks for one month, the engine reads only the folders for that month and skips the rest. This can cut reading from terabytes to gigabytes.

  • Choose columns that queries filter on, most often date.
  • Avoid too many partitions. Partitioning by a column with millions of values creates millions of tiny folders and files.
  • Keep partitions big enough. A partition should hold files of a healthy size, not a few kilobytes.
  • Do not partition small tables. The overhead is not worth it.

File size

Aim for files that are large enough to read efficiently and small enough to process in parallel. A common guideline is somewhere between a hundred megabytes and a gigabyte per file, though the best size depends on the engine. Both thousands of tiny files and a few gigantic ones cause trouble.

Compression

Compressing files saves storage and reading time at the cost of a little processing. Modern column formats compress internally by default. For text formats, compression is worth enabling, with a type that the reading tools can split for parallel work.

i
A simple rule

Land raw data in whatever form it arrives. Convert to a column format such as Parquet or Delta from the cleaned zone onwards. This one habit usually gives the largest single improvement in cost and speed.

13Security Part One: Authentication and Roles

A data lake collects data from the whole business, so it becomes a very attractive target. Security starts with knowing who is asking, and what they are allowed to do.

Four ways to prove who you are

MethodHow it worksOpinion
Microsoft Entra IDPeople and applications sign in with identities and receive tokensBest; supports roles, ACLs, auditing, and conditional access
Managed identityAzure services get their own identity to sign in with, with no secret to storeBest for services such as pipelines and virtual machines
Shared access signatureA time-limited link with set permissionsAcceptable for sharing outside the organization for a short time
Account keyA master secret that unlocks everything in the accountAvoid; consider disabling it completely
Analogy

An Entra identity is a personal staff badge with your photo and your own access rights. A managed identity is a badge issued to a machine. A shared access link is a visitor pass that expires. An account key is a master key that opens every door and does not say who used it. You would not hand out master keys in a real building.

Why the account key is dangerous

An account key gives full access to the entire account and bypasses roles and ACLs. Anyone holding it can read, change, or delete everything, and the logs cannot tell who they were. It is also hard to rotate, because many tools may depend on it. Mature setups disable key-based access so that only Entra identities work. Do this carefully, checking that no tool still depends on keys.

Azure roles for the data

Role-based access control gives broad permissions at the level of the account, a container, or higher. The roles most used with data lakes are:

Read

Storage Blob Data Reader

Can read and list data, but cannot change anything.

Write

Storage Blob Data Contributor

Can read, write, and delete data, but cannot change permissions.

Full

Storage Blob Data Owner

Has full control of data, including managing permissions. Acts as a super user on the hierarchical namespace.

Management

Management roles

Roles such as Owner, Contributor, and Storage Account Contributor manage the account itself, not the data inside it. Reading data needs a data role.

A key point about management and data

Azure separates the management plane, which creates and configures accounts, from the data plane, which reads and writes files. A person who is Owner of the account can change its settings, but does not automatically get permission to read the files unless they also hold a data role or use the account key. This separation is helpful: platform administrators can run the account without seeing the data.

Assigning roles sensibly

  • Use groups, not individuals, so access follows team membership.
  • Assign at the narrowest scope that works: a container rather than the whole account when possible.
  • Prefer reader roles for most analysts, and give write roles only to pipelines and engineers.
  • Review regularly, and remove access when people change roles or leave.
  • Use conditional access and strong sign-in for people with broad rights.
!
Role order of evaluation

When a request arrives, Azure checks role assignments first. If a role already grants the action, access is allowed and ACLs are not even looked at. A broad role at the account level can therefore override careful folder permissions. Keep broad roles to a minimum if you rely on ACLs.

14Security Part Two: ACLs and Folder Permissions

Roles are broad. Access control lists let you be precise: this team may read this folder, that team may write that one, and nobody else may see either.

What an ACL is

An access control list is a list of entries attached to a directory or file. Each entry names an identity, which can be a user, a group, or a service, and gives it some combination of three rights: read, write, and execute. This follows the permission model long used on Linux and other Unix systems.

RightOn a fileOn a directory
ReadRead the contentsList what is inside
WriteChange the contentsCreate, rename, or delete items inside (together with execute)
ExecuteNot used for ordinary data filesEnter the directory and reach what is below it
Analogy

Think of rooms in a building. To read a document in a room, you need permission to walk down the corridor, which is the execute right on each directory along the way, and permission to open the document, which is the read right on the file. If any corridor door is locked, you never reach the room, even if the document itself is open.

Walking the path

To reach a file deep in a tree, a person needs the execute right on every directory above it, starting at the container root. This surprises beginners: granting read on a leaf folder is not enough if the parent folders refuse entry. Always check the whole path.

Access ACLs and default ACLs

  • Access ACLs control access to the item they are attached to.
  • Default ACLs are set on a directory and act as a template. New files and subdirectories created below it inherit them. They do not change items that already exist.

This second point causes a lot of trouble. If you add a default ACL to a folder that already has a million files, those files do not get it. You must apply the change recursively to existing items. Tools can do this in bulk, but it takes time on large trees. Set default ACLs when you create the folder, before data arrives.

Use groups, not individuals

ACLs have a limit on the number of entries per item, so listing individual users does not scale. Grant rights to Entra groups instead, and manage membership in the group. Then one ACL entry covers a whole team, and people moving between teams change group membership, not folder permissions.

Typical permission design

1

Create groups by role and area

For example, sales readers, sales writers, and finance readers.

2

Give pipelines write rights where they load

Raw and cleaned zones are written only by pipeline identities, not by people.

3

Give readers execute on parent folders and read on data folders

Set both access and default entries so new data inherits the right rules.

4

Keep sensitive trees apart

Place data of different sensitivity in separate directory trees so each has its own small audience.

5

Review and test

Check as a real user that they can reach what they should and nothing more.

Roles and ACLs together

A common approach is to give broad roles only to administrators and pipelines, and use ACLs on groups for everyone else. Because roles are checked first and can override ACLs, avoid giving ordinary users a data role at the account level when you want ACLs to control them.

i
Write it down

Keep a simple table of which group has which rights on which folder. ACLs are hard to read in a portal when there are hundreds of folders, and the table becomes your map when someone asks “who can see this?”.

15Security Part Three: Networks and Encryption

Even with good identities and permissions, it is wise to limit where requests may come from, and to protect data against anyone who gets at the storage itself.

Network controls

By default, a storage account is reachable over the public internet by anyone who can authenticate. You can narrow this in layers:

ControlWhat it doesGood for
Firewall with allowed address rangesAccepts requests only from listed public addressesSimple limits for known offices or services
Virtual network rules with service endpointsAccepts requests only from chosen subnetsModerate protection with little effort
Private endpointsGives the account a private address inside your network and allows turning off public accessStrongest protection and hybrid access over private links
Disable public network accessBlocks all public internet requestsHighly sensitive data, together with private endpoints
Trusted service exceptionsLets certain Azure services reach the account even when the firewall is onLetting chosen platform services through with care
Analogy

A firewall rule is a guard checking each visitor’s address on a list. A private endpoint is a private corridor from your own office building straight into the vault, with the street door bricked up. The more sensitive the vault, the more you want the bricked-up door.

Private endpoints and the two doors

For a Gen2 account, you may need a private endpoint for the dfs endpoint, which analytics tools use, and another for the blob endpoint, which some tools still use. Create the ones your tools need. You also need private DNS set up so that the account name resolves to the private address from inside your network. A missing DNS zone is the most common reason a private endpoint appears not to work.

Encryption at rest

All data in a storage account is encrypted at rest automatically, using strong encryption and keys managed by Microsoft. If your rules require control of the keys, you can use customer-managed keys stored in Azure Key Vault. This gives you the power to rotate or revoke the key, at the price of extra responsibility: if the key is lost or access to it is removed, the data becomes unreadable. Some organizations also use an extra layer of encryption at the infrastructure level.

Encryption in transit

Require secure transfer so that all connections use encrypted channels, and set a minimum version of the transport security protocol. Modern tools support this by default. Disable old, weak settings.

Protection against deletion and change

  • Soft delete keeps deleted data for a set number of days so that it can be restored.
  • Immutable storage makes data write-once and unchangeable for a time, for regulatory records.
  • Resource locks stop someone from deleting the whole account by accident.
  • Backups and copies to another account or region protect against serious mistakes or attacks. Check which of these features work on accounts with the hierarchical namespace, since support has varied.

Auditing and threat detection

Turn on logging of read, write, and delete requests, and send the logs to a central workspace. Microsoft also offers threat protection for storage that can warn about unusual access, such as a flood of reads from a strange location. Alerts only help if someone responds, so connect them to a person or a process.

!
Public access is the classic leak

Many data breaches in the cloud come from storage left open to the public by mistake. Disable anonymous access at the account level, review network settings often, and use policy to prevent open accounts from being created.

16Monitoring, Logging, and Governance

A lake that nobody watches will grow, drift, and sometimes leak. Monitoring shows health and cost. Governance shows what you have and whether it follows the rules.

What to monitor

SignalWhy it matters
Used capacityShows growth and helps forecast cost
Transactions and their typesCost depends on operations, and spikes can show runaway jobs
Latency of requestsSlow responses can mean overload or throttling
Failed requests and error codesPermission problems, throttling, and network trouble show here
Throttling responsesSignals that you are exceeding the account’s request or bandwidth limits
Egress (data leaving)Unexpected large downloads can be both a cost and a security signal
Authentication method usedReveals use of account keys that should have been retired
Changes to settings and permissionsUnplanned changes are a common cause of leaks and outages
Analogy

A warehouse manager reads the stock counts, the delivery log, the door-access records, and the electricity bill. Any strange number is a reason to walk the aisles. Storage metrics and logs are the same set of readings for your lake.

Tools

Numbers

Azure Monitor metrics

Capacity, transactions, latency, and availability, with charts and alerts.

Records

Resource logs

Detailed records of requests, sent to a Log Analytics workspace or storage, showing who did what and when.

Counts

Storage insights

Ready-made views of usage and health across accounts.

Inventory

Blob inventory

A scheduled report listing files and their properties, useful for finding old, large, or untiered data.

Events

Event notifications

Messages sent when files are created or deleted, used to trigger pipelines.

Catalog

Data governance catalog

A service such as Microsoft Purview that scans the lake and records what datasets exist, their sensitivity, and their lineage.

Alerts worth setting

  • Sudden growth in used capacity or transactions.
  • High rates of throttled or failed requests.
  • Large downloads or egress at unusual times.
  • Any use of the account key, if keys should be off.
  • Changes to firewall rules, public access, or role assignments.

Governance basics

Governance means knowing what data you hold, who owns it, how sensitive it is, and where it came from. A catalog scans folders and records datasets, with labels for sensitive content such as personal information. Lineage shows how one dataset was built from others, which is vital when a source is wrong and you must find everything it affected. Azure Policy can enforce rules, such as requiring private endpoints, encryption settings, or tags on every account.

i
Tag everything

Tag accounts and, where useful, containers with owner, cost center, data sensitivity, and environment. Tags make cost reports, policies, and reviews far easier.

17Cost and Optimization

Storing data is cheap per gigabyte, but a large lake has many meters. Understanding them helps you keep the bill steady as the lake grows.

Where the money goes

Cost itemHow it is chargedHow to reduce it
CapacityPer gigabyte per month, by tier and redundancyUse lifecycle rules, compress, convert to column formats, delete what is not needed
OperationsPer number of read, write, list, and other requests, priced by type and tierUse larger files, avoid listing huge folders repeatedly, avoid tiny writes
Data retrievalPer gigabyte read from cool, cold, and archive tiersKeep frequently read data in hot; do not tier data that jobs still read
Early deletionA charge when data is removed or moved before the minimum period of a cooler tierMatch tiering rules to real retention
Geo replicationExtra capacity cost plus data transfer to the second regionUse geo options only for data that needs them
Data egressPer gigabyte leaving Azure or crossing regionsKeep compute in the same region as the lake
Private endpointsHourly and per-gigabyte chargesShare endpoints where design allows
Monitoring and logsStorage and ingestion in the workspaceFilter logs and set retention
Compute that reads the lakeCharged by the engine, not the storagePartition and compact data so queries read less
Analogy

Renting warehouse space has several charges: rent for the space, a fee each time a forklift moves a pallet, extra fees for fetching from the far basement, and delivery charges when goods leave the site. A tidy warehouse with few, large pallets, and goods in the right zones, costs far less to run than a cluttered one.

The biggest levers

1

Delete and expire

The cheapest data is data you no longer keep. Use retention rules and remove temporary and duplicate copies.

2

Use cooler tiers wisely

Automate movement for older data, but test the retrieval pattern first so savings are not eaten by access charges.

3

Choose compact formats

Parquet or Delta with compression often shrinks data several times compared with CSV or JSON.

4

Reduce operations

Merge small files, batch writes, and avoid scanning folders unnecessarily.

5

Match redundancy to value

Not all data needs geo redundancy. Use cheaper options for data that can be rebuilt.

6

Keep compute near the lake

Reading across regions costs money and time.

Reserved capacity

For large, steady amounts of data, Azure offers reserved capacity: you commit to a quantity for one or three years in return for a discount. This suits predictable lakes. It is a poor choice if you expect to shrink or move the data soon. Check current terms and rates.

Finding waste

Use the inventory report to list files by size, age, and tier. Look for large old files in hot, huge counts of tiny files, folders that nobody has read in a year, and duplicate copies of the same dataset. A quarterly cleanup often pays for itself many times.

i
Check current prices

Prices, minimum periods, and operation charges differ by region, tier, and redundancy, and they change over time. Use the Azure pricing calculator for real numbers, and treat any figure in an article as a starting point only.

18Performance and Scalability

Data Lake Storage Gen2 can serve very high throughput, but only if the data and the jobs are arranged to take advantage of it.

What limits speed

A storage account has limits on how many requests per second it can handle and how much data per second it can move. These limits are high, but they exist, and the numbers differ by region and account type. When a workload pushes beyond them, the service replies with a message asking the client to slow down and try again. This is called throttling. Well-built tools retry automatically with growing pauses, but heavy throttling makes jobs slow.

Analogy

A large warehouse has many loading bays, but only so many forklifts. If a hundred trucks arrive at once and all want the same bay, they queue. Spreading trucks across bays, and not sending them all at the same minute, keeps everything moving.

Habits that help

  • Use large files. Fewer, bigger files mean fewer requests and faster scans.
  • Read in parallel. Analytics engines split the work over many machines; give them enough files and partitions to spread the load.
  • Use column formats and partition pruning, so jobs read only what they need.
  • Co-locate compute and storage in the same region, to avoid long network trips.
  • Avoid hot spots. Many clients hammering one file or one folder at the same instant can slow down. Spread them out.
  • Avoid unnecessary listing. Listing a folder with millions of entries is slow and costly. Use partitioned paths and metadata where possible.
  • Prefer the dfs endpoint and the ABFS driver for analytics, which is built for parallel work.
  • Use premium accounts if you need very low latency and very high transaction rates; they cost more per gigabyte and fit particular workloads.

Standard and premium

QuestionStandard accountPremium block blob account
Storage priceLowerHigher
Operation priceHigher per operationLower per operation
LatencyGoodVery low and consistent
Best forMost lakes and big scansMany small, fast operations, such as interactive analytics and machine learning with heavy small-file access
Redundancy choicesWide choiceMore limited; check current options

Multiple accounts

If one account cannot meet the limits, you can spread the load across several accounts, for example by zone, by business unit, or by region. This also separates cost and permissions. The price is more to manage, so do it for a reason, not by habit.

Test before you trust

Run a realistic test with the file sizes, counts, and access patterns you expect. Measure throughput and look for throttling in the metrics. Surprises are cheaper to find in a test than on the day of a big launch.

!
The small files trap

A lake with millions of tiny files can make a job take hours when the same data in a few large files would take minutes. If your jobs slow down as the lake grows, count the files first.

19Design Patterns and Decisions

Experienced architects write down major choices as short decision notes. Here are common decisions for data lake designs, written in that style so you can see how the reasoning goes.

ADR-01Accepted
Decision

Build the lake with a hierarchical namespace, using one container per zone: raw, cleaned, and curated.

Reason

Separate containers allow different permissions, lifecycle rules, and monitoring for each level of refinement, and the namespace gives fast folder operations for analytics jobs.

Cost

A few more containers to manage, and some blob features may be limited on accounts with the hierarchical namespace.

ADR-02Accepted
Decision

Control access with Entra groups and folder ACLs, grant broad data roles only to platform administrators and pipelines, and disable account key access.

Reason

Groups scale with the organization, ACLs give folder-level precision, and removing keys means every request is tied to an identity and appears in the logs.

Cost

More design effort for permissions, and every tool must be checked to confirm it works without account keys.

ADR-03Accepted
Decision

Use private endpoints for both the dfs and blob endpoints, and disable public network access.

Reason

Policy forbids data crossing the public internet, and private endpoints give the strongest protection against accidental exposure.

Cost

Extra cost and DNS work, and any tool outside the network needs a private route or an approved gateway.

ADR-04Proposed
Decision

Store cleaned and curated data as Delta tables, and keep raw data in its original format.

Reason

Delta gives safe updates, history, and consistent reads for shared tables, while raw data stays untouched for reprocessing.

Cost

Tools must understand Delta, and files must be compacted and cleaned regularly.

Patterns that work

Pattern

Medallion zones

Raw, cleaned, and curated layers with clear rules for each.

Pattern

Landing area for outsiders

A narrow, separate place where partners drop files, checked before entering the raw zone.

Pattern

Group-based access

Entra groups mapped to roles and folder rights, with membership as the only thing that changes.

Pattern

Date-partitioned paths

Year, month, and day folders so jobs and lifecycle rules work on natural slices.

Pattern

Compaction jobs

Scheduled jobs that merge small files into healthy sizes.

Pattern

Catalog and ownership

Every dataset registered with an owner, a description, and a sensitivity label.

Anti-patterns to avoid

Avoid these

  • One flat container with everything inside
  • Sharing the account key among teams
  • Giving everyone a broad role on the whole account
  • Millions of tiny files with no compaction
  • Editing or cleaning data in the raw zone
  • Public network access left open by default

Do these instead

  • Zones, subject folders, and date partitions
  • Entra identities and managed identities
  • Narrow roles plus ACLs on groups
  • Scheduled compaction and sensible file sizes
  • Raw data kept as received
  • Private endpoints and public access disabled
A lake is a library, not a landfill. Someone has to shelve the books.

20Best Practices and Common Mistakes

This chapter gathers lessons that many teams learn the hard way. You can learn them the easy way, by reading them first.

Best practices

  • Enable the hierarchical namespace at creation for any analytics account.
  • Write a folder standard before loading data, with zones, subjects, and date partitions.
  • Keep raw data raw, and rebuild other zones from it when rules change.
  • Use Entra identities, managed identities for services, and disable account key access when possible.
  • Grant access through groups, with roles at the narrowest scope and ACLs for folder detail.
  • Set default ACLs before data arrives, and remember that they do not change existing items.
  • Use private endpoints and disable public access for sensitive data.
  • Convert to Parquet or Delta from the cleaned zone onward, and partition by the columns queries filter on.
  • Compact small files and aim for healthy file sizes.
  • Automate lifecycle rules, aligned with zone and retention.
  • Choose redundancy by data value, and add soft delete and a backup plan.
  • Log and alert on usage, errors, and configuration changes.
  • Catalog datasets, give each an owner, and review them regularly.
  • Tag resources for cost and governance.

Common mistakes

MistakeWhat goes wrongBetter approach
Creating the account without the hierarchical namespace, then needing itSlow folder operations and a migration project laterDecide at creation
No folder standardThe lake becomes a swampWrite and enforce one before the first load
Using the account key everywhereNo accountability, easy leaks, hard rotationEntra identities; disable key access
Granting a broad role to everyoneACLs are bypassed and everything is visibleNarrow roles and group ACLs
Forgetting execute on parent folders“Access denied” despite read on the data folderCheck the entire path
Setting default ACLs after loadingExisting files lack the rulesSet defaults first, or apply recursively
Per-user ACL entriesHits the entry limit and is hard to maintainGroups
Millions of tiny filesSlow jobs and high operation chargesCompaction and larger batches
Cleaning data in place in the raw zoneNo original left to rebuild fromWrite cleaned data to a new zone
Tiering data that is still readHigh retrieval charges, slow jobsCheck access patterns before tiering
Assuming redundancy is backupDeleted data is gone everywhereSoft delete, backups, and tight permissions
Open public accessData leaksDisable anonymous access; private endpoints; policy
Ignoring DNS for private endpointsNames resolve to public addresses and connections failCreate and link private DNS zones
Keeping everything foreverRising cost and legal riskRetention rules per dataset
Analogy

These practices are the habits of a good librarian. Decide the shelving plan before the books arrive, keep first editions untouched in a vault, issue personal library cards instead of lending the master key, move rarely read books to the basement, and know exactly what is on every shelf.

!
The costly mistake

A lake with no structure and no owners cannot be fixed by technology. Cleaning it later means reading millions of files to learn what they are. Spend your planning time on folders, ownership, and access before the data arrives.

21Real-World Usage Scenarios

Here are typical ways organizations use Data Lake Storage Gen2. These are common patterns described in general terms, not accounts of any named company.

A typical retailer building a single view of sales

A retail company keeps store systems, an online shop, and a loyalty program, each with its own database. Every night, pipelines copy new records into a raw zone organized by source and date. A cleaning step removes duplicates and fixes product codes, writing Parquet files into the cleaned zone. A curated zone holds daily sales by store and product. Analysts query it with SQL, and data scientists use the cleaned zone to build demand forecasts. Old raw data moves to cooler tiers after ninety days.

A typical bank with strict controls

A financial company stores transaction history for risk models. The lake lives behind private endpoints with public access disabled. Account keys are turned off, so every request comes from an Entra identity and appears in the logs. Pipelines have write rights only in raw and cleaned zones. Analysts read curated data through group-based ACLs. Immutable storage protects records that regulations require to be kept unaltered. A catalog tracks the sensitivity of each dataset.

A typical manufacturer with sensor data

A manufacturer collects readings from thousands of machines. An event streaming service captures them into the lake as small files by the minute. A nightly job compacts them into larger Parquet files partitioned by day and machine type. Engineers use the data to predict failures and plan maintenance. Because the raw readings are huge and rarely needed after a few weeks, lifecycle rules move them to the archive tier after sixty days, while the summarized data stays hot.

A typical media company storing large files

A media business stores video and audio files for editing and for machine learning that tags content. Files are large, so throughput matters more than request counts. The company keeps recent projects in hot storage and moves finished ones to cool and then archive. A metadata table in the curated zone records where each file is and what it contains, so searching does not require scanning folders.

A typical software company sharing data across teams

A software firm gives each product team a folder tree in the lake and an Entra group per tree. A platform team owns the account, the network rules, and the policies, but cannot read team data because it holds only management roles. Teams share chosen datasets by adding another group to the read ACL of a specific curated folder. The catalog shows who owns each dataset and who may read it.

Services that work with the lake

Movement

Data Factory

Copies data in and out and orchestrates cleaning and loading.

Processing

Databricks and Spark

Transforms large datasets in parallel and writes results back.

Query

Synapse and SQL engines

Lets analysts query files with SQL.

Streams

Event services

Capture streaming data directly into the lake.

Learning

Machine learning tools

Read training data and store models and results.

Governance

Catalog and policy

Record what exists, how sensitive it is, and enforce rules.

Analogy

Think of these organizations as different kinds of libraries. A retail library catalogs daily newspapers. A bank library keeps its records in a locked vault with sign-in sheets. A factory library receives a constant flow of small notes and files them into bound volumes. Each uses the same building design with different rules for the doors.

22Troubleshooting

When something fails in the lake, an ordered approach finds the cause quickly. Most problems come from permissions, networks, or file layout.

A method that works

1

Read the error code and message

Storage errors usually name the problem: authorization, not found, throttled, or network. Note the status code and the request identifier.

2

Check the network path

Can the client reach the right endpoint? Test name resolution, firewall rules, and private endpoints from the client’s own network.

3

Check the identity

Which identity is the client really using? Confirm the token, the tenant, and the group memberships.

4

Check roles, then ACLs

Look at role assignments at the account and container, then walk the folder path checking execute rights on each directory and the needed right on the target.

5

Check the logs

Resource logs show the request, the caller, and the reason for denial, which usually points straight to the fix.

6

Check the data layout

For slowness, count files, check sizes and partitions, and look for throttling in metrics.

Common symptoms and likely causes

SymptomLikely causeFirst check
403 error, authorization failureMissing role or ACL right, or a firewall blockRole assignments and ACLs along the whole path; resource log reason
Role assigned but access still deniedRole changes can take a few minutes; wrong scope; wrong identityWait briefly, verify scope, confirm the identity in use
Can list folder but cannot read fileMissing read right on the fileACL on the file itself
Cannot reach a deep folderMissing execute right on a parent directoryExecute on every directory in the path
New files not accessible, old files fineDefault ACL missing or wrong on the parentDefault ACL entries on the folder
Name does not resolve or connection refused with private endpointPrivate DNS zone missing, or endpoint for the wrong sub-resourceDNS lookup from the client; endpoints for dfs and blob
503 or server busy responsesThrottling due to high request ratesMetrics for throttling; reduce parallelism; spread load
Jobs slow as data growsToo many small files or missing partition pruningFile counts and sizes; query plans
Account key request rejectedKey access disabledSwitch the tool to Entra identity authentication
Feature not available on the accountNot supported with the hierarchical namespaceCurrent feature support list
Rehydration is taking hoursArchive tier recovery is slow by designPlan ahead; use priority rehydration where offered
Unexpected high billOperations, retrieval, early deletion, or egressCost analysis by meter
Analogy

It is like finding why a visitor could not reach a room in a big building. Check whether the front gate was open, whether the visitor’s badge was valid, whether the corridor doors let them through, and finally whether the room itself was unlocked. Going in order saves you from testing every door in the building.

i
Test as the real identity

An administrator will often have access that the failing user or pipeline lacks. Always test as the same identity that failed, not as yourself.

23Frequently Asked Questions

Quick answers to questions beginners ask most often.

1Is Data Lake Storage Gen2 a separate service from Blob Storage?
Not exactly. It is blob storage in a storage account with the hierarchical namespace enabled, plus extra capabilities for analytics. The same data can be reached through both the blob and the dfs endpoints.
2What does the hierarchical namespace do?
It turns the flat list of objects into a real tree of directories and files. Renaming or deleting a directory becomes one fast, atomic action, and you can set permissions on folders and files.
3Can I turn the hierarchical namespace on later?
In some cases an existing blob account can be upgraded, with conditions, testing, and a restricted period. It is far easier to enable it at creation. Check current documentation.
4What happened to Data Lake Storage Gen1?
It was an earlier, separate service that Microsoft retired. Gen2 is the current design. If you meet older material about Gen1, treat it as history and check the retirement notes.
5What is the difference between RBAC roles and ACLs?
Roles give broad rights at the account or container level. ACLs give precise rights on directories and files. Roles are checked first, and if a role grants the action, ACLs are not consulted.
6Why can a user list a folder but not open a file?
Listing needs read on the directory and execute along the path. Opening a file needs read on the file itself. Check the ACL on the file.
7Why do new files not get my ACL changes?
Changes to access ACLs affect only the item they are set on. New items inherit from default ACLs on the parent. Set default ACLs on the folder, and apply changes recursively to existing items.
8Which file format should I use?
Keep raw data as received. For cleaned and curated data, use a compressed column format such as Parquet, or Delta when you need safe updates and history.
9How big should files be?
Large enough to read efficiently and small enough to process in parallel. A common guideline is roughly a hundred megabytes to a gigabyte, depending on the engine. Avoid millions of tiny files.
10Which redundancy option should I choose?
Local for rebuildable data, zone redundant for most production data, and geo or geo-zone redundant for critical data that must survive a regional loss. Remember that geo copies are asynchronous.
11Is redundancy the same as backup?
No. Redundancy protects against hardware and site failures. Deletes and overwrites are copied too, so add soft delete, careful permissions, and a backup or copy strategy.
12How do I keep the lake off the public internet?
Create private endpoints for the endpoints you use, set up private DNS, and disable public network access. Check that your tools can reach the private addresses.
13Should I disable the account key?
For most serious uses, yes, so that only Entra identities work and every request is attributable. First confirm that no tool still depends on the key.
14How do I reduce storage cost?
Delete what you do not need, use lifecycle rules to move aging data to cooler tiers, convert to compact formats, merge small files, and match redundancy to data value.
15Where should I start learning more?
Create a small account with the hierarchical namespace, make containers for raw, cleaned, and curated data, upload a few files, and practice setting group ACLs. Then copy data in with a pipeline and read it with a notebook.

24Summary and Key Takeaways

Azure Data Lake Storage Gen2 gives you cheap, huge, well-organized storage for analytics. It rewards planning of folders, identities, and lifecycle, and it punishes a casual start.

In this guide you met Data Lake Storage Gen2 as blob storage with a real folder tree. You learned the vocabulary and architecture, the hierarchical namespace, zone and folder design, and the ways data gets in and out. You saw how redundancy, tiers, and lifecycle rules protect and price your data, how file formats and partitioning make analytics fast, and how authentication, roles, ACLs, networks, and encryption keep it safe. You also covered monitoring, cost, performance, patterns, common mistakes, and a method for troubleshooting.

Key Takeaways

  • The hierarchical namespace is the heart of Gen2. Enable it at creation for analytics accounts, and enjoy real folders with fast, atomic renames and folder-level permissions.
  • Design the lake before filling it. Use zones such as raw, cleaned, and curated, a written folder standard with date partitions, and an owner for every dataset.
  • Keep raw data raw. It is your safety net for reprocessing whenever rules or logic change.
  • Use identity, groups, and the right layers. Entra and managed identities instead of keys, broad roles sparingly, and group-based ACLs for folder detail, with default ACLs set first.
  • Close the doors. Use private endpoints, disable public access and anonymous access, encrypt, and add soft delete because redundancy is not backup.
  • Store data for speed and cost. Use Parquet or Delta, partition sensibly, avoid tiny files, and move aging data to cooler tiers with lifecycle rules.
  • Watch and govern. Monitor capacity, operations, errors, and changes, catalog your data, tag your resources, and review the lake on a schedule.