Enable Azure Storage blob inventory reports

The Azure Storage blob inventory feature provides an overview of your containers, blobs, snapshots, and blob versions within a storage account. Use the inventory report to understand various attributes of blobs and containers such as your total data size, age, encryption status, immutability policy, and legal hold and so on. The report provides an overview of your data for business and compliance requirements.

To learn more about blob inventory reports, see Azure Storage blob inventory.

Enable blob inventory reports by adding a policy with one or more rules to your storage account. Add, edit, or remove a policy by using the Azure portal.

Enable inventory reports

  1. Sign in to the Azure portal to get started.

  2. Locate your storage account and display the account overview.

  3. Under Data management, select Blob inventory.

  4. Select Add your first inventory rule.

    The Add a rule page appears.

  5. In the Add a rule page, name your new rule.

  6. Choose the container that will store inventory reports.

  7. Under Object type to inventory, choose whether to create a report for blobs or containers.

    If you select Blob, then under Blob subtype, choose the types of blobs that you want to include in your report, and whether to include blob versions and/or snapshots in your inventory report.

    Note

    Versions and snapshots must be enabled on the account to save a new rule with the corresponding option enabled.

  8. Select the fields that you would like to include in your report, and the format of your reports.

  9. Choose how often you want to generate reports.

  10. Optionally, add a prefix match to filter blobs in your inventory report.

  11. Select Save.

    Screenshot showing how to add a blob inventory rule by using the Azure portal.

Disable inventory reports

While you can disable individual reports, you can also prevent blob inventory from running at all.

  1. Sign in to the Azure portal.

  2. Locate your storage account and display the account overview.

  3. Under Data management, select Blob inventory.

  4. Select Blob inventory settings, and in the Blob inventory settings pane, clear the Enable blob inventory checkbox, and then select Save.

    Screenshot showing the Enable blob inventory checkbox in the Azure portal.

    Clearing the Enable blob inventory checkbox suspends all blob inventory runs. You can select this checkbox later if you want to resume inventory runs.

Optionally enable access time tracking

You can choose to enable blob access time tracking. When access time tracking is enabled, inventory reports will include the LastAccessTime field based on the time that the blob was last accessed with a read or write operation. To minimize the effect on read access latency, only the first read of the last 24 hours updates the last access time. Subsequent reads in the same 24-hour period don't update the last access time. If a blob is modified between reads, the last access time is the more recent of the two values.

To enable last access time tracking with the Azure portal, follow these steps:

  1. Sign in to the Azure portal.

  2. Locate your storage account and display the account overview.

  3. Under Data management, select Blob inventory.

  4. Select Blob inventory settings, and in the Blob inventory settings pane, select the Enable last access tracking checkbox.

    Screenshot showing how to enable last access time tracking of the blob inventory settings by using the Azure portal.

Next steps