{"id":2731,"date":"2021-02-01T21:38:39","date_gmt":"2021-02-01T20:38:39","guid":{"rendered":"https:\/\/azuregeek.io\/?p=2731"},"modified":"2021-07-20T16:21:15","modified_gmt":"2021-07-20T14:21:15","slug":"acronis-agent-updates-mit-azure-functions-automatisieren","status":"publish","type":"post","link":"https:\/\/azuregeek.io\/en\/automate-acronis-agent-updates-with-azure-functions\/","title":{"rendered":"Automate Acronis Agent updates with Azure Functions"},"content":{"rendered":"<p>If you use Acronis Cloud Backup with many agents and\/or customer tenants, you know the problem: you have to update the agents manually at regular intervals. This can be extremely annoying, especially if you have to work through multiple tenants.<\/p>\n<p>So as an automation geek, it made sense to delegate this activity to Azure Functions \ud83d\ude04<\/p>\n<figure>\n\t\t\t\t\t\t\t\t\t\t<span class=\"placeholder-el\" data-svq-align=\"\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-45x25.png\" alt class=\"lazy\" data-srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-1024x576.png 1024w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-300x169.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-768x432.png 768w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-16x9.png 16w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-1100x620.png 1100w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-45x25.png 45w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate.png 1383w\" data-sizes=\"100vw\" data-width=\"1024\" data-height=\"576\" data-src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-1024x576.png\" style=\"height: 0; width: 1024px; padding-bottom: 56.25%;\"><span class=\"svq-img-loader\"><\/span><\/span><noscript><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"576\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-1024x576.png\" alt=\"\" srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-1024x576.png 1024w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-300x169.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-768x432.png 768w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-16x9.png 16w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-1100x620.png 1100w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate-45x25.png 45w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisManualUpdate.png 1383w\" sizes=\"100vw\"><\/noscript><figcaption>Manual update of the agents is very time consuming<\/figcaption><\/figure>\n<p>The Azure Function is developed in .NET Core \/ C# and does the following for us:<\/p>\n<ul>\n<li>Logging in to the Acronis Cloud API<\/li>\n<li>Identify all customer accounts below the stored user - including \"special\" accounts of type department, partner, etc.<\/li>\n<li>For each customer account, the backup agents created under it are identified<\/li>\n<li>The function then processes all agents and starts the agent update.<\/li>\n<li>Last but not least, the updated agents are summarized by e-mail and sent to the deposited e-mail address.<\/li>\n<li>In addition, a table storage is created as an update archive, in which the agent data is also stored.<\/li>\n<\/ul>\n<figure>\n\t\t\t\t\t\t\t\t\t\t<span class=\"placeholder-el\" data-svq-align=\"\"><img loading=\"lazy\" decoding=\"async\" width=\"860\" height=\"352\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-45x18.png\" alt class=\"lazy\" data-srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification.png 860w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-300x123.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-768x314.png 768w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-16x7.png 16w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-45x18.png 45w\" data-sizes=\"100vw\" data-width=\"860\" data-height=\"352\" data-src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification.png\" style=\"height: 0; width: 860px; padding-bottom: 40.93%;\"><span class=\"svq-img-loader\"><\/span><\/span><noscript><img loading=\"lazy\" decoding=\"async\" width=\"860\" height=\"352\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification.png\" alt=\"\" srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification.png 860w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-300x123.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-768x314.png 768w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-16x7.png 16w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentAutoUpdate-Notification-45x18.png 45w\" sizes=\"100vw\"><\/noscript><figcaption>E-mail notification after automatic update<\/figcaption><\/figure>\n<p>Since a good Cloud Architect \/ SysAdmin \/ Backup Operator \/ * is comfortable, the \"installation\", i.e. the deployment of the Azure Function is completely automated and all parameters can be specified during deployment. Of course, the data can be changed later (in the app settings of the function or access data in the created KeyVault).<\/p>\n<figure>\n\t\t\t\t\t\t\t\t\t\t<span class=\"placeholder-el\" data-svq-align=\"\"><img loading=\"lazy\" decoding=\"async\" width=\"735\" height=\"734\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-45x45.png\" alt class=\"lazy\" data-srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate.png 735w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-300x300.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-150x150.png 150w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-12x12.png 12w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-700x700.png 700w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-350x350.png 350w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-240x240.png 240w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-120x120.png 120w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-100x100.png 100w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-45x45.png 45w\" data-sizes=\"100vw\" data-width=\"735\" data-height=\"734\" data-src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate.png\" style=\"height: 0; width: 735px; padding-bottom: 99.86%;\"><span class=\"svq-img-loader\"><\/span><\/span><noscript><img loading=\"lazy\" decoding=\"async\" width=\"735\" height=\"734\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate.png\" alt=\"\" srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate.png 735w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-300x300.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-150x150.png 150w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-12x12.png 12w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-700x700.png 700w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-350x350.png 350w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-240x240.png 240w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-120x120.png 120w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-100x100.png 100w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AutoDeploymentOfAgentUpdate-45x45.png 45w\" sizes=\"100vw\"><\/noscript><figcaption>All properties can be set during deployment<\/figcaption><\/figure>\n<p>After successful deployment, the update runs by default every day at 11:30 CET. During the deployment, the automatic start time can be set using the <a href=\"https:\/\/docs.microsoft.com\/en-us\/azure\/azure-functions\/functions-bindings-timer?tabs=csharp#ncrontab-expressions\" target=\"_blank\" rel=\"noopener\">CRON Expression<\/a> customize.<\/p>\n<p>Here is one last view of the Table Storage, where all updated agents are logged:<\/p>\n<p><span class=\"placeholder-el\" data-svq-align=\"\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"340\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-45x15.png\" alt class=\"lazy\" data-srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-1024x340.png 1024w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-300x100.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-768x255.png 768w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-16x5.png 16w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-45x15.png 45w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable.png 1350w\" data-sizes=\"100vw\" data-width=\"1024\" data-height=\"340\" data-src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-1024x340.png\" style=\"height: 0; width: 1024px; padding-bottom: 33.20%;\"><span class=\"svq-img-loader\"><\/span><\/span><noscript><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"340\" src=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-1024x340.png\" alt=\"\" srcset=\"https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-1024x340.png 1024w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-300x100.png 300w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-768x255.png 768w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-16x5.png 16w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable-45x15.png 45w, https:\/\/azuregeek.io\/wp-content\/uploads\/2021\/02\/AcronisAgentUpdateTable.png 1350w\" sizes=\"100vw\"><\/noscript><\/p>\n<p>And here you can deploy the function:<br \/>\n<a href=\"https:\/\/github.com\/TobiKr\/AcronisAgentUpdater\" target=\"_blank\" rel=\"noopener\">https:\/\/github.com\/TobiKr\/AcronisAgentUpdater<\/a><\/p>\n<p><a href=\"https:\/\/portal.azure.com\/#create\/Microsoft.Template\/uri\/https%3A%2F%2Fraw.githubusercontent.com%2FTobiKr%2FAcronisAgentUpdater%2Fmain%2Fazuredeploy.json\" target=\"_blank\" rel=\"noopener\"><img decoding=\"async\" src=\"https:\/\/aka.ms\/deploytoazurebutton\"><\/a><\/p>\n<p>Happy automating \ud83e\udd16<\/p>","protected":false},"excerpt":{"rendered":"<p>Wer Acronis Cloud Backup mit vielen Agents und\/oder Kunden-Tenants einsetzt, kennt das Problem: in regelm\u00e4\u00dfigen Abst\u00e4nden muss man die Agents manuell updaten. Das kann \u00e4u\u00dferst l\u00e4stig werden, insbesondere, wenn man sich durch mehrere Tenants arbeiten muss. Als Automatisierungs-Geek lag es also nahe, diese T\u00e4tigkeit an Azure Functions zu delegieren \ud83d\ude04 Manuelles Update der Agents ist [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"_links":{"self":[{"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/posts\/2731"}],"collection":[{"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/comments?post=2731"}],"version-history":[{"count":14,"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/posts\/2731\/revisions"}],"predecessor-version":[{"id":2751,"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/posts\/2731\/revisions\/2751"}],"wp:attachment":[{"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/media?parent=2731"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/categories?post=2731"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/azuregeek.io\/en\/wp-json\/wp\/v2\/tags?post=2731"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}