Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Azure function storage file isn't deleted with function

When I create new Azure function, the specified storage account also create logs and files like host locks. For consumption, plan storage uses File Share to store whole function app by default.

When I want to delete my azure function, nothing is deleted in the storage account.

Storage account after deleted:

  1. Is that correct for consumption plan?
  2. Should I delete it manually?
like image 314
Olena Denysiuk Avatar asked Feb 07 '19 12:02

Olena Denysiuk


People also ask

Can multiple function apps use the same storage account?

Shared storage accountsIt's possible for multiple function apps to share the same storage account without any issues.

Why do I need an Azure storage account for Azure Functions?

Azure Functions requires an Azure Storage account when you create a function app instance. The following storage services may be used by your function app: Maintain bindings state and function keys. Also used by task hubs in Durable Functions. File share used to store and run your function app code in a Consumption Plan and Premium Plan.

Where are azure durable functions stored?

Used by task hubs in Durable Functions. When using the Consumption/Premium hosting plan, your function code and binding configuration files are stored in Azure Files in the main storage account. When you delete the main storage account, this content is deleted and cannot be recovered.

How to recover lost function code from Azure storage account?

Search for your storage account in the Azure portal to see whether it still exists. If it has been deleted, re-create the storage account and replace your storage connection strings. Your function code is lost, and you need to redeploy it.

Why is my Azure Functions runtime unreachable?

"Error: Azure Functions Runtime is unreachable. Click here for details on storage configuration." This issue occurs when the Azure Functions Runtime can't start. The most common reason for the issue is that the function app has lost access to its storage account. For more information, see Storage account requirements.


1 Answers

On either a Consumption plan or an App Service plan, a function app requires a general Azure Storage account, which supports Azure Blob, Queue, Files, and Table storage. This is because Functions relies on Azure Storage for operations such as managing triggers and logging function executions, but some storage accounts do not support queues and tables.

They are part of a resource group, if you don't delete the whole resource group you have to delete each item seperately.

reference: https://learn.microsoft.com/en-us/azure/azure-functions/functions-scale

like image 181
Anass Kartit Avatar answered Oct 10 '22 23:10

Anass Kartit