Skip to main content

Data disk limit on App Service Plan and Web Apps

This post is dedicated to Web Apps and how we should handle that case when we are out of disk space.

Context
When hosting our web applications as Web Apps inside App Service Plan we are limited to a specific number of GB that can be used by our web applications to store content. Depending on what kind of tier we are using we can have from a few GB of disk space up to 1TB of disk space.
Inside an App Service Plan, we can host multiple Web Apps that are sharing the resources between each other, including the disk space. This means that if we have 4 Web Apps that are requiring 5GB of disk space each, at App Service Plan level we would require and consume 20 GB of disk space.

Problem
There are special cases when the disk storage space is not enough for our web apps. For example, there are cases when because of our business use cases we might need more data on disk that we have available inside the App Service Plans.

Let's take a look at what are the options that we have at the moment when the disk space inside App Service Environment it is not enough for our web apps.

Tier up
The first option that we have is to change the App Service Plan tier. Each App Service Plan tier has a different disk space, starting from 1GB up to 1024GB.
Changing the App Service tier from one to another comes with additional cost. Changing the App Service tier will double the running cost. Because of this, many companies and customer are looking for other options to increase the disk space without doing this change.

Attach disks
At this moment there is no possibility to attach a disk to App Service or to a Web App. This is something normal because at Web App level we don't have any control at OS level. Even if this solution would be super simple to implement and cheap it is not possible inside a Web App.

Azure Files
Using Azure Files, we would be able to share content using network drive or other capabilities. Unfortunately, Azure Files cannot be attached to Web Apps and App Services. The root cause is similar with the previous options, based on the network share and attach disks.

Azure Blob Storage
Blob storage it is a good option to be used in combination with App Services. Blobs are a cheap location where we can store content used by our Web Apps. The storage can be accessed directly by our application layer or we can redirect clients directly to our blob storage.
This solution works great as long as we have control at the application layer and we can change the code or how we fetch data.
If we don't have the possibility to modify the application to fetch data from different sources, then we cannot use this option.

Static web content inside Azure Storage
These capabilities enable us to host static content directly to Azure Storage. Clients can fetch content from Azure Storage as it would be under our Web App. It works great for cases when data disk is required to store content that it is required by our clients and not by our web application layer.

Conclusion
When you have such an issue related to disk space, in most of the cases the web application footprint it is so big that you consume all disk space available inside the App Service. The extra space required by your web application might be fetched from external sources, but not all the time. For this scenarious, the best possible solution is to split the application. More about this will be presented in the next post.

Comments

Popular posts from this blog

Windows Docker Containers can make WIN32 API calls, use COM and ASP.NET WebForms

After the last post , I received two interesting questions related to Docker and Windows. People were interested if we do Win32 API calls from a Docker container and if there is support for COM. WIN32 Support To test calls to WIN32 API, let’s try to populate SYSTEM_INFO class. [StructLayout(LayoutKind.Sequential)] public struct SYSTEM_INFO { public uint dwOemId; public uint dwPageSize; public uint lpMinimumApplicationAddress; public uint lpMaximumApplicationAddress; public uint dwActiveProcessorMask; public uint dwNumberOfProcessors; public uint dwProcessorType; public uint dwAllocationGranularity; public uint dwProcessorLevel; public uint dwProcessorRevision; } ... [DllImport("kernel32")] static extern void GetSystemInfo(ref SYSTEM_INFO pSI); ... SYSTEM_INFO pSI = new SYSTEM_INFO(

ADO.NET provider with invariant name 'System.Data.SqlClient' could not be loaded

Today blog post will be started with the following error when running DB tests on the CI machine: threw exception: System.InvalidOperationException: The Entity Framework provider type 'System.Data.Entity.SqlServer.SqlProviderServices, EntityFramework.SqlServer' registered in the application config file for the ADO.NET provider with invariant name 'System.Data.SqlClient' could not be loaded. Make sure that the assembly-qualified name is used and that the assembly is available to the running application. See http://go.microsoft.com/fwlink/?LinkId=260882 for more information. at System.Data.Entity.Infrastructure.DependencyResolution.ProviderServicesFactory.GetInstance(String providerTypeName, String providerInvariantName) This error happened only on the Continuous Integration machine. On the devs machines, everything has fine. The classic problem – on my machine it’s working. The CI has the following configuration: TeamCity .NET 4.51 EF 6.0.2 VS2013 It see

Navigating Cloud Strategy after Azure Central US Region Outage

 Looking back, July 19, 2024, was challenging for customers using Microsoft Azure or Windows machines. Two major outages affected customers using CrowdStrike Falcon or Microsoft Azure computation resources in the Central US. These two outages affected many people and put many businesses on pause for a few hours or even days. The overlap of these two issues was a nightmare for travellers. In addition to blue screens in the airport terminals, they could not get additional information from the airport website, airline personnel, or the support line because they were affected by the outage in the Central US region or the CrowdStrike outage.   But what happened in reality? A faulty CrowdStrike update affected Windows computers globally, from airports and healthcare to small businesses, affecting over 8.5m computers. Even if the Falson Sensor software defect was identified and a fix deployed shortly after, the recovery took longer. In parallel with CrowdStrike, Microsoft provided a too