Azure Arc Azure Governance

Azure Arc: Keep an eye on the value of the Datacenter physical location tag when onboarding Azure Arc-enabled servers


Azure Arc allows you to onboard a wide variety of servers to Azure with Azure Arc-enabled servers which makes it easier to increase security, governance, and the compliance posture on all your Windows and Linux servers that are deployed outside of Azure.

One of the governance controls you can use when a hybrid machine is connected (connected machine) to Azure with Azure Arc, is tags. By applying tags you can then logically organize, manage server inventory, apply your business policies with Azure Policy or track cost with Cost Management on all these non-Azure resources.

What we see is that most company’s these days already use a specific tagging strategy and naming convention, whether or not aligned with Microsoft’s Cloud Adoption Framework methodologies, to apply tags to all their Azure resources. That is why it is also important to apply the same tagging principals to all Azure Arc resources to keep an identical tagging structure.

Because of this I just wanted to draw attention to something I noticed when tagging non-Azure servers while (or after) connecting them to Azure Arc.


Azure Arc installation script – Datacenter physical location tag

When you use the Azure Portal to onboard a server, you normally open the Servers – Azure Arc page, from where you click Generate script to create the deployment script which automates to Azure Arc onboarding process.



After a few steps you then arrive on the Tags page, where you can select the default Physical location tags you want to use by entering a value, like for example Datacenter 1. And then you also add the Custom tags to support your standards.


You then complete all the following steps, and download and run (elevated PowerShell) the script on the server(s).

After the installation you then verify the (successful) connection with Azure Arc in the Azure Portal, where you will notice that the Datacenter tag value is show between single quotes (<your tag value>), which normally will not align with your tagging naming convention.


Solution

To solve this you should Download and adjust the script before you run it.



Then open the script with Visual Studio Code or another editor, and look for “Datacenter=’<your tag value>‘ , and remove the two single quotes ‘.




Then Save the script and run in on the server(s) you want to onboard.

When you now verify the (successful) connection with Azure Arc in the Azure Portal, you will see the Datacenter tag value is show without the single quotes.


Conclusion

Whenever you apply tags to your Azure Arc resources you should follow your company’s tagging structure and principals. So, keep in mind that whenever you use the default Datacenter tag that you set it so it follows the naming convention you specified for all your tag values.


2 comments on “Azure Arc: Keep an eye on the value of the Datacenter physical location tag when onboarding Azure Arc-enabled servers

  1. Pingback: Azure Arc: Using tags with Azure Arc-enabled servers – Wim Matthyssen

  2. Pingback: Azure Back to School 2022: Let’s take a look at Azure Arc-enabled VMware vSphere – Wim Matthyssen

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: