Managing Microsoft Azure EA or PAYG collections
HPE Consumption Analytics portal's Microsoft Azure collection retrieves usage, cost, and performance data from Azure, Microsoft's public cloud platform. HPE Consumption Analytics portal collects data from your Azure Enterprise Agreement (EA), Azure Pay-As-You-Go (PAYG) subscription, or Azure Cloud Solution Provider (CSP) subscription.
Azure CSP collections are administered by HPE teams. This page shows you how to create collections for your EA or PAYG subscription.
Creating a Microsoft Azure EA Collection
Creating a Microsoft Azure EA collection in HPE Consumption Analytics platform enables you to collect usage and cost data from one or more subscriptions in your Microsoft Azure EA account. HPE Consumption Analytics platform can automatically collect your Azure EA resource-level and group-level tags for resources deployed using the Azure Resource Manager HPE Consumption Analytics platform can also collect performance metrics for resources that have diagnostics enabled in Microsoft Azure EA.
HPE Consumption Analytics platform collects Azure EA data through the following APIs:
- Azure EA Billing: - Usage, charges, and resource tags
- Azure Resource: Resource Group name and tags for resource groups
- Azure Diagnostics: - Performance metrics
To collect the resource tags and/or performance metrics, you need to enable the appropriate APIs, which require specific subscriptions to be explicitly approved by the admin/co-admin of the subscriptions.
For more information about how HPE Consumption Analytics portal maps source provider data to HPE Consumption Analytics portal normalized fields, see Field mapping.
The HPE Consumption Analytics portal supports EA enrollments for Azure China for collection of billing information, but not for collection of performance metrics and other information described in Understanding connection to your subscriptions in this topic.
HPE has observed that Azure China, which is operated by 21Vianet, does not behave as predictably as the global Azure service operated by Microsoft. We have attempted to compensate in HPE Consumption Analytics portal for known anomalies of Azure China, but cannot predict every such anomaly. You might find that in HPE Consumption Analytics portal an Azure collection for an EA enrollment in China behaves differently than an Azure collection for an EA enrollment in another country.
HPE Consumption Analytics platform does not support Azure Germany, another independently operated Azure system introduced in April 2017.
Getting started
Before creating an Azure EA collection:
- Gather your Azure EA credentials.
- If you want to collect subscription information, make sure:
- Your Azure EA account is assigned the right administrator roles for the subscriptions associated with your Enterprise account.
- Subscriptions are active. HPE Consumption Analytics portal cannot collect from disabled subscriptions.
- Subscriptions are registered with the microsoft.insights resource provider.
- If you want to collect performance data, make sure you have the correct diagnostic setting configured for each virtual machine.
Gathering credential information
Before you start creating an Azure EA collection in HPE Consumption Analytics portal, you will need the following credential information,:
- Enrollment Number: Your Microsoft EA enrollment ID. You can locate this at the top of the Microsoft Azure Enterprise Portal (EA portal).
- Access Key: A long string of about 700 characters, which is used to authenticate access to the Microsoft Azure API.
To obtain this key from the EA portal, select Reports > Download Usage > API Access Key and view the value in the Primary Key field. Your key must be an Enrollment Access Key.
- Only an enrollment-level access key will allow HPE Consumption Analytics portal to collect Azure data. To check your level of access, look at the heading above your keys in the EA portal. It must read Enrollment Access Keys.
- If the heading is Department Access Keys, Subscription Access Keys, or something else, you do not have an enrollment-level access key. In that case, you must get help from someone with enrollment-level keys to create your Azure collection in HPE Consumption Analytics portal.
- The Enrollment Access Key is a long string (about 700 characters). To copy the entire value, we recommend using the Expand Key button to copy the string from the Microsoft Azure EA portal and and paste it to the HPE Consumption Analytics portal Access Key field.
- Keys expire every 6 months by default. Therefore, you need to update your collection periodically. If data collection fails with an "HTTP/1.1 401 Unauthorized" error when connecting to the Microsoft Azure endpoint, investigate whether you need to generate a new access key in the EA portal.
Understanding connection to your subscriptions (optional)
To supplement the usage and billing data that the HPE Consumption Analytics platform collects using your EA credentials, the portal can optionally collect resource details (such as metrics, tags, and resource group names) available through your Azure subscriptions.
The HPE Consumption Analytics platform collects this data per resource, but in Azure, the permission to do so is set at the subscription level. For this reason, if you want to collect subscription-level data, you must use an Azure Service Administrator or Co-Administrator role when you create the collection in your HPE Consumption Analytics platform account and connect it to the Azure subscription(s) for which you want to collect details.
Connecting a subscription to an HPE Consumption Analytics platform collection creates a service principal user in Azure with the Reader role only, to represent the HPE Consumption Analytics platform application in that subscription. This gives the HPE Consumption Analytics platform permission to view data, but not to make any changes to the Azure subscription.
While the HPE Consumption Analytics platform requires only Reader-level access in the subscription to be used for data collection, a human with Azure Service Administrator or Co-Administrator access must grant it this Reader role in the subscription when creating the collection in the HPE Consumption Analytics platform.
Service Administrator or Co-Administrator access ends when the login session used to connect the subscription ends.
If you have multiple subscriptions and multiple subscription administrators, use one of the following strategies to ensure that HPE Consumption Analytics platform can discover and collect from your subscriptions:
- Centralize subscription administrator roles with a single Azure user account. With this strategy:
- You designate a single Azure user account to manage your Azure EA collection in HPE Consumption Analytics platform.
- Subscription Service Administrators then add that centralized user as a Co-Administrator of each subscription.
The benefit of this strategy is simplicity; you need only one user to administer the Azure collection in the HPE Consumption Analytics platform.
Before the HPE Consumption Analytics platform can discover and collect from new subscriptions added in Azure, the Service Administrators of those subscriptions must add the centralized user as a Co-Administrator.
For more information about Azure administrator roles and how to add them to subscriptions, see How to add or change Azure administrator roles in the Microsoft Azure documentation.
- Allow multiple Azure users to manage the Azure collection in HPE Consumption Analytics portal. With this strategy:
- You create a user account for each Service Administrator to add their own Azure subscriptions in HPE Consumption Analytics platform.
- After you create the Azure EA collection in HPE Consumption Analytics platform, each subscription Service Administrator must add his or her subscriptions to the collection, as described in Updating a collection with additional subscriptions.
The benefit of this strategy is that you spread responsibility for managing the Azure collection in the HPE Consumption Analytics platform among the Service Administrators of your subscriptions.
If you use this strategy, each subscription Service Administrator must have a HPE Consumption Analytics platform user account with the Manage Data capability. For more information, see Permissions.
Creating your Microsoft Azure EA collection
The following step-by-step instructions show you how to create a Microsoft Azure EA collection in HPE Consumption Analytics portal, enabling you to collect usage and cost data, as well as tags and performance metrics, from your Microsoft Azure EA account.
To create a Microsoft Azure EA collection in the HPE Consumption Analytics platform
- Click Data in the left navigation panel.
The Data page displays:
- Click the + icon.
The Source page of the New Data Collection wizard displays.
- Click the Microsoft Azure button.
The Credentials page of the wizard displays, with the Do you have an Enrollment number....? radio button defaulted to Yes.
- Enter your Microsoft EA account Enrollment Number and Access Key.
- Click Next.
HPE Consumption Analytics portal validates your credentials, and the Subscriptions page of the wizard displays a list of active subscriptions.
The Status column shows whether subscriptions are connected, connecting, or not connected. Connected subscriptions appear in green, connecting subscriptions appear in blue, and not connected subscriptions appear in red. Subscriptions that are not connected are either canceled or disabled in the Azure Preview portal. You can use the filter under Subscription Collections to show active or inactive subscriptions, and you can view the total number of subscriptions per status in the Total Subscriptions section.
If no active subscriptions are found, or if a subscription is still connecting, you can still progress to the next step of the wizard.
- For any subscriptions you do not want to use in this collection (such as subscriptions with a status of not connected), clear the Collect check box.
- Click Next.
The Data Collection Options page of the wizard displays.
- If you haven't included any subscriptions, the Skip adding subscriptions? overlay will display. The overlay lists the benefits of adding subscriptions. If you're already aware of these and intend to add subscriptions at a later time, close the overlay, and the Data Collection Options screen will display.
- You don't have to include subscriptions to collect usage and billing data for Azure EA, but you need to include subscriptions to collect utilization metrics that enable other HPE Consumption Analytics platform features, such as cost saving Insights.
- On the Data Collection Options page, enter the following information:
- Name: Enter a unique name for the collection. The character limit is 40.
- Comments: (Optional) Enter additional information about the collection; for example, the types of data you are collecting.
- Earliest Date to Collect: Select the first day of data you want to collect. HPE Consumption Analytics portal collects data from that date forward. For example, if you had your cloud in a pre-production mode for a short time while you fine-tuned the services you offer, consider setting the date to the first day your cloud was in production.
- Source Currency: Select the currency in which your cloud provider reports your charges. If the Source Currency and your Display currency do not match, HPE Consumption Analytics portal converts collections with a different Source Currency and displays the selected Display Currency.
For information about changing currency and locale settings, see Currency and locale.
- Click Finish.
The new collection appears in your list of collections, and HPE Consumption Analytics portal begins collecting data from Microsoft Azure. - To view the status of the collection, click the gear icon and click Status.
Any errors or warnings related to your collection appear on the Health Checks page. For more information, see Health checks.
Updating an EA collection with additional subscriptions
You can add subscriptions to a Microsoft Azure EA collection you've already created. For example, you might have added subscriptions in Azure EA and you want to collect their metrics in HPE Consumption Analytics portal.
Microsoft stores utilization data for 14 days only. Once collected, it is stored permanently in HPE Consumption Analytics portal, but you will see only the most recent 14 days of data in the first collection after adding a subscription. From that point forward, data will be collected and stored daily.
To add subscriptions to an Azure EA collection
- Click Data in the left navigation panel.
- In the Collections list, select the collection you want to edit.
The Editing Data Collection overlay displays. - Click the Manage subscriptions tab.
- Click the + icon.
The Enter Directory Name popup displays.
- In the Enter Directory Name field, enter the name of the Azure Active Directory that contains the subscriptions you want to add, in the full name format (for example, mydirectory.onmicrosoft.com).
You can find the directory name by clicking Switch Directory in your account menu in the top right corner of the Azure Portal.
- Click Sign in with Microsoft.
The Sign in to your account popup displays:
- Sign in to your Microsoft account.
HPE Consumption Analytics portal connects to the subscriptions in the Active Directory you entered, and adds them to the Subscriptions list. The Status column shows whether subscriptions are connected, connecting, or not connected. Subscriptions that are not connected are either canceled or disabled in the Azure Preview portal.
You must be a Co-Administrator or a Service Administrator of the subscription.
For more information about assigning administrator roles to Azure subscriptions, see How to add or change Azure administrator roles in the Microsoft documentation.
- Clear the Collect checkbox for any subscriptions you don't want to use in this collection (such as subscriptions with a status of not connected).
- Click Save.
The overlay closes and the collection is saved. HPE Consumption Analytics portal will collect historical data for your new subscription at its next daily collection.
Creating a Microsoft Azure PAYG collection
Creating a Microsoft Azure PAYG collection in HPE Consumption Analytics Portal enables you to collect usage and cost data from the subscription in your Microsoft Azure PAYG account.
Getting Started
Before creating an Azure PAYG collection:
- Gather your Azure credentials.
- If you want to collect subscription information, make sure:
- Your Azure account is assigned the right administrator roles for the subscription associated with your PAYG account.
- The subscription is active. HPE Consumption Analytics Portal cannot collect from disabled subscriptions.
- The subscription is registered with the microsoft.insights resource provider.
- If you want to collect performance data, make sure you have the correct diagnostic setting configured for each virtual machine.
Creating your Microsoft Azure PAYG collection
The following step-by-step instructions show you how to create a Microsoft Azure PAYG collection in HPE Consumption Analytics Portal, enabling you to collect usage and cost data from your Microsoft Azure PAYG subscription. There will be one collection per subscription.
To create a Microsoft Azure PAYG collection in the HPE Consumption Analytics Portal
- Click Data in the left navigation panel.
- On the Data page, click the + icon.
The Source page of the New Data Collection wizard displays. - Click the Microsoft Azure button.
The Credentials page of the wizard displays, with the Do you have an Enrollment number for an Enterprise Agreement (EA)? radio button defaulted to Yes. - Click No.
The message As a Pay-As-You-Go customer, you must add subscriptions ... displays:.
- Click Next.
- Click the + icon.
The Enter Directory Name popup displays.
- In the Enter Directory Name field, enter the name of the Azure Active Directory that contains the subscription you want to add, in the full name format (for example, mydirectory.onmicrosoft.com).
You can find the directory name by clicking Switch Directory in your account menu in the top right corner of the Azure Portal.
- Click Sign in with Microsoft.
The Sign in to your account popup displays:
- Sign in to your Microsoft account.
The HPE Consumption Analytics Portal connects to the subscription in the Active Directory you entered, and shows it in the Subscriptions list. The Status column shows whether the subscription is connected, connecting, or not connected. Subscriptions that are not connected are either canceled or disabled in the Azure Preview portal.
You must be a Co-Administrator or a Service Administrator of the subscription.
For more information about assigning administrator roles to Azure subscriptions, see How to add or change Azure administrator roles in the Microsoft documentation.
- Click Next.
The Data Collection Options page of the wizard displays.
- On the Data Collection Options page, enter the following information:
- Name: Enter a unique name for the collection. The character limit is 40.
- Comments: Enter additional information about the collection if needed. For example, you might describe the types of data you are collecting.
- Earliest Date to Collect: Select the first day of data you want to collect. HPE Consumption Analytics Portal collects data from that date forward.
For example, if you had your cloud in a pre-production mode for a short time while you fine-tuned the services you offer, consider setting the date to the first day your cloud was in production. - Source Currency: Select the currency in which your cloud provider reports your charges.
If the Source Currency and your Display currency do not match, HPE Consumption Analytics Portal converts collections with a different Source Currency and displays the selected Display Currency.
For information about changing currency and locale settings, see Currency and locale.
- Click Finish.
The overlay closes and the collection is saved. HPE Consumption Analytics Portal begins collecting data from Microsoft Azure. - To view the status of the collection, click the gear icon and click Status.
Managing diagnostics for Azure VMs
HPE Consumption Analytics portal can collect performance and utilization metrics for VMs that have diagnostics enabled and not enabled in Microsoft Azure. Diagnostics captures system data on the virtual machines and virtual machine instances that run a cloud service. Memory utilization metrics are collected for ARM VMs with diagnostics enabled. For ARM VMs with diagnostics not enabled, all metrics are collected. For a list of the specific HPE Consumption Analytics portal metrics fields collected from Azure and other providers, see Performance and utilization metrics.
To enable diagnostics for an Azure VM
- Go to the Azure Preview portal (https://portal.azure.com).
- Select Virtual Machines.
- Click the VM you want to modify.
- Navigate to Monitoring, and select Diagnostics settings.
- To enable/disable diagnostics:
- For Windows VMs:Select Performance counters.
- To enable diagnostics, skip to step c. To disable diagnostics, select None, then skip to step 5.
- To enable diagnostics, select Basic and then select the following Performance Counter check boxes:
- Network
- Disk
- Memory
- CPU
- For Linux VMs:To enable diagnostics, skip to step b. To disable diagnostics, select Off under Status, then skip to step e.
- To enable diagnostics, select On under Status.
- Select the storage account to store metrics.
- Select the Basic Metrics check box.
- Click Save.
- For Windows VMs:Select Performance counters.
- Repeat this procedure as needed to enable diagnostics for other VMs.