This post was originally published to Martynas' personal cloud blog MagicMarty.eu. You can read it here.
Today I am going to show how you can change the default retention period in Log Analytics and keep the data up to 2 years.
After the Microsoft Ignite conference which happened just few months ago, the pricing plans have changed for Operations Management Suite (OMS). It used to be three plans: Free, Standard and Premium. All plans were based on how long you are able to keep your data within Log Analytics (only Free plan had upload limitations). Anyway, because OMS is expanding and more and more functionality is introduced the pricing tiers have changed as well. Now we have Free, Standalone and OMS plans.
Both Standalone and OMS plans have 31 days of data retention period. Free plan has a fixed 7 days data retention period. Keep in mind that there is still a limitation for Standalone and OMS plans, but now we can choose retention period of time up to 2 years! Currently the price is calculated “cost per 1GB” and it means that you will have to pay not for the data that is being stored but as soon as the data have reached OMS workspace.
Let’s check now how we can change data retention.
First, go to http://resources.azure.com and provide the credentials that you normally use to login to your Azure subscription. On the very top choose the subscription where your OMS workspace is residing and from Read Only change to Read/Write.
Now on the left hand side expand the following subscriptions -> your subscription name -> resourceGroups -> yourResourceGroupName -> providers -> Microsoft.OperationalInsights -> workspaces -> yourOMSworkspaceName
In order to edit you need to click Edit button. Then change the value of the retentionInDays parameter let’s say to 365 and click the PUT button to apply the changes.
That is simple as that! Good luck!
Martynas is a Senior Cloud Solutions Architect at Elastabytes. He's a Lithuanian who loves the gym, poker, and Cloud and Hybrid Cloud solutions.
Elastabytes are a cloud managed services company specialising in SQL Server. We’re a Microsoft Gold Partner and our team is made of Microsoft MVPs. Whether you’re already in Azure and need a DBA-as-a-Service, or you’re about to go to Azure and need a hand getting there, Elastabytes can help.
Contact us at email@example.com to set up a chat with one of our architects.