title: How to change the Analytics Workspace of a VMSS in Azure?
body: <p>The Azure Monitoring Agent is a service that runs on a virtual machine and sends logs and metrics to Azure Analytics. This agent can be installed via multiple ways, for example:</p>
  <ul>
  <li>by selecting the option while creating the VMSS, for example in the Azure portal</li>
  <li>with an &quot;Enable&quot; button in the monitoring section of a VMSS in case it was not installed while the VMSS was created</li>
  <li>by installing the the correct &quot;extension&quot; for all machines in the VMSS</li>
  <li>manually or automated as a software installation inside the virtual machine, for example via ansible or actually by hand</li>
  </ul>
  <p>There might be more options, but in any case the agent needs to know to which Analytics Workspace it should send its data, and this value is a user input during the installation of the agent.</p>
  <p>Now, once installed, how can I change the destination Analytics Workspace for an entire VMSS?</p>